diff options
Diffstat (limited to 'site/app/models/agenda.rb')
-rw-r--r-- | site/app/models/agenda.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/site/app/models/agenda.rb b/site/app/models/agenda.rb index 5580828..c15b12e 100644 --- a/site/app/models/agenda.rb +++ b/site/app/models/agenda.rb @@ -52,7 +52,9 @@ class Agenda < ActiveRecord::Base end def self.current - Agenda.state_is_not(:old).first + result = Agenda.state_is_not(:old).first + result = Agenda.create! unless result + result end def self.transitions_available(user) |