Class: Supabase::Auth::Types::UserResponse

Inherits:
Struct
  • Object
show all
Defined in:
lib/supabase/auth/types.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#userObject

Returns the value of attribute user

Returns:

  • (Object)

    the current value of user



220
221
222
# File 'lib/supabase/auth/types.rb', line 220

def user
  @user
end

Class Method Details

.from_hash(hash) ⇒ Object



224
225
226
227
228
# File 'lib/supabase/auth/types.rb', line 224

def self.from_hash(hash)
  return nil if hash.nil?

  new(user: User.from_hash(hash["user"] || hash[:user]))
end