Declare previously undeclared variable
This commit is contained in:
parent
9a0d625da4
commit
ea2e485638
|
@ -91,7 +91,7 @@ func GenerateName() string {
|
||||||
Check(err)
|
Check(err)
|
||||||
defer db.Close()
|
defer db.Close()
|
||||||
// query database if id exists and if it does call generateName again
|
// query database if id exists and if it does call generateName again
|
||||||
query, err = db.Query("select id from pastebin where id=?", id)
|
query, err := db.Query("select id from pastebin where id=?", id)
|
||||||
if err != sql.ErrNoRows {
|
if err != sql.ErrNoRows {
|
||||||
for query.Next() {
|
for query.Next() {
|
||||||
GenerateName()
|
GenerateName()
|
||||||
|
|
Loading…
Reference in New Issue