mirror of
https://github.com/idanoo/gomatrixbot
synced 2025-07-22 16:39:11 +00:00
Fix counter
This commit is contained in:
parent
cc9d2d5aae
commit
5bac56f38a
1 changed files with 1 additions and 1 deletions
|
@ -30,7 +30,7 @@ func (db *Database) GetCounterFor(key string) (time.Time, error) {
|
|||
// UpdateCounterFor - Add counter
|
||||
func (db *Database) UpdateCounterFor(key string, timestamp time.Time) (int64, error) {
|
||||
exec, err := db.db.Exec(
|
||||
"REPLACE INTO `counter` (`key`, `timestamp`) VALUES (?,?)",
|
||||
"UPDATE `counter` SET `timestamp` = ? WHERE `key` = ?",
|
||||
key,
|
||||
timestamp,
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue