First commit
This commit is contained in:
19
framework/sync/switchDownloadedDatabaseFile.js
Normal file
19
framework/sync/switchDownloadedDatabaseFile.js
Normal file
@@ -0,0 +1,19 @@
|
||||
/*
|
||||
|
||||
Copyright (c) 2020, 2023, The Unified Company.
|
||||
|
||||
This code is part of Unify.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the ESA Software Community License - Strong Copyleft,
|
||||
|
||||
https://unifyjs.org
|
||||
|
||||
*/
|
||||
|
||||
import fse from "fs-extra";
|
||||
|
||||
|
||||
fse.copySync("./framework/db/index.sqlite", "./framework/db/backup"+Math.floor(Math.random() * 100)+".sqlite");
|
||||
|
||||
fse.copySync("./framework/db/uploaded_db.sqlite", "./framework/db/index.sqlite");
|
||||
Reference in New Issue
Block a user