Browse code

Cleaning up svr4pkg commit fix for #7645

James Cammarata authored on 2014/06/10 00:48:06
Showing 1 changed files
... ...
@@ -209,18 +209,18 @@ def main():
209 209
             (rc, out, err) = package_uninstall(module, name, src, category)
210 210
             out = out[:75]
211 211
 
212
-	#Success,Warning,Interruption,Reboot all,Reboot this return codes
213
-    if rc is 0 or rc is 2 or rc is 3 or rc is 10 or rc is 20: 
212
+    # Success, Warning, Interruption, Reboot all, Reboot this return codes
213
+    if rc in (0, 2, 3, 10, 20):
214 214
         result['changed'] = True
215
-    #no install nor uninstall, or failed
215
+    # no install nor uninstall, or failed
216 216
     else:
217 217
         result['changed'] = False
218
-        
219
-    #Fatal error,Administration,Administration Interaction return codes
220
-    if rc is 1 or rc is 4 or rc is 5:
221
-    	result['failed'] = True
218
+
219
+    # Fatal error, Administration, Administration Interaction return codes
220
+    if rc in (1, 4 , 5):
221
+        result['failed'] = True
222 222
     else:
223
-    	result['failed'] = False
223
+        result['failed'] = False
224 224
 
225 225
     if out:
226 226
         result['stdout'] = out