Fix minor bug in paste_post method

Make a variable that was global local when an error
is thrown.
This commit is contained in:
Robin Malley 2022-06-26 22:52:58 +00:00
parent 77d8c0e66b
commit a0c8907f71
1 changed files with 1 additions and 1 deletions

View File

@ -51,7 +51,7 @@ local function anon_paste(req,ps)
util.sqlbind(stmnt_paste,"bind_blob",5,"")
util.sqlbind(stmnt_paste,"bind",6,ps.unlisted)
util.sqlbind(stmnt_paste,"bind_blob",7,textsha3)
err = util.do_sql(stmnt_paste)
local err = util.do_sql(stmnt_paste)
stmnt_paste:reset()
if err == sql.DONE then
local rowid = stmnt_paste:last_insert_rowid()