mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-19 20:06:00 +00:00
export model WIP
This commit is contained in:
@@ -95,4 +95,13 @@ module.exports = {
|
||||
});
|
||||
});
|
||||
},
|
||||
|
||||
async getNewArchiveFolder({ database }) {
|
||||
if (!(await fs.exists(path.join(archivedir(), database)))) return database;
|
||||
let index = 2;
|
||||
while (await fs.exists(path.join(archivedir(), `${database}${index}`))) {
|
||||
index += 1;
|
||||
}
|
||||
return `${database}${index}`;
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user