Permalink
Browse files

gar

  • Loading branch information...
1 parent 0bdd47a commit d4719367a45dc6b77193cc109cfee93913163f04 @bjeanes committed Oct 22, 2008
Showing with 2 additions and 8 deletions.
  1. +1 −7 app/models/playership.rb
  2. +1 −1 app/models/user.rb
View
@@ -1,6 +1,5 @@
class Playership < ActiveRecord::Base
- acts_as_ordered :order => 'id', :wrap => true, :conditions => :active?
-
+ acts_as_ordered :order => 'id', :wrap => true
belongs_to :game
belongs_to :player, :class_name => "User"
@@ -13,9 +12,4 @@ def before_create
self[:owner] = true
end
end
-
- def inactive!
- active = false
- save
- end
end
View
@@ -81,7 +81,7 @@ def online!
def offline!
self.online = false
- self.playerships.map(&:inactive!)
+ self.playerships.destroy_all
save!
end

0 comments on commit d471936

Please sign in to comment.