use parent serializer method to avoid API browser job access check

This commit is contained in:
AlanCoding
2016-04-13 15:19:10 -04:00
parent 914918b5ae
commit dc37f00d0a
2 changed files with 4 additions and 3 deletions

View File

@@ -766,7 +766,7 @@ class JobTemplateAccess(BaseAccess):
self.check_license()
if obj.job_type == PERM_INVENTORY_SCAN:
self.check_license(feature='system_tracking')
if getattr(obj, 'survey_enabled', None):
if obj.survey_enabled:
self.check_license(feature='surveys')
# Super users can start any job