Skip to content

Commit

Permalink
UIU-2955 - add a header comment to escapeSpecialCharactersInTagFilter…
Browse files Browse the repository at this point in the history
…s function
  • Loading branch information
Terala-Priyanka committed Nov 9, 2023
1 parent 6a9e3a3 commit b3b191b
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/routes/UserSearchContainer.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,15 @@ const searchFields = [
];
const compileQuery = template(`(${searchFields.join(' or ')})`, { interpolate: /%{([\s\S]+?)}/g });

/*
Some of the special characters that are allowed while creating a tag are "", \, *, ?
These special characters cause CQL exceptions while searching the user records, which are
assigned with such tags.
This function "escapeSpecialCharactersInTagFilters" intends to escape the special characters
in filters of type "Tags"
Ref: https://issues.folio.org/browse/UIU-2995
*/

const escapeSpecialCharactersInTagFilters = (queryParams, resourceData) => {
const newResourceData = cloneDeep(resourceData);
let escapedFilters;
Expand Down

0 comments on commit b3b191b

Please sign in to comment.