mirror of
https://github.com/Joxit/docker-registry-ui.git
synced 2026-05-23 04:42:47 +00:00
fix(taglist-order): improve error handler when the order does not exists
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
export class DockerRegistryUIError extends Error {
|
||||
constructor(msg) {
|
||||
super(msg);
|
||||
this.isError = true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ export const taglistOrderVariants = (taglistOrder) => {
|
||||
} else if (TAGLIST_ORDER_REGEX.test(taglistOrder)) {
|
||||
return taglistOrder;
|
||||
}
|
||||
throw new DockerRegistryUIError(`The order \`${taglistOrder}\` is not recognized.`);
|
||||
throw new DockerRegistryUIError(`The taglist order \`${taglistOrder}\` is not recognized.`);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user