diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/db.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/db.go b/src/db.go index 884a365..0c2e04b 100644 --- a/src/db.go +++ b/src/db.go @@ -120,3 +120,11 @@ func dbGetChallengeByUUID(uuid string) (Challenge, error) { } return challenge, nil } + +func dbDeleteChallengeByUUID(uuid string) error { + query := fmt.Sprintf("DELETE FROM challenges WHERE uuid::text = '%s'", uuid) + + _, _ = db.Exec(query) + + return nil +} |