From a6f714a1e91141515c238f1547ca198f39102be5 Mon Sep 17 00:00:00 2001 From: David John Date: Sun, 9 Oct 2016 21:51:33 +0100 Subject: [PATCH] Fix string module error --- shreddit.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/shreddit.py b/shreddit.py index 4252070..bf9fc96 100755 --- a/shreddit.py +++ b/shreddit.py @@ -8,7 +8,6 @@ import json import yaml import praw import random -import string from re import sub from datetime import datetime, timedelta @@ -75,10 +74,10 @@ whitelist = config.get('whitelist', []) whitelist_ids = config.get('whitelist_ids', []) if whitelist: + whitelist = set([subr.lower() for subr in whitelist]) log.debug("Keeping messages from subreddits {subs}".format( subs=', '.join(whitelist)) ) - whitelist = set([string.lower(subr) for subr in whitelist]) def get_sentence():