Skip to content

Commit 556fe76

Browse files
committed
Rebase, allow deleting pending link object
1 parent 97ad7e0 commit 556fe76

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

0 Bytes
Binary file not shown.

src/DeepLinkModule/javasource/deeplink/actions/ExecuteDeeplink.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,18 +112,18 @@ public java.lang.Boolean executeAction() throws Exception
112112
LOG.error("Failed to execute deeplink " + link.getName(), e);
113113
return false;
114114
}
115+
116+
IContext sudoContext = getContext().createSudoClone();
115117

116118
//remove the pendinglink, unless it should be reused during this session..
117119
if (link.getUseAsHome()) { //do not remove if used as home.
118-
IContext sudoContext = getContext().createSudoClone();
119120
this.pendinglink.setSessionId(sudoContext, this.getContext().getSession().getId().toString());
120121
Core.commit(sudoContext, this.pendinglink.getMendixObject());
121122
}
122123
else {
123124
Core.delete(this.getContext(), this.pendinglink.getMendixObject());
124125
}
125126

126-
IContext sudoContext = getContext().createSudoClone();
127127
if(link.getTrackHitCount(sudoContext)) {
128128
//set hitcount (note, this might not be exact)
129129
link.setHitCount(sudoContext, link.getHitCount(sudoContext) + 1);

0 commit comments

Comments
 (0)