fix(client >> storage): fixed sql query to enable entry overriding

This commit is contained in:
antifallobst 2024-03-31 23:40:07 +02:00
parent 9bac0c2a78
commit af3952cbe6
Signed by: antifallobst
GPG Key ID: 2B4F402172791BAF
1 changed files with 1 additions and 1 deletions

View File

@ -53,7 +53,7 @@ impl Storage for StandardStorage {
return Err(StorageError::IdCollision(id.to_string())); return Err(StorageError::IdCollision(id.to_string()));
} }
sqlx::query(r#"INSERT INTO Entries VALUES (?, ?);"#) sqlx::query(r#"INSERT OR REPLACE INTO Entries VALUES (?, ?);"#)
.bind(id) .bind(id)
.bind(&data) .bind(&data)
.execute(&self.pool) .execute(&self.pool)