I created a custom error object by extending the Error class like so,
class GeneralError extends Error { constructor(value) { super(value) } getErr