need to allow for now scope
This commit is contained in:
parent
60ba9dcc5e
commit
3f67f91d27
|
@ -72,7 +72,7 @@ class CategorySerializer < BasicCategorySerializer
|
|||
end
|
||||
|
||||
def notification_level
|
||||
user = scope.user
|
||||
user = scope && scope.user
|
||||
object.notification_level ||
|
||||
(user && CategoryUser.where(user: user, category: object).first.try(:notification_level))
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue