From e1567ba7c52774f32b9dcc9ae4625038fc84a709 Mon Sep 17 00:00:00 2001 From: Sylvain Date: Wed, 13 Apr 2016 13:05:16 +0200 Subject: [PATCH] [bug taiga#25] allow event update if removing nb places --- app/models/event.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/event.rb b/app/models/event.rb index 22e04ab3f..b28b8b0ba 100644 --- a/app/models/event.rb +++ b/app/models/event.rb @@ -86,7 +86,7 @@ class Event < ActiveRecord::Base end def update_nb_free_places - unless nb_total_places_was.nil? + unless nb_total_places_was.nil? or nb_total_places.nil? diff = nb_total_places - nb_total_places_was self.nb_free_places += diff end