refactored some of onBeforeRequest-related code, removed ugly built-in exception re talkgadget