mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-27 04:43:12 +03:00
30b4eb07f7
- This is a first pass at getting a more logical structure. The focus is on moving from admin/frontend to client/server. - The location of the databases is highly important, this isn't expected to change again In the future - client/assets should probably become public/ - more stuff should be shared (helpers etc) - cleanup some confusion around tpl and views
18 lines
321 B
JavaScript
18 lines
321 B
JavaScript
var when = require('when');
|
|
|
|
module.exports = function (version, data) {
|
|
var importer;
|
|
|
|
try {
|
|
importer = require("./" + version);
|
|
} catch (ignore) {
|
|
// Zero effs given
|
|
}
|
|
|
|
if (!importer) {
|
|
return when.reject("No importer found");
|
|
}
|
|
|
|
return importer.importData(data);
|
|
};
|