From 5bc0403d9c9a42300613bd3382522856ec1996f2 Mon Sep 17 00:00:00 2001 From: AlanCoding Date: Wed, 18 May 2016 15:18:27 -0400 Subject: [PATCH] add spaces around euality operator --- awx/api/serializers.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/awx/api/serializers.py b/awx/api/serializers.py index 377b640fbc..f7ddf6e36a 100644 --- a/awx/api/serializers.py +++ b/awx/api/serializers.py @@ -2286,10 +2286,10 @@ class JobLaunchSerializer(BaseSerializer): # Special prohibited cases for scan jobs if 'job_type' in data and obj.ask_job_type_on_launch: - if ((obj.job_type==PERM_INVENTORY_SCAN and not data['job_type']==PERM_INVENTORY_SCAN) or - (data['job_type']==PERM_INVENTORY_SCAN and not obj.job_type==PERM_INVENTORY_SCAN)): + if ((obj.job_type == PERM_INVENTORY_SCAN and not data['job_type'] == PERM_INVENTORY_SCAN) or + (data['job_type'] == PERM_INVENTORY_SCAN and not obj.job_type == PERM_INVENTORY_SCAN)): errors['job_type'] = 'Can not override job_type to or from a scan job.' - if (obj.job_type==PERM_INVENTORY_SCAN and ('inventory' in data) and obj.ask_inventory_on_launch and + if (obj.job_type == PERM_INVENTORY_SCAN and ('inventory' in data) and obj.ask_inventory_on_launch and obj.inventory != data['inventory']): errors['inventory'] = 'Inventory can not be changed at runtime for scan jobs.'