We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 321a22d commit 9c4dfbaCopy full SHA for 9c4dfba
src/commands/Administration/resetserver.ts
@@ -101,7 +101,7 @@ const Resetserver: Command<Message> = {
101
.map(
102
(save) => `${client.config.serverpath}/${server.path}/saves/${save}`
103
);
104
- const latestSavePath = saves[0];
+ const latestSavePath = sortModifiedDate(saves)[0].path;
105
// if there are saves, back up latest and remove all after
106
if (latestSavePath) {
107
const latestSave = latestSavePath.slice(
0 commit comments