Class: Ddr::Auth::Roles::RoleAttribute

Inherits:
Virtus::Attribute
  • Object
show all
Defined in:
lib/ddr/auth/roles/role_attribute.rb

Instance Method Summary collapse

Instance Method Details

#coerce(value) ⇒ Object



7
8
9
10
11
12
# File 'lib/ddr/auth/roles/role_attribute.rb', line 7

def coerce(value)
  if value.is_a? Array
    return coerce(value.first)
  end
  value.to_s
end