mirror of
https://github.com/dbeaver/cloudbeaver.git
synced 2026-09-24 16:04:36 +08:00
CB-5255. Fixed cb error when you tried delete node twice, return error from database (#2828)
Co-authored-by: Evgenia Bezborodova <139753579+EvgeniaBzzz@users.noreply.github.com>
This commit is contained in:
co-authored by
Evgenia Bezborodova
parent
afb4ea205c
commit
5d071e5dfd
+6
-1
@@ -530,7 +530,12 @@ public class WebServiceNavigator implements DBWServiceNavigator {
|
||||
DBCExecutionContext executionContext = getCommandExecutionContext(object);
|
||||
DBECommandContext commandContext = new WebCommandContext(executionContext, false);
|
||||
ne.getValue().deleteObject(commandContext, object, options);
|
||||
commandContext.saveChanges(session.getProgressMonitor(), options);
|
||||
try {
|
||||
commandContext.saveChanges(session.getProgressMonitor(), options);
|
||||
} catch (DBException e) {
|
||||
commandContext.resetChanges(true);
|
||||
throw e;
|
||||
}
|
||||
} else if (node instanceof DBNLocalFolder) {
|
||||
var nodePath = node.getNodeItemPath();
|
||||
node.getOwnerProject().getDataSourceRegistry().removeFolder(((DBNLocalFolder) node).getFolder(), false);
|
||||
|
||||
Reference in New Issue
Block a user