Fix admin slot deletion (quite possibly the dumbest fucking bug in existence)

This commit is contained in:
jvyden 2022-03-22 18:22:25 -04:00
commit fb4d29eb43
No known key found for this signature in database
GPG key ID: 18BCF2BE0262B278

View file

@ -1,5 +1,4 @@
#nullable enable
using System;
using System.Threading.Tasks;
using LBPUnion.ProjectLighthouse.Types;
using LBPUnion.ProjectLighthouse.Types.Levels;
@ -60,8 +59,6 @@ public class AdminSlotController : ControllerBase
Slot? slot = await this.database.Slots.FirstOrDefaultAsync(s => s.SlotId == id);
if (slot == null) return this.Ok();
if (slot.Location == null) throw new ArgumentNullException();
await this.database.RemoveSlot(slot);
return this.Ok();