Sha256: df19d892b3554788af545ac346f08cbe517952e6c4a2fdebede3a4f52478a1c8

Contents?: true

Size: 283 Bytes

Versions: 5

Compression:

Stored size: 283 Bytes

Contents

# frozen_string_literal: true

module Ivapi
  module Authentication
    def authentication
      if @username && @password
        { nick: @username, password: @password }
      else
        {}
      end
    end

    def authenticated?
      !authentication.empty?
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
ivapi-1.9.0 lib/ivapi/authentication.rb
ivapi-1.8.0 lib/ivapi/authentication.rb
ivapi-1.7.0 lib/ivapi/authentication.rb
ivapi-1.6.1 lib/ivapi/authentication.rb
ivapi-1.6.0 lib/ivapi/authentication.rb