mirror of
https://github.com/wassname/talk.git
synced 2026-07-29 11:28:24 +08:00
Fixed misplaced deps
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"presets": [
|
||||
["es2015", {modules: false}]
|
||||
["es2015", {"modules": false}]
|
||||
],
|
||||
"plugins": [
|
||||
"transform-class-properties",
|
||||
|
||||
+3
-3
@@ -126,6 +126,7 @@
|
||||
"inquirer": "^3.2.2",
|
||||
"inquirer-autocomplete-prompt": "^0.12.1",
|
||||
"ioredis": "3.1.4",
|
||||
"ip": "^1.1.5",
|
||||
"joi": "^13.0.0",
|
||||
"jsonwebtoken": "^8.0.0",
|
||||
"jwt-decode": "^2.2.0",
|
||||
@@ -143,6 +144,7 @@
|
||||
"morgan": "^1.9.0",
|
||||
"ms": "^2.0.0",
|
||||
"murmurhash-js": "^1.0.0",
|
||||
"name-all-modules-plugin": "^1.0.1",
|
||||
"node-emoji": "^1.8.1",
|
||||
"node-fetch": "^1.7.2",
|
||||
"nodemailer": "^2.6.4",
|
||||
@@ -195,6 +197,7 @@
|
||||
"url-search-params": "^0.9.0",
|
||||
"uuid": "^3.1.0",
|
||||
"webpack": "^3.10.0",
|
||||
"webpack-manifest-plugin": "^2.0.0-rc.2",
|
||||
"webpack-sources": "^1.0.1",
|
||||
"yaml-loader": "^0.4.0",
|
||||
"yamljs": "^0.2.10"
|
||||
@@ -216,19 +219,16 @@
|
||||
"eslint-plugin-mocha": "^4.11.0",
|
||||
"husky": "^0.14.3",
|
||||
"identity-obj-proxy": "^3.0.0",
|
||||
"ip": "^1.1.5",
|
||||
"jest": "^21.2.1",
|
||||
"jest-junit": "^3.6.0",
|
||||
"lint-staged": "^7.0.0",
|
||||
"mocha": "^3.1.2",
|
||||
"mocha-junit-reporter": "^1.12.1",
|
||||
"name-all-modules-plugin": "^1.0.1",
|
||||
"nightwatch": "^0.9.16",
|
||||
"nodemon": "^1.11.0",
|
||||
"selenium-standalone": "^6.11.0",
|
||||
"sinon": "^3.2.1",
|
||||
"sinon-chai": "^2.13.0",
|
||||
"webpack-manifest-plugin": "^2.0.0-rc.2",
|
||||
"yaml-lint": "^1.0.0"
|
||||
},
|
||||
"engines": {
|
||||
|
||||
+5
-4
@@ -13,6 +13,7 @@ const staticMiddleware = require('express-static-gzip');
|
||||
const { DISABLE_STATIC_SERVER } = require('../config');
|
||||
const { passport } = require('../services/passport');
|
||||
const { MOUNT_PATH } = require('../url');
|
||||
const url = require('url');
|
||||
const context = require('../middleware/context');
|
||||
|
||||
const router = express.Router();
|
||||
@@ -31,8 +32,8 @@ if (!DISABLE_STATIC_SERVER) {
|
||||
/**
|
||||
* Redirect old embed calls.
|
||||
*/
|
||||
const oldEmbed = path.resolve(MOUNT_PATH, 'embed.js');
|
||||
const newEmbed = path.resolve(MOUNT_PATH, 'static/embed.js');
|
||||
const oldEmbed = url.resolve(MOUNT_PATH, 'embed.js');
|
||||
const newEmbed = url.resolve(MOUNT_PATH, 'static/embed.js');
|
||||
router.get('/embed.js', (req, res) => {
|
||||
console.warn(
|
||||
`deprecation warning: ${oldEmbed} will be phased out soon, please replace calls from ${oldEmbed} to ${newEmbed}`
|
||||
@@ -132,9 +133,9 @@ if (process.env.NODE_ENV !== 'production') {
|
||||
router.get('/', async (req, res, next) => {
|
||||
try {
|
||||
await SetupService.isAvailable();
|
||||
return res.redirect('/admin/install');
|
||||
return res.redirect(url.resolve(MOUNT_PATH, 'admin/install'));
|
||||
} catch (e) {
|
||||
return res.redirect('/admin');
|
||||
return res.redirect(url.resolve(MOUNT_PATH, 'admin'));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user