mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-21 09:52:06 +03:00
6dc8d91ace
This reverts commit 80af56b530
.
- reverting temporarily so that all associated functionality can be merged in a single release
- creating email batch/recipient records without using them would cause inconsistent data
53 lines
767 B
JavaScript
53 lines
767 B
JavaScript
/**
|
|
* Dependencies
|
|
*/
|
|
|
|
const _ = require('lodash');
|
|
|
|
// enable event listeners
|
|
require('./base/listeners');
|
|
|
|
/**
|
|
* Expose all models
|
|
*/
|
|
exports = module.exports;
|
|
|
|
const models = [
|
|
'permission',
|
|
'post',
|
|
'role',
|
|
'settings',
|
|
'session',
|
|
'tag',
|
|
'tag-public',
|
|
'user',
|
|
'author',
|
|
'invite',
|
|
'webhook',
|
|
'integration',
|
|
'api-key',
|
|
'mobiledoc-revision',
|
|
'member',
|
|
'action',
|
|
'posts-meta',
|
|
'member-stripe-customer',
|
|
'stripe-customer-subscription',
|
|
'email',
|
|
'label',
|
|
'single-use-token'
|
|
];
|
|
|
|
function init() {
|
|
exports.Base = require('./base');
|
|
|
|
models.forEach(function (name) {
|
|
_.extend(exports, require('./' + name));
|
|
});
|
|
}
|
|
|
|
/**
|
|
* Expose `init`
|
|
*/
|
|
|
|
exports.init = init;
|