core: Underscores in tag names break tags

Fixing tag regular expression matching in TagHandler.
We are adding backslashes for the SQL search query but should remove
them when the regular expression is matched.

Change-Id: I0925cdba0ed34e3dc68a8396eca0b17589dfa853
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=949484
Signed-off-by: Eli Mesika <emesika@redhat.com>