Remove unneeded variable
This commit is contained in:
parent
13fa84be3a
commit
7d9133008a
|
@ -90,12 +90,10 @@ func GenerateName() string {
|
|||
Check(err)
|
||||
defer db.Close()
|
||||
// query database if id exists and if it does call generateName again
|
||||
query, err := db.Query("select id from pastebin where id=?", id)
|
||||
_, err = db.Query("select id from pastebin where id=?", id)
|
||||
if err != sql.ErrNoRows {
|
||||
for query.Next() {
|
||||
GenerateName()
|
||||
}
|
||||
}
|
||||
|
||||
return id
|
||||
|
||||
|
|
Loading…
Reference in New Issue