mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-21 09:52:06 +03:00
bd597db829
- This is part of the quest to separate the frontend and server & get rid of all the places where there are cross-requires - At the moment the settings cache is one big shared cache used by the frontend and server liberally - This change doesn't really solve the fundamental problems, as we still depend on events, and requires from inside frontend - However it allows us to control the misuse slightly better by getting rid of restricted requires and turning on that eslint ruleset
20 lines
686 B
JavaScript
20 lines
686 B
JavaScript
const config = require('../../../shared/config');
|
|
const logging = require('@tryghost/logging');
|
|
const db = require('../../data/db');
|
|
const settings = require('../../../shared/settings-cache');
|
|
const {EmailAnalyticsService} = require('@tryghost/email-analytics-service');
|
|
const EventProcessor = require('./lib/event-processor');
|
|
const MailgunProvider = require('@tryghost/email-analytics-provider-mailgun');
|
|
const queries = require('./lib/queries');
|
|
|
|
module.exports = new EmailAnalyticsService({
|
|
config,
|
|
logging,
|
|
settings,
|
|
eventProcessor: new EventProcessor({db, logging}),
|
|
providers: [
|
|
new MailgunProvider({config, settings, logging})
|
|
],
|
|
queries
|
|
});
|