mirror of
https://github.com/QuiteAFancyEmerald/Holy-Unblocker.git
synced 2025-05-13 03:50:02 -04:00
Fixed a simple mistake
This commit is contained in:
parent
15b1c88788
commit
cc11c39b67
2 changed files with 8 additions and 8 deletions
13
app.js
13
app.js
|
@ -4,8 +4,7 @@
|
||||||
* MIT license: http://opensource.org/licenses/MIT
|
* MIT license: http://opensource.org/licenses/MIT
|
||||||
* ----------------------------------------------- */
|
* ----------------------------------------------- */
|
||||||
const
|
const
|
||||||
char_insert = require('./src/charinsert.js'),
|
alloy = require('./src/alloyproxy'),
|
||||||
alloy = require('./src/alloyproxy'),
|
|
||||||
path = require('path'),
|
path = require('path'),
|
||||||
config = require('./config.json'),
|
config = require('./config.json'),
|
||||||
fs = require('fs'),
|
fs = require('fs'),
|
||||||
|
@ -126,11 +125,11 @@ function tryReadFile(file) {
|
||||||
|
|
||||||
// Local alloy proxy
|
// Local alloy proxy
|
||||||
const localAlloy = new alloy({
|
const localAlloy = new alloy({
|
||||||
prefix: '/fetch/',
|
prefix: '/fetch/',
|
||||||
error: (proxy) => { proxy.res.send(tryReadFile(path.normalize(__dirname + '/views/error.html')).replace('%ERR%', proxy.error.info.message.replace(/<|>/g, ''))); }, // Doing replace functions on "<" and ">" to prevent XSS.
|
error: (proxy) => { proxy.res.send(tryReadFile(path.normalize(__dirname + '/views/error.html')).replace('%ERR%', proxy.error.info.message.replace(/<|>/g, ''))); }, // Doing replace functions on "<" and ">" to prevent XSS.
|
||||||
request: [],
|
request: [],
|
||||||
response: [],
|
response: [],
|
||||||
injection: true
|
injection: true
|
||||||
});
|
});
|
||||||
app.use(localAlloy.app);
|
app.use(localAlloy.app);
|
||||||
localAlloy.ws(server);
|
localAlloy.ws(server);
|
||||||
|
|
|
@ -16,6 +16,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"express": "^4.17.1",
|
"express": "^4.17.1",
|
||||||
"mime-types": "^2.1.27"
|
"mime-types": "^2.1.27",
|
||||||
|
"ws": "^7.4.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue