Sha256: 6aefe1475f67f7acbe51ac97fd7de6b3df904b44f85d9312c1da32dfff228c16

Contents?: true

Size: 420 Bytes

Versions: 14

Compression:

Stored size: 420 Bytes

Contents

# frozen_string_literal: true

module Uffizzi
  module AuthHelper
    class << self
      def signed_in?
        ConfigFile.exists? &&
          ConfigFile.option_exists?(:account_id) &&
          ConfigFile.option_exists?(:cookie) &&
          ConfigFile.option_exists?(:hostname)
      end

      def project_set?
        ConfigFile.exists? &&
          ConfigFile.option_exists?(:project)
      end
    end
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
uffizzi-cli-0.5.2 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.5.1 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.5.0 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.4.0 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.3.8 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.3.7 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.3.6 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.3.5 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.3.4 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.3.3 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.3.2 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.2.2 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.2.1 lib/uffizzi/auth_helper.rb
uffizzi-cli-0.2.0 lib/uffizzi/auth_helper.rb