mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-08 00:38:20 +00:00
#467 - Delete bean with unloaded version property throws OptimisticLockException
This commit is contained in:
1 parent
872f0e21cb
commit
a2ee0bfdbe
2 files changed
+21
-1
No files matched your search
@@ -528,7 +528,7 @@ public final class PersistRequestBean<T> extends PersistRequest implements BeanP
|
||||
* Check for optimistic concurrency exception.
|
||||
*/
|
||||
public final void checkRowCount(int rowCount) {
|
||||
if (rowCount != 1) {
|
||||
if (ConcurrencyMode.VERSION == concurrencyMode && rowCount != 1) {
|
||||
String m = Message.msg("persist.conc2", "" + rowCount);
|
||||
throw new OptimisticLockException(m, null, bean);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user