fix: copy mistake

This commit is contained in:
dragonmuffin 2024-08-17 17:40:33 +05:00
parent 5e86cf19a3
commit 80df2e2820

View file

@ -66,7 +66,7 @@ func (storage *SolutionStorage) ReadSolutionById(ctx context.Context, id int32)
}
func (storage *SolutionStorage) DeleteSolution(ctx context.Context, id int32) error {
query := storage.db.Rebind("UPDATE solutions SET expired_at=now() WHERE id = ?")
query := storage.db.Rebind("DELETE FROM solutions WHERE id=?")
_, err := storage.db.ExecContext(ctx, query, id)
if err != nil {
return storage.HandlePgErr(err)