fix: remove
This commit is contained in:
parent
35f1182aec
commit
23ca75e870
2
.gitignore
vendored
2
.gitignore
vendored
@ -1 +1,3 @@
|
|||||||
node_modules
|
node_modules
|
||||||
|
|
||||||
|
dist
|
@ -26,6 +26,7 @@ router.add(removeRouter);
|
|||||||
|
|
||||||
// add router
|
// add router
|
||||||
export const addRouter = new Route('admin', 'addRouter');
|
export const addRouter = new Route('admin', 'addRouter');
|
||||||
|
|
||||||
addRouter.run = async (ctx) => {
|
addRouter.run = async (ctx) => {
|
||||||
const { path, key } = ctx.query;
|
const { path, key } = ctx.query;
|
||||||
router.add(new Route(path, key));
|
router.add(new Route(path, key));
|
||||||
@ -38,7 +39,7 @@ router.add(addRouter);
|
|||||||
export const updateRouter = new Route('admin', 'updateRouter');
|
export const updateRouter = new Route('admin', 'updateRouter');
|
||||||
updateRouter.run = async (ctx) => {
|
updateRouter.run = async (ctx) => {
|
||||||
const { path, key } = ctx.query;
|
const { path, key } = ctx.query;
|
||||||
// router.update(path, key);
|
router.add(new Route(path, key));
|
||||||
ctx.body = 'success';
|
ctx.body = 'success';
|
||||||
return ctx;
|
return ctx;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user