Skip to content

Commit

Permalink
Merge #809 from 2.x into 3.x
Browse files Browse the repository at this point in the history
  • Loading branch information
BalusC committed May 10, 2024
2 parents 9360976 + b07c715 commit 40da4a7
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,7 @@ OmniFaces.Unload = (function(Util, navigator, window) {
}

if (id == null) {
var form = Util.getFacesForm();

if (!form) {
if (!Util.getFacesForm()) {
return;
}

Expand All @@ -56,6 +54,7 @@ OmniFaces.Unload = (function(Util, navigator, window) {
}

try {
var form = Util.getFacesForm();
var url = form.action;
var query = OmniFaces.EVENT + "=unload&id=" + id + "&" + OmniFaces.VIEW_STATE_PARAM + "=" + encodeURIComponent(form[OmniFaces.VIEW_STATE_PARAM].value);
var contentType = "application/x-www-form-urlencoded";
Expand Down Expand Up @@ -105,4 +104,4 @@ OmniFaces.Unload = (function(Util, navigator, window) {

return self;

})(OmniFaces.Util, navigator, window);
})(OmniFaces.Util, navigator, window);

0 comments on commit 40da4a7

Please sign in to comment.