From c56177cd10d76390486ce972a2588f47098e1a52 Mon Sep 17 00:00:00 2001 From: nilsding Date: Sun, 14 Dec 2014 14:49:14 +0100 Subject: [PATCH] we don't need this --- app/models/notification.rb | 2 +- app/models/notifications/question_answered.rb | 3 --- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/app/models/notification.rb b/app/models/notification.rb index 20e9ebfe..0c681579 100644 --- a/app/models/notification.rb +++ b/app/models/notification.rb @@ -1,6 +1,6 @@ class Notification < ActiveRecord::Base belongs_to :recipient, class_name: 'User' - belongs_to :target, :polymorphic => true + belongs_to :target, polymorphic: true class << self def for(recipient, options={}) diff --git a/app/models/notifications/question_answered.rb b/app/models/notifications/question_answered.rb index 15b2cadf..f93ffd45 100644 --- a/app/models/notifications/question_answered.rb +++ b/app/models/notifications/question_answered.rb @@ -1,5 +1,2 @@ class Notifications::QuestionAnswered < Notification - def linked_object - Answer.where(id: self.target_id).first - end end \ No newline at end of file