@nymphjs/nymph
Version:
Nymph.js - Nymph ORM
20 lines • 451 B
JavaScript
export class QueryFailedError extends Error {
query;
constructor(message, query) {
super(message);
this.name = 'QueryFailedError';
this.query = query;
}
getQuery() {
return this.query;
}
toJSON() {
if (process.env.NODE_ENV !== 'production') {
return this;
}
return {
name: this.name,
};
}
}
//# sourceMappingURL=QueryFailedError.js.map