From 33b2ee9255addbc098c3fa81401d75eeee4ff1a7 Mon Sep 17 00:00:00 2001
From: Pierre-Yves Chibon <pingou@pingoured.fr>
Date: May 04 2015 15:35:22 +0000
Subject: If works with `==` not `=`


---

diff --git a/pagure/hooks/files/fedmsg_hook.py b/pagure/hooks/files/fedmsg_hook.py
index 89a93eb..d595678 100755
--- a/pagure/hooks/files/fedmsg_hook.py
+++ b/pagure/hooks/files/fedmsg_hook.py
@@ -60,7 +60,7 @@ seen = []
 for line in sys.stdin.readlines():
     (oldrev, newrev, refname) = line.strip().split(' ', 2)
 
-    if set(newrev) = set(['0']):
+    if set(newrev) == set(['0']):
             print "Deleting a reference/branch, so we won't run the "\
                 "pagure hook"
             return
diff --git a/pagure/hooks/files/pagure_hook.py b/pagure/hooks/files/pagure_hook.py
index b971819..98b12da 100755
--- a/pagure/hooks/files/pagure_hook.py
+++ b/pagure/hooks/files/pagure_hook.py
@@ -153,7 +153,7 @@ def run_as_post_receive_hook():
         print '  -- Ref name'
         print refname
 
-        if set(newrev) = set(['0']):
+        if set(newrev) == set(['0']):
             print "Deleting a reference/branch, so we won't run the "\
                 "pagure hook"
             return
diff --git a/pagure/hooks/files/pagure_hook_requests.py b/pagure/hooks/files/pagure_hook_requests.py
index 9d2b8cd..49d5233 100755
--- a/pagure/hooks/files/pagure_hook_requests.py
+++ b/pagure/hooks/files/pagure_hook_requests.py
@@ -56,7 +56,7 @@ def run_as_post_receive_hook():
         print '  -- Ref name'
         print refname
 
-        if set(newrev) = set(['0']):
+        if set(newrev) == set(['0']):
             print "Deleting a reference/branch, so we won't run the "\
                 "pagure hook"
             return
diff --git a/pagure/hooks/files/pagure_hook_tickets.py b/pagure/hooks/files/pagure_hook_tickets.py
index 5c708a7..5e464a7 100755
--- a/pagure/hooks/files/pagure_hook_tickets.py
+++ b/pagure/hooks/files/pagure_hook_tickets.py
@@ -56,7 +56,7 @@ def run_as_post_receive_hook():
         print '  -- Ref name'
         print refname
 
-        if set(newrev) = set(['0']):
+        if set(newrev) == set(['0']):
             print "Deleting a reference/branch, so we won't run the "\
                 "pagure hook"
             return