Changed regex to strip out /. before query only