reduce duplicate bonks received slightly

This commit is contained in:
Ted Unangst 2019-04-14 10:10:08 -04:00
parent 5d340cd1ab
commit 68c465c4ad
2 changed files with 2 additions and 2 deletions

View File

@ -218,7 +218,7 @@ func savedonk(url string, name, media string) *Donk {
}
func needxonk(userid int64, x *Honk) bool {
row := stmtFindXonk.QueryRow(userid, x.XID, x.What)
row := stmtFindXonk.QueryRow(userid, x.XID)
err := row.Scan(&x.ID)
if err == nil {
return false

View File

@ -1014,7 +1014,7 @@ func prepareStatements(db *sql.DB) {
if err != nil {
log.Fatal(err)
}
stmtFindXonk, err = db.Prepare("select honkid from honks where userid = ? and xid = ? and what = ?")
stmtFindXonk, err = db.Prepare("select honkid from honks where userid = ? and xid = ?")
if err != nil {
log.Fatal(err)
}