From e682468eb3c9459b827b5a57cf95f0d39f9cec47 Mon Sep 17 00:00:00 2001 From: Dave Disser Date: Sun, 31 May 2015 15:09:19 -0700 Subject: [PATCH] Move trial_run check to after gilded & and distinguished check, since these comments would erroneously be indicated for deletion by trial mode. --- shreddit.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/shreddit.py b/shreddit.py index 88ed10d..b780bf1 100755 --- a/shreddit.py +++ b/shreddit.py @@ -123,15 +123,16 @@ for thing in things: thing.id in whitelist_ids: continue + if whitelist_distinguished and thing.distinguished: + continue + if whitelist_gilded and thing.gilded: + continue + if trial_run: # Don't do anything, trial mode! if verbose: print("Would have deleted {thing}: '{content}'".format( thing=thing.id, content=thing)) continue - if whitelist_distinguished and thing.distinguished: - continue - if whitelist_gilded and thing.gilded: - continue if clear_vote: thing.clear_vote()