WIP: Split up moon counter from the database #489

Draft
Vylpes wants to merge 16 commits from feature/300-moon-set into develop
Showing only changes of commit 10e51c8e90 - Show all commits

View file

@ -22,7 +22,9 @@ export default async function AddMoon(interaction: CommandInteraction) {
await moonSetting.Save(UserSetting, moonSetting); await moonSetting.Save(UserSetting, moonSetting);
const moon = new Moon(moonCount + 1, description, interaction.user.id); const allMoons = await Moon.FetchMoonCountByUserId(interaction.user.id);
const moon = new Moon(allMoons + 1, description, interaction.user.id);
await moon.Save(Moon, moon); await moon.Save(Moon, moon);