FIX: Skip notifications about beginner badges (#12819)

This commit is contained in:
Andrei Prigorshnev
2021-04-26 11:41:51 +04:00
committed by GitHub
parent 886f4b589e
commit f7aeb257ee
3 changed files with 34 additions and 11 deletions

View File

@ -305,6 +305,10 @@ class Badge < ActiveRecord::Base
end
end
def for_beginners?
id == Welcome || (badge_grouping_id == BadgeGrouping::GettingStarted && id != NewUserOfTheMonth)
end
protected
def ensure_not_system