0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-27 22:49:56 -05:00
ghost/core/server/services/newsletters/index.js

15 lines
529 B
JavaScript
Raw Normal View History

const NewslettersService = require('./service.js');
const SingleUseTokenProvider = require('../members/SingleUseTokenProvider');
const mail = require('../mail');
const models = require('../../models');
const urlUtils = require('../../../shared/url-utils');
const MAGIC_LINK_TOKEN_VALIDITY = 24 * 60 * 60 * 1000;
module.exports = new NewslettersService({
NewsletterModel: models.Newsletter,
mail,
singleUseTokenProvider: new SingleUseTokenProvider(models.SingleUseToken, MAGIC_LINK_TOKEN_VALIDITY),
urlUtils
});