summaryrefslogtreecommitdiff
path: root/app/models
diff options
context:
space:
mode:
Diffstat (limited to 'app/models')
-rw-r--r--app/models/sent_notification.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/models/sent_notification.rb b/app/models/sent_notification.rb
index fd12615717b..03108da17be 100644
--- a/app/models/sent_notification.rb
+++ b/app/models/sent_notification.rb
@@ -62,6 +62,10 @@ class SentNotification < ActiveRecord::Base
end
end
+ def can_unsubscribe?
+ !for_commit?
+ end
+
def for_commit?
noteable_type == "Commit"
end