Class: Tokite::User
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- Tokite::User
- Defined in:
- app/models/tokite/user.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.create_group_user!(name) ⇒ Object
5 6 7 8 9 10 11 12 13 14 |
# File 'app/models/tokite/user.rb', line 5 def self.create_group_user!(name) uuid = SecureRandom.uuid.tr("-", "") create!( provider: "GROUP", uid: uuid, email: uuid, image_url: "", name: name ) end |
Instance Method Details
#group_user? ⇒ Boolean
16 17 18 |
# File 'app/models/tokite/user.rb', line 16 def group_user? provider == "GROUP" end |