diff options
Diffstat (limited to 'app/models/participant.rb')
-rw-r--r-- | app/models/participant.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/models/participant.rb b/app/models/participant.rb index 205bd2c..dff6160 100644 --- a/app/models/participant.rb +++ b/app/models/participant.rb @@ -16,7 +16,7 @@ # License along with ECS. If not, see <http://www.gnu.org/licenses/>. -class Participant < ActiveRecord::Base +class Participant < ApplicationRecord TTL = 1.hour # how long an anonymous participant lives TYPE={ :main => "main", :sub => "sub", :anonym => "anonym" } @@ -162,7 +162,7 @@ class Participant < ActiveRecord::Base private def delete_messages - Message.destroy_all(["sender = ?", self.id]) + Message.where(["sender = ?", self.id]).destroy_all end end |