diff --git a/server/src/workflow-management/classes/Generator.ts b/server/src/workflow-management/classes/Generator.ts index 5f19e47a..796b64c3 100644 --- a/server/src/workflow-management/classes/Generator.ts +++ b/server/src/workflow-management/classes/Generator.ts @@ -518,7 +518,14 @@ export class WorkflowGenerator { } } - + /** + * Generates a pair for navigating to the previous page. + * This function alone adds the pair to the workflow and notifies the client. + * It's safe to always add a go back action to the first rule in the workflow and do not check + * general conditions for adding a pair to the workflow. + * @param newUrl The previous page's url. + * @returns void + */ public onGoBack = (newUrl: string) => { //it's safe to always add a go back action to the first rule in the workflow this.workflowRecord.workflow[0].what.push({