[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [gettor/master] Fix too many requests check



commit 64a9d4913179aa882286b31dd43e8dead2a9bba5
Author: hiro <hiro@xxxxxxxxxxxxxx>
Date:   Wed Oct 16 13:35:12 2019 +0200

    Fix too many requests check
---
 gettor/parse/email.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/gettor/parse/email.py b/gettor/parse/email.py
index 72d992d..ac3aa89 100644
--- a/gettor/parse/email.py
+++ b/gettor/parse/email.py
@@ -156,16 +156,16 @@ class EmailParser(object):
         num_requests = limit
 
         if hid.hexdigest() == self.settings.get('test_hid'):
-            return 0
+            return False
         else:
             num_requests = yield conn.get_num_requests(
                 id=hid.hexdigest(), service=request_service
             )
 
         if num_requests[0][0] < email_requests_limit:
-            return 0
+            return False
         else:
-            return 1
+            return True
 
 
     def parse(self, msg_str):

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits