app/models/tramway/user/user.rb in tramway-user-2.1 vs app/models/tramway/user/user.rb in tramway-user-2.1.0.1
- old
+ new
@@ -1,9 +1,11 @@
+# frozen_string_literal: true
+
class Tramway::User::User < ::Tramway::Core::ApplicationRecord
has_secure_password
- # FIXME replace to tramway-admin
- enumerize :role, in: [ :user, :admin ], default: :user
+ # FIXME: replace to tramway-admin
+ enumerize :role, in: %i[user admin], default: :user
def admin?
role.admin?
end