docs: function handleStringAsError(err, errorMessage) {
    var fauxError = new Error();
    var fullStack = fauxError.stack.split('\n');
    var cleanedStack = fullStack.slice(0, 1).concat(fullStack.slice(4));
    var errChecked = '';
  
    if (isString(err)) {
      // Replace the generic error message with the user-provided string
      cleanedStack[0] = err;
    }
  
    errChecked = cleanedStack.join('\n');
  
    errorMessage.setMessage(errChecked);
  }