mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 09:46:28 +08:00
util: remove node_modules/ in errMsg
This commit is contained in:
1 parent
561c4d4175
commit
cc6e623413
4 files changed
+11
-5
No files matched your search
@@ -1,10 +1,14 @@
|
||||
/* eslint-disable no-empty-function */
|
||||
/* eslint-disable class-methods-use-this */
|
||||
import { NotFoundError } from '../error';
|
||||
import { Route, Handler } from '../service/server';
|
||||
import {
|
||||
Route, Handler, param, Types,
|
||||
} from '../service/server';
|
||||
|
||||
class NotFoundHandler extends Handler {
|
||||
prepare() {
|
||||
@param('bsod', Types.Boolean)
|
||||
prepare(domainId: string, bsod: boolean) {
|
||||
if (bsod) throw new Error(this.request.path);
|
||||
throw new NotFoundError(this.request.path);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user