DEPRECATION WARNING: Using return
, break
or throw
to exit a transaction block
#2197
Labels
return
, break
or throw
to exit a transaction block
#2197
Hi
We hit this problem when upgrade rails to 6.1.4, found the error! function throw it, please help. Thanks
DEPRECATION WARNING: Using
return
,break
orthrow
to exit a transaction block isdeprecated without replacement. If the
throw
came fromTimeout.timeout(duration)
, pass an exception class as a secondargument so it doesn't use
throw
to abort its block. This resultsin the transaction being committed, but in the next release of Rails
it will rollback.
The text was updated successfully, but these errors were encountered: