Fixed bug with target selector being treated as regex instead of String
Fix target selectors not being correctly replaced when at the end of the line