Class: ModelTag

Inherits:
Object
  • Object
show all
Includes:
MongoMapper::EmbeddedDocument
Defined in:
lib/app/models/model_tag.rb

Defined Under Namespace

Classes: UserProxy

Instance Method Summary collapse

Instance Method Details

#save_or_destroyObject



16
17
18
# File 'lib/app/models/model_tag.rb', line 16

def save_or_destroy
  user_ids.empty? ? destroy : save
end

#usersObject



8
9
10
# File 'lib/app/models/model_tag.rb', line 8

def users
  UserProxy.new(self)
end