mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 14:52:15 +00:00
Don't use len, use count
This commit is contained in:
@@ -117,7 +117,7 @@ def send_message(application, message_type, note=None):
|
|||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
if installed('reddit') and len(application.user.redditaccount_set.all()) > 0:
|
if installed('reddit') and application.user.redditaccount_set.count():
|
||||||
from reddit.tasks import send_reddit_message
|
from reddit.tasks import send_reddit_message
|
||||||
|
|
||||||
for account in application.user.redditaccount_set.all():
|
for account in application.user.redditaccount_set.all():
|
||||||
|
|||||||
Reference in New Issue
Block a user