mirror of
https://github.com/luxfi/pics.git
synced 2026-10-30 15:22:15 +00:00
10 lines
309 B
JavaScript
10 lines
309 B
JavaScript
'use strict';
|
|
|
|
module.exports = async(db, redis) => {
|
|
console.log('moving globalsettings from redis into mongodb');
|
|
const oldSettings = await redis.get('globalsettings');
|
|
if (oldSettings) {
|
|
await db.collection('globalsettings').replaceOne({ _id: 'globalsettings' }, oldSettings, { upsert: true });
|
|
}
|
|
};
|