Moved config from server to shared (#11850)
* moved `server/config` to `shared/config` * updated config import paths in server to use shared * updated config import paths in frontend to use shared * updated config import paths in test to use shared * updated config import paths in root to use shared * trigger regression tests * of course the rebase broke tests
This commit is contained in:
parent
c3e1e559e6
commit
15d9a77092
@ -8,7 +8,7 @@
|
||||
|
||||
require('./core/server/overrides');
|
||||
|
||||
const config = require('./core/server/config');
|
||||
const config = require('./core/shared/config');
|
||||
const urlService = require('./core/frontend/services/url');
|
||||
const _ = require('lodash');
|
||||
const fs = require('fs-extra');
|
||||
|
@ -1,4 +1,4 @@
|
||||
const config = require('./core/server/config');
|
||||
const config = require('./core/shared/config');
|
||||
const ghostVersion = require('./core/server/lib/ghost-version');
|
||||
|
||||
/**
|
||||
|
@ -3,7 +3,7 @@ const url = require('url');
|
||||
const session = require('cookie-session');
|
||||
const crypto = require('crypto');
|
||||
const path = require('path');
|
||||
const config = require('../../../../server/config');
|
||||
const config = require('../../../../shared/config');
|
||||
const urlUtils = require('../../../../server/lib/url-utils');
|
||||
const constants = require('../../../../server/lib/constants');
|
||||
const {i18n} = require('../../../../server/lib/common');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const crypto = require('crypto');
|
||||
const config = require('../../server/config');
|
||||
const config = require('../../shared/config');
|
||||
const {blogIcon} = require('../../server/lib/image');
|
||||
const urlUtils = require('../../server/lib/url-utils');
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
const config = require('../../server/config');
|
||||
const config = require('../../shared/config');
|
||||
const escapeExpression = require('../services/themes/engine').escapeExpression;
|
||||
const socialUrls = require('@tryghost/social-urls');
|
||||
const _ = require('lodash');
|
||||
|
@ -2,7 +2,7 @@ const debug = require('ghost-ignition').debug('services:apps');
|
||||
const Promise = require('bluebird');
|
||||
const {logging, i18n} = require('../../../server/lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const loader = require('./loader');
|
||||
|
||||
module.exports = {
|
||||
|
@ -2,7 +2,7 @@ const path = require('path');
|
||||
const _ = require('lodash');
|
||||
const Promise = require('bluebird');
|
||||
const {i18n} = require('../../../server/lib/common');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const Proxy = require('./proxy');
|
||||
|
||||
// Get the full path to an app by name
|
||||
|
@ -6,7 +6,7 @@ const errors = require('@tryghost/errors');
|
||||
|
||||
const {i18n, logging} = require('../../server/lib/common');
|
||||
const settingsCache = require('../../server/services/settings/cache');
|
||||
const config = require('../../server/config');
|
||||
const config = require('../../shared/config');
|
||||
|
||||
// Direct requires:
|
||||
// - lodash
|
||||
|
@ -5,7 +5,7 @@ const moment = require('moment-timezone');
|
||||
|
||||
const validation = require('./validation');
|
||||
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const {i18n} = require('../../../server/lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
const debug = require('ghost-ignition').debug('services:routing:taxonomy-router');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const {events} = require('../../../server/lib/common');
|
||||
const ParentRouter = require('./ParentRouter');
|
||||
const RSSRouter = require('./RSSRouter');
|
||||
|
@ -1,6 +1,6 @@
|
||||
const debug = require('ghost-ignition').debug('services:routing:controllers:entry');
|
||||
const url = require('url');
|
||||
const config = require('../../../../server/config');
|
||||
const config = require('../../../../shared/config');
|
||||
const urlService = require('../../../services/url');
|
||||
const urlUtils = require('../../../../server/lib/url-utils');
|
||||
const helpers = require('../helpers');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const debug = require('ghost-ignition').debug('services:routing:controllers:preview');
|
||||
const config = require('../../../../server/config');
|
||||
const config = require('../../../../shared/config');
|
||||
const urlService = require('../../url');
|
||||
const urlUtils = require('../../../../server/lib/url-utils');
|
||||
const helpers = require('../helpers');
|
||||
|
@ -6,7 +6,7 @@ const _ = require('lodash');
|
||||
|
||||
const path = require('path');
|
||||
const url = require('url');
|
||||
const config = require('../../../../server/config');
|
||||
const config = require('../../../../shared/config');
|
||||
const themes = require('../../themes');
|
||||
const _private = {};
|
||||
|
||||
|
@ -4,7 +4,7 @@ const path = require('path');
|
||||
const urlService = require('../url');
|
||||
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
|
||||
/**
|
||||
* The `routes.yaml` file offers a way to configure your Ghost blog. It's currently a setting feature
|
||||
|
@ -4,7 +4,7 @@ const path = require('path');
|
||||
const debug = require('ghost-ignition').debug('frontend:services:settings:ensure-settings');
|
||||
const {i18n} = require('../../../server/lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
|
||||
/**
|
||||
* Makes sure that all supported settings files are in the
|
||||
|
@ -3,7 +3,7 @@ const path = require('path');
|
||||
const debug = require('ghost-ignition').debug('frontend:services:settings:settings-loader');
|
||||
const {i18n} = require('../../../server/lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const yamlParser = require('./yaml-parser');
|
||||
const validate = require('./validate');
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const Manager = require('./manager');
|
||||
const manager = new Manager();
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
const fs = require('fs-extra');
|
||||
const os = require('os');
|
||||
const path = require('path');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const security = require('../../../server/lib/security');
|
||||
const {compress} = require('@tryghost/zip');
|
||||
const LocalFileStorage = require('../../../server/adapters/storage/LocalFileStorage');
|
||||
|
@ -16,7 +16,7 @@ const join = require('path').join;
|
||||
const _ = require('lodash');
|
||||
const themeConfig = require('./config');
|
||||
const themeEngines = require('./engines');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const engine = require('./engine');
|
||||
|
||||
// Current instance of ActiveTheme
|
||||
|
@ -1,5 +1,5 @@
|
||||
const hbs = require('express-hbs');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const instance = hbs.create();
|
||||
|
||||
// @TODO think about a config option for this e.g. theme.devmode?
|
||||
|
@ -1,6 +1,6 @@
|
||||
const _ = require('lodash');
|
||||
const semver = require('semver');
|
||||
const config = require('../../../../server/config');
|
||||
const config = require('../../../../shared/config');
|
||||
const DEFAULTS = require('./defaults');
|
||||
const allowedKeys = ['ghost-api'];
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
const Promise = require('bluebird');
|
||||
const errors = require('@tryghost/errors');
|
||||
const hbs = require('../engine');
|
||||
const config = require('../../../../server/config');
|
||||
const config = require('../../../../shared/config');
|
||||
const {logging} = require('../../../../server/lib/common');
|
||||
|
||||
// Register an async handlebars helper for a given handlebars instance
|
||||
|
@ -1,7 +1,7 @@
|
||||
const errors = require('@tryghost/errors');
|
||||
const {i18n, events, logging} = require('../../../server/lib/common');
|
||||
const settingsCache = require('../../../server/services/settings/cache');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
|
||||
const jp = require('jsonpath');
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
const debug = require('ghost-ignition').debug('themes:loader');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const packageJSON = require('../../../server/lib/fs/package-json');
|
||||
const themeList = require('./list');
|
||||
let loadAllThemes;
|
||||
|
@ -1,7 +1,7 @@
|
||||
const _ = require('lodash');
|
||||
const hbs = require('./engine');
|
||||
const urlUtils = require('../../../server/lib/url-utils');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const {i18n} = require('../../../server/lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const settingsCache = require('../../../server/services/settings/cache');
|
||||
|
@ -1,7 +1,7 @@
|
||||
const _ = require('lodash');
|
||||
const Promise = require('bluebird');
|
||||
const fs = require('fs-extra');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const {i18n} = require('../../../server/lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
|
||||
|
@ -2,7 +2,7 @@ const _ = require('lodash');
|
||||
const Promise = require('bluebird');
|
||||
const debug = require('ghost-ignition').debug('services:url:resources');
|
||||
const Resource = require('./Resource');
|
||||
const config = require('../../../server/config');
|
||||
const config = require('../../../shared/config');
|
||||
const models = require('../../../server/models');
|
||||
const {events} = require('../../../server/lib/common');
|
||||
|
||||
|
@ -6,7 +6,7 @@ const fs = require('fs-extra');
|
||||
const path = require('path');
|
||||
const Promise = require('bluebird');
|
||||
const moment = require('moment');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const {logging, i18n} = require('../../lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const constants = require('../../lib/constants');
|
||||
|
@ -1,6 +1,6 @@
|
||||
const _ = require('lodash');
|
||||
const Analytics = require('analytics-node');
|
||||
const config = require('./config');
|
||||
const config = require('../shared/config');
|
||||
const {events} = require('./lib/common');
|
||||
|
||||
module.exports.init = function () {
|
||||
|
@ -1,5 +1,5 @@
|
||||
const api = require('./index');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const {i18n} = require('../../lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const web = require('../../web');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const {isPlainObject} = require('lodash');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const labs = require('../../services/labs');
|
||||
const ghostVersion = require('../../lib/ghost-version');
|
||||
|
||||
|
@ -3,7 +3,7 @@
|
||||
const Promise = require('bluebird');
|
||||
const moment = require('moment-timezone');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const models = require('../../models');
|
||||
const membersService = require('../../services/members');
|
||||
const settingsCache = require('../../services/settings/cache');
|
||||
|
@ -7,7 +7,7 @@ const membersService = require('../../services/members');
|
||||
const allowedIncludes = ['tags', 'authors', 'authors.roles', 'email'];
|
||||
const unsafeAttrs = ['status', 'authors', 'visibility'];
|
||||
const _ = require('lodash');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
|
||||
module.exports = {
|
||||
docName: 'posts',
|
||||
|
@ -1,6 +1,6 @@
|
||||
const _ = require('lodash');
|
||||
const moment = require('moment');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const models = require('../../models');
|
||||
const urlUtils = require('../../lib/url-utils');
|
||||
const {i18n} = require('../../lib/common');
|
||||
|
@ -1,7 +1,7 @@
|
||||
const ghostVersion = require('../../lib/ghost-version');
|
||||
const settingsCache = require('../../services/settings/cache');
|
||||
const urlUtils = require('../../lib/url-utils');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
|
||||
const site = {
|
||||
docName: 'site',
|
||||
|
@ -1,6 +1,6 @@
|
||||
const _ = require('lodash');
|
||||
const localUtils = require('../../../index');
|
||||
const config = require('../../../../../../config');
|
||||
const config = require('../../../../../../../shared/config');
|
||||
|
||||
const tag = (attrs, frame) => {
|
||||
if (localUtils.isContentAPI(frame)) {
|
||||
|
@ -6,7 +6,7 @@ const gating = require('./post-gating');
|
||||
const clean = require('./clean');
|
||||
const extraAttrs = require('./extra-attrs');
|
||||
const postsMetaSchema = require('../../../../../../data/schema').tables.posts_meta;
|
||||
const config = require('../../../../../../config');
|
||||
const config = require('../../../../../../../shared/config');
|
||||
|
||||
const mapUser = (model, frame) => {
|
||||
const jsonModel = model.toJSON ? model.toJSON(frame.options) : model;
|
||||
|
@ -1,5 +1,5 @@
|
||||
const jsonSchema = require('../utils/json-schema');
|
||||
const config = require('../../../../../config');
|
||||
const config = require('../../../../../../shared/config');
|
||||
const {i18n} = require('../../../../../lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {imageSize, blogIcon} = require('../../../../../lib/image');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const api = require('./index');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const {i18n} = require('../../lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const web = require('../../web');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const {isPlainObject} = require('lodash');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const labs = require('../../services/labs');
|
||||
const ghostVersion = require('../../lib/ghost-version');
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
const _ = require('lodash');
|
||||
const moment = require('moment');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const models = require('../../models');
|
||||
const urlUtils = require('../../lib/url-utils');
|
||||
const {i18n} = require('../../lib/common');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const jsonSchema = require('../utils/json-schema');
|
||||
const config = require('../../../../../config');
|
||||
const config = require('../../../../../../shared/config');
|
||||
const {i18n} = require('../../../../../lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {imageSize, blogIcon} = require('../../../../../lib/image');
|
||||
|
@ -4,7 +4,7 @@ const fs = require('fs-extra');
|
||||
|
||||
const path = require('path');
|
||||
const Promise = require('bluebird');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const {logging} = require('../../lib/common');
|
||||
const urlUtils = require('../../lib/url-utils');
|
||||
const exporter = require('../exporter');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const knex = require('knex');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const {logging} = require('../../lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
let knexInstance;
|
||||
|
@ -1,5 +1,5 @@
|
||||
const KnexMigrator = require('knex-migrator');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const errors = require('@tryghost/errors');
|
||||
|
||||
const knexMigrator = new KnexMigrator({
|
||||
|
@ -1,7 +1,7 @@
|
||||
const _ = require('lodash');
|
||||
const Promise = require('bluebird');
|
||||
const path = require('path');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const urlUtils = require('../../../lib/url-utils');
|
||||
const storage = require('../../../adapters/storage');
|
||||
let ImageHandler;
|
||||
|
@ -1,6 +1,6 @@
|
||||
const path = require('path');
|
||||
const fs = require('fs-extra');
|
||||
const config = require('../../../../config');
|
||||
const config = require('../../../../../shared/config');
|
||||
const {logging} = require('../../../../lib/common');
|
||||
const models = require('../../../../models');
|
||||
const message1 = 'Removing `globals.permalinks` from routes.yaml.';
|
||||
|
@ -2,7 +2,7 @@ const _ = require('lodash');
|
||||
const Promise = require('bluebird');
|
||||
const {logging} = require('../../../../lib/common');
|
||||
const settingsCache = require('../../../../services/settings/cache');
|
||||
const config = require('../../../../config');
|
||||
const config = require('../../../../../shared/config');
|
||||
const moment = require('moment');
|
||||
const fs = require('fs-extra');
|
||||
const path = require('path');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const {logging} = require('../../../../lib/common');
|
||||
const config = require('../../../../config');
|
||||
const config = require('../../../../../shared/config');
|
||||
const {URL} = require('url');
|
||||
|
||||
module.exports.config = {
|
||||
|
@ -6,7 +6,7 @@ const Promise = require('bluebird');
|
||||
const fs = require('fs-extra');
|
||||
const path = require('path');
|
||||
const _ = require('lodash');
|
||||
const config = require('./config');
|
||||
const config = require('../shared/config');
|
||||
const urlUtils = require('./lib/url-utils');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {events, i18n, logging} = require('./lib/common');
|
||||
|
@ -11,7 +11,7 @@ require('./overrides');
|
||||
|
||||
const debug = require('ghost-ignition').debug('boot:init');
|
||||
const Promise = require('bluebird');
|
||||
const config = require('./config');
|
||||
const config = require('../shared/config');
|
||||
const {events, i18n, logging} = require('./lib/common');
|
||||
const migrator = require('./data/db/migrator');
|
||||
const urlUtils = require('./lib/url-utils');
|
||||
|
@ -1,4 +1,4 @@
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const {logging} = require('ghost-ignition');
|
||||
|
||||
module.exports = logging({
|
||||
|
@ -2,7 +2,7 @@ const sizeOf = require('image-size');
|
||||
const Promise = require('bluebird');
|
||||
const _ = require('lodash');
|
||||
const path = require('path');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const {i18n} = require('../common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const urlUtils = require('../../lib/url-utils');
|
||||
|
@ -1,6 +1,6 @@
|
||||
const Promise = require('bluebird');
|
||||
const crypto = require('crypto');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const request = require('../request');
|
||||
|
||||
module.exports.lookup = function lookup(userData, timeout) {
|
||||
|
@ -8,7 +8,7 @@ const request = require('../request');
|
||||
const urlUtils = require('../../lib/url-utils');
|
||||
const {i18n} = require('../common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const storage = require('../../adapters/storage');
|
||||
const storageUtils = require('../../adapters/storage/utils');
|
||||
const validator = require('../../data/validation').validator;
|
||||
|
@ -1,6 +1,6 @@
|
||||
const errors = require('@tryghost/errors');
|
||||
const {logging} = require('./common');
|
||||
const config = require('../config');
|
||||
const config = require('../../shared/config');
|
||||
|
||||
let cardFactory;
|
||||
let cards;
|
||||
|
@ -1,5 +1,5 @@
|
||||
const UrlUtils = require('@tryghost/url-utils');
|
||||
const config = require('../config');
|
||||
const config = require('../../shared/config');
|
||||
const mobiledoc = require('./mobiledoc');
|
||||
|
||||
const urlUtils = new UrlUtils({
|
||||
|
@ -13,7 +13,7 @@ const moment = require('moment');
|
||||
const Promise = require('bluebird');
|
||||
const ObjectId = require('bson-objectid');
|
||||
const debug = require('ghost-ignition').debug('models:base');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const db = require('../../data/db');
|
||||
const {logging, events, i18n} = require('../../lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
|
@ -2,7 +2,7 @@ const ghostBookshelf = require('./base');
|
||||
const uuid = require('uuid');
|
||||
const _ = require('lodash');
|
||||
const sequence = require('../lib/promise/sequence');
|
||||
const config = require('../config');
|
||||
const config = require('../../shared/config');
|
||||
const crypto = require('crypto');
|
||||
|
||||
const Member = ghostBookshelf.Model.extend({
|
||||
|
@ -8,7 +8,7 @@ const {i18n} = require('../lib/common');
|
||||
const errors = require('@tryghost/errors');
|
||||
const htmlToText = require('html-to-text');
|
||||
const ghostBookshelf = require('./base');
|
||||
const config = require('../config');
|
||||
const config = require('../../shared/config');
|
||||
const settingsCache = require('../services/settings/cache');
|
||||
const mobiledocLib = require('../lib/mobiledoc');
|
||||
const relations = require('./relations');
|
||||
|
@ -1,6 +1,6 @@
|
||||
const AdapterManager = require('@tryghost/adapter-manager');
|
||||
const getAdapterServiceConfig = require('./config');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
|
||||
const adapterManager = new AdapterManager({
|
||||
loadAdapterFromPath: require,
|
||||
|
@ -1,7 +1,7 @@
|
||||
const jwt = require('express-jwt');
|
||||
const membersService = require('../../members');
|
||||
const labs = require('../../labs');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
|
||||
let UNO_MEMBERINO;
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
const session = require('express-session');
|
||||
const constants = require('../../../lib/constants');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const settingsCache = require('../../settings/cache');
|
||||
const models = require('../../../models');
|
||||
const urlUtils = require('../../../lib/url-utils');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const _ = require('lodash');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {i18n, logging} = require('../../lib/common');
|
||||
const models = require('../../models');
|
||||
|
@ -2,7 +2,7 @@ const _ = require('lodash');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {i18n, logging} = require('../../lib/common');
|
||||
const mailgunProvider = require('./mailgun');
|
||||
const configService = require('../../config');
|
||||
const configService = require('../../../shared/config');
|
||||
const settingsCache = require('../settings/cache');
|
||||
const sentry = require('../../../shared/sentry');
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
const {URL} = require('url');
|
||||
const mailgun = require('mailgun-js');
|
||||
const {logging} = require('../../lib/common');
|
||||
const configService = require('../../config');
|
||||
const configService = require('../../../shared/config');
|
||||
const settingsCache = require('../settings/cache');
|
||||
|
||||
function createMailgun(config) {
|
||||
|
@ -3,7 +3,7 @@
|
||||
const _ = require('lodash');
|
||||
const Promise = require('bluebird');
|
||||
const validator = require('validator');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {i18n} = require('../../lib/common');
|
||||
const settingsCache = require('../settings/cache');
|
||||
|
@ -7,7 +7,7 @@ const membersService = require('../members');
|
||||
const bulkEmailService = require('../bulk-email');
|
||||
const models = require('../../models');
|
||||
const postEmailSerializer = require('./post-email-serializer');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
|
||||
const getEmailData = async (postModel, members = []) => {
|
||||
const {emailTmpl, replacements} = await postEmailSerializer.serialize(postModel);
|
||||
|
@ -1,6 +1,6 @@
|
||||
const _ = require('lodash');
|
||||
const {logging} = require('../../lib/common');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const labsService = require('../labs');
|
||||
const membersService = require('./index');
|
||||
const urlUtils = require('../../lib/url-utils');
|
||||
|
@ -1,6 +1,6 @@
|
||||
const _ = require('lodash');
|
||||
const xml = require('xml');
|
||||
const config = require('../config');
|
||||
const config = require('../../shared/config');
|
||||
const urlService = require('../../frontend/services/url');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {events, i18n, logging} = require('../lib/common');
|
||||
|
@ -16,7 +16,7 @@ const _ = require('lodash');
|
||||
const url = require('url');
|
||||
const debug = require('ghost-ignition').debug('update-check');
|
||||
const api = require('./api').v2;
|
||||
const config = require('./config');
|
||||
const config = require('../shared/config');
|
||||
const urlUtils = require('./lib/url-utils');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {i18n, logging} = require('./lib/common');
|
||||
|
@ -1,7 +1,7 @@
|
||||
const debug = require('ghost-ignition').debug('web:admin:app');
|
||||
const express = require('../../../shared/express');
|
||||
const serveStatic = express.static;
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const constants = require('../../lib/constants');
|
||||
const urlUtils = require('../../lib/url-utils');
|
||||
const shared = require('../shared');
|
||||
|
@ -1,6 +1,6 @@
|
||||
const debug = require('ghost-ignition').debug('web:admin:controller');
|
||||
const path = require('path');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const updateCheck = require('../../update-check');
|
||||
const {logging} = require('../../lib/common');
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
const cloneDeep = require('lodash/cloneDeep');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const {logging} = require('../../../lib/common');
|
||||
const imageTransform = require('@tryghost/image-transform');
|
||||
|
||||
|
@ -3,7 +3,7 @@ const os = require('os');
|
||||
const multer = require('multer');
|
||||
const fs = require('fs-extra');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const {i18n,logging} = require('../../../lib/common');
|
||||
|
||||
const upload = {
|
||||
|
@ -1,7 +1,7 @@
|
||||
const debug = require('ghost-ignition').debug('web:parent');
|
||||
const express = require('../../../shared/express');
|
||||
const vhost = require('@tryghost/vhost-middleware');
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const compress = require('compression');
|
||||
const netjet = require('netjet');
|
||||
const mw = require('./middleware');
|
||||
|
@ -2,7 +2,7 @@ const moment = require('moment');
|
||||
const extend = require('lodash/extend');
|
||||
const pick = require('lodash/pick');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../../config');
|
||||
const config = require('../../../../../shared/config');
|
||||
const {logging,i18n} = require('../../../../lib/common');
|
||||
const spam = config.get('spam') || {};
|
||||
|
||||
|
@ -3,7 +3,7 @@ const express = require('../../../../shared/express');
|
||||
const url = require('url');
|
||||
const path = require('path');
|
||||
const debug = require('ghost-ignition').debug('web:shared:mw:custom-redirects');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const urlUtils = require('../../../lib/url-utils');
|
||||
const errors = require('@tryghost/errors');
|
||||
const {logging, i18n} = require('../../../lib/common');
|
||||
|
@ -2,7 +2,7 @@ const hbs = require('express-hbs');
|
||||
const _ = require('lodash');
|
||||
const debug = require('ghost-ignition').debug('error-handler');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const {i18n} = require('../../../lib/common');
|
||||
const helpers = require('../../../../frontend/services/routing/helpers');
|
||||
const sentry = require('../../../../shared/sentry');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const {i18n} = require('../../../lib/common');
|
||||
const urlService = require('../../../../frontend/services/url');
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
// @TODO optimise this to reduce the number of redirects required to get to a pretty URL
|
||||
// @TODO move this to being used by routers?
|
||||
const slashes = require('connect-slashes');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
|
||||
module.exports = [
|
||||
slashes(true, {
|
||||
|
@ -6,7 +6,7 @@ const {URL} = require('url');
|
||||
const errors = require('@tryghost/errors');
|
||||
|
||||
// App requires
|
||||
const config = require('../../config');
|
||||
const config = require('../../../shared/config');
|
||||
const constants = require('../../lib/constants');
|
||||
const storage = require('../../adapters/storage');
|
||||
const urlService = require('../../../frontend/services/url');
|
||||
|
@ -1,5 +1,5 @@
|
||||
const express = require('../../../../shared/express');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const urlUtils = require('../../../lib/url-utils');
|
||||
|
||||
const adminRedirect = (path) => {
|
||||
|
@ -1,7 +1,7 @@
|
||||
const fs = require('fs-extra');
|
||||
const path = require('path');
|
||||
const crypto = require('crypto');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const {blogIcon} = require('../../../lib/image');
|
||||
const storage = require('../../../adapters/storage');
|
||||
const urlUtils = require('../../../lib/url-utils');
|
||||
|
@ -2,7 +2,7 @@ const crypto = require('crypto');
|
||||
const fs = require('fs-extra');
|
||||
const path = require('path');
|
||||
const errors = require('@tryghost/errors');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const urlUtils = require('../../../lib/url-utils');
|
||||
const {i18n} = require('../../../lib/common');
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
const path = require('path');
|
||||
const config = require('../../../config');
|
||||
const config = require('../../../../shared/config');
|
||||
const constants = require('../../../lib/constants');
|
||||
const themeUtils = require('../../../../frontend/services/themes');
|
||||
const express = require('../../../../shared/express');
|
||||
|
@ -1,4 +1,4 @@
|
||||
const config = require('../server/config');
|
||||
const config = require('./config');
|
||||
const sentryConfig = config.get('sentry');
|
||||
|
||||
const expressNoop = function (req, res, next) {
|
||||
|
@ -3,7 +3,7 @@ const Promise = require('bluebird');
|
||||
const supertest = require('supertest');
|
||||
const testUtils = require('../../utils');
|
||||
const localUtils = require('./utils');
|
||||
const config = require('../../../core/server/config');
|
||||
const config = require('../../../core/shared/config');
|
||||
const ghost = testUtils.startGhost;
|
||||
|
||||
let request;
|
||||
|
@ -2,7 +2,7 @@ const should = require('should');
|
||||
const supertest = require('supertest');
|
||||
const testUtils = require('../../utils');
|
||||
const localUtils = require('./utils');
|
||||
const config = require('../../../core/server/config');
|
||||
const config = require('../../../core/shared/config');
|
||||
const ghost = testUtils.startGhost;
|
||||
|
||||
let request;
|
||||
|
@ -2,7 +2,7 @@ const path = require('path');
|
||||
const should = require('should');
|
||||
const supertest = require('supertest');
|
||||
const sinon = require('sinon');
|
||||
const config = require('../../../core/server/config');
|
||||
const config = require('../../../core/shared/config');
|
||||
const common = require('../../../core/server/lib/common');
|
||||
const testUtils = require('../../utils');
|
||||
const localUtils = require('./utils');
|
||||
|
@ -3,7 +3,7 @@ const supertest = require('supertest');
|
||||
const ObjectId = require('bson-objectid');
|
||||
const testUtils = require('../../utils');
|
||||
const localUtils = require('./utils');
|
||||
const config = require('../../../core/server/config');
|
||||
const config = require('../../../core/shared/config');
|
||||
const models = require('../../../core/server/models/index');
|
||||
|
||||
const ghost = testUtils.startGhost;
|
||||
|
@ -1,7 +1,7 @@
|
||||
const should = require('should');
|
||||
const supertest = require('supertest');
|
||||
const testUtils = require('../../utils');
|
||||
const config = require('../../../core/server/config');
|
||||
const config = require('../../../core/shared/config');
|
||||
const localUtils = require('./utils');
|
||||
|
||||
const ghost = testUtils.startGhost;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user