It was found that when the client has a large number of synthetic scripts the algorithm fails because it only performs a search on the first 50 elements.
Steps to Reproduce
Reproducing the bug requires a customer with more than 50 Synthetic Scripts in their account.
The search algorithm fails, and instead of updating the existing script, it tries to create a new one with the same name, which is why the creation attempt fails.
Solution
save the script id in the Pathpoint storage
Then, instead of doing a general search, try to read the data from the Synthetic Script using the previously saved ID
file to fix: /nerdlets/pathpoint-nerdlet/services/SynConnector.js
add in the header
import { AccountStorageQuery, AccountStorageMutation } from 'nr1';
Description
It was found that when the client has a large number of synthetic scripts the algorithm fails because it only performs a search on the first 50 elements.
Steps to Reproduce
Reproducing the bug requires a customer with more than 50 Synthetic Scripts in their account. The search algorithm fails, and instead of updating the existing script, it tries to create a new one with the same name, which is why the creation attempt fails.
Solution
file to fix: /nerdlets/pathpoint-nerdlet/services/SynConnector.js
add in the header
Add the next function
Update this function ExistFlameScript()
Add the. SetFlameScript function to CreateFlameScript()