fixed bugs in badwords handling