diff options
author | Luke Shumaker <shumakl@purdue.edu> | 2014-04-28 09:51:39 -0400 |
---|---|---|
committer | Luke Shumaker <shumakl@purdue.edu> | 2014-04-28 09:51:39 -0400 |
commit | e0feee503865ac797a2d5bf95f7c655c0289a329 (patch) | |
tree | 1da40eec6a639d1b248833772301cb621b2cb7c1 /app/models | |
parent | f8e9b0349b82278c8fb015037e901dd5a77e30e7 (diff) |
Tournament: set status=0 by default
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/tournament.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/app/models/tournament.rb b/app/models/tournament.rb index a569213..46a2ba7 100644 --- a/app/models/tournament.rb +++ b/app/models/tournament.rb @@ -8,6 +8,8 @@ class Tournament < ActiveRecord::Base alias_attribute :stages, :tournament_stages + before_save { self.status ||= 0 } + # Settings ################################################################# def settings |