22 lines
589 B
JavaScript
22 lines
589 B
JavaScript
import initLog from '../utills/log.js'
|
|
import { checkForFinishes, checkForMaps, checkForPlayers } from './sqlite2mongo/checks.js'
|
|
import postTasks from './sqlite2mongo/postTasks.js'
|
|
|
|
const log = initLog("sqlite2mongo")
|
|
|
|
/**
|
|
* This function handles the sqlite database provided by DDNet and
|
|
* migrates the data to mongodb.
|
|
* @module libs/database/sqlite2mongo
|
|
*/
|
|
async function sqlite2mongo() {
|
|
log("Checking for additions to 'ddnet.sqlite'...")
|
|
|
|
await checkForMaps()
|
|
await checkForPlayers()
|
|
await checkForFinishes()
|
|
|
|
await postTasks()
|
|
}
|
|
|
|
export default sqlite2mongo |