Some bot changes and stuff

This commit is contained in:
RussellChamp committed 2015-11-24 12:56:18 -05:00
1 parent 94127052c9
commit ebb5f2fe37
9 files changed
+61 -44

No files matched your search

+2 -1
View File
@@ -31,7 +31,8 @@ with open(logfile, "r") as log:
continue #We don't care what they say
if time >= timeCutoff and time <= timeTo:
#print "Processing line from " + user + " at " + str(time)
for word in re.sub('[\'\"\`\/\\;:,.?!*&^\-()<>|_\[\]0-9]', '', message).lower().split():
for word in re.sub('[\'\"\`\/\\;:,.?!*&^\-()<>\{\}|_\[\]0-9]', ' ', message).lower().split():
#changing symbols into spaces instead of stripping them avoids compounded words
if len(word) < minLength or word in bannedWords:
#print "Rejecting " + word
continue