_ajaxSuccess: function(data) {
if (data.returnValues.queueID) {
- UiDialog.close(this);
+ if (UiDialog.isOpen(this)) {
+ UiDialog.close(this);
+ }
var installation = new window.WCF.ACP.Package.Installation(data.returnValues.queueID, undefined, false);
installation.prepareInstallation();
// there are no available package update servers
if (empty($availableUpdateServers)) {
- WCF::getTPL()->assign(['packageUpdates' => []]);
+ WCF::getTPL()->assign([
+ 'thirdPartySources' => [],
+ 'trustedSources' => [],
+ ]);
return ['count' => 0, 'pageCount' => 0, 'searchID' => 0, 'template' => WCF::getTPL()->fetch('packageSearchResultList')];
}
// no matches found
if (empty($packageUpdateIDs)) {
- WCF::getTPL()->assign(['packageUpdates' => []]);
+ WCF::getTPL()->assign([
+ 'thirdPartySources' => [],
+ 'trustedSources' => [],
+ ]);
return ['count' => 0, 'pageCount' => 0, 'searchID' => 0, 'template' => WCF::getTPL()->fetch('packageSearchResultList')];
}
// no matches found
if (empty($packageUpdates)) {
- WCF::getTPL()->assign(['packageUpdates' => []]);
+ WCF::getTPL()->assign([
+ 'thirdPartySources' => [],
+ 'trustedSources' => [],
+ ]);
return ['count' => 0, 'pageCount' => 0, 'searchID' => 0, 'template' => WCF::getTPL()->fetch('packageSearchResultList')];
}