fix isolated scope versus $scope issue for tagQuery