Function to throw Error in suite script

Use the N/error module to create your own custom SuiteScript errors. Use these custom errors in try-catch statements to abort script execution. This module does not provide the functionality to throw custom errors, however, your script can include logic to throw custom SuiteScript errors after they are created. Make sure that the throw function should… Continue reading Function to throw Error in suite script