Fix bug with deprimarification

This commit is contained in:
zkldi
2021-09-07 12:54:23 +01:00
parent 89b36bfc22
commit a3512b1242
@@ -105,6 +105,8 @@ router.post(
* its score data.
*
* @param chartID - the chartID to deprimarify.
* @param game - The game this chart is on.
* @param songID - Alternatively, this will deprimarify all charts for this songID.
*
* @name POST /api/v1/admin/deprimarify
*/
@@ -157,7 +159,7 @@ router.post(
await coll.update(
{
chartID: req.body.chartID,
chartID: chart.chartID,
},
{
$set: {
@@ -169,7 +171,7 @@ router.post(
logger.info(`Emptying all calculated data for this chart.`);
await db.scores.update(
{ chartID: req.body.chartID },
{ chartID: chart.chartID },
{
$set: {
calculatedData: {},
@@ -182,7 +184,7 @@ router.post(
await db["personal-bests"].update(
{
chartID: req.body.chartID,
chartID: chart.chartID,
},
{
$set: {