fix once of example module
This commit is contained in:
parent
daa38cdeab
commit
0f0626dc57
@ -1,7 +1,7 @@
|
||||
const express = require("express");
|
||||
const { NetHelperModule } = global.moduleApi;
|
||||
|
||||
const HTTPReverse = require("../components/http-reverse");
|
||||
const HTTPServer = require("../components/_http");
|
||||
|
||||
module.exports = class CustomAuthPage extends NetHelperModule {
|
||||
constructor () {
|
||||
@ -11,7 +11,7 @@ module.exports = class CustomAuthPage extends NetHelperModule {
|
||||
this.cauth = new this.statics.Operator("cauth", (argv) => {
|
||||
return argv.length === 2;
|
||||
}, (argv, self, syntaxTree) => {
|
||||
if (![HTTPReverse].includes(syntaxTree.Type)) {
|
||||
if (!(syntaxTree.Type.prototype instanceof HTTPServer)) {
|
||||
throw new SyntaxError("Unsupported type of server");
|
||||
}
|
||||
const [ login, password ] = argv;
|
||||
|
Loading…
Reference in New Issue
Block a user