mirror of
https://github.com/strapi/strapi.git
synced 2025-12-02 18:13:16 +00:00
Fix spelling errors in error messages (#24501)
Changed 'occured' to 'occurred' in: - DatabaseError constructor - ApplicationError constructor - API error handler Authored-by: dollaransh17 <dollaransh17@users.noreply.github.com>
This commit is contained in:
parent
efac5b501f
commit
222401a886
@ -183,7 +183,7 @@ export function useAPIErrorHandler(
|
||||
* In that case we return a generic error message.
|
||||
*/
|
||||
if (!error.message) {
|
||||
return 'Unknown error occured.';
|
||||
return 'Unknown error occurred.';
|
||||
}
|
||||
|
||||
return formatError(err);
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
export default class DatabaseError extends Error {
|
||||
details: unknown;
|
||||
|
||||
constructor(message = 'A database error occured', details = {}) {
|
||||
constructor(message = 'A database error occurred', details = {}) {
|
||||
super();
|
||||
this.name = 'DatabaseError';
|
||||
this.message = message;
|
||||
|
||||
@ -17,7 +17,7 @@ class ApplicationError<
|
||||
message: TMessage;
|
||||
|
||||
constructor(
|
||||
message = 'An application error occured' as TMessage,
|
||||
message = 'An application error occurred' as TMessage,
|
||||
details: TDetails = {} as TDetails
|
||||
) {
|
||||
super();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user