lib/castronaut/authentication_result.rb in masover-castronaut-0.4.4.4 vs lib/castronaut/authentication_result.rb in masover-castronaut-0.4.4.5

- old
+ new

@@ -1,12 +1,13 @@ module Castronaut class AuthenticationResult - attr_reader :username, :error_message + attr_reader :username, :identifier, :error_message - def initialize(username, error_message=nil) + def initialize(username, error_message=nil, identifier=nil) @username = username + @identifier = identifier.nil? ? username : identifier @error_message = error_message Castronaut.logger.info("#{self.class} - #{@error_message} for #{@username}") if @error_message && @username end def valid?