Skip to content

Commit ce8735d

Browse files
committed
Return the result of the transaction function being applied
1 parent 4e33f5b commit ce8735d

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/DBInterface.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,8 +166,9 @@ performance in database systems.
166166
function transaction(f, conn::Connection)
167167
execute(conn, "BEGIN TRANSACTION;")
168168
try
169-
f()
169+
ret = f()
170170
execute(conn, "COMMIT;")
171+
return ret
171172
catch e
172173
execute(conn, "ROLLBACK;")
173174
rethrow(e)

0 commit comments

Comments
 (0)