From 54657e5dc7228df443ab99a419b5fee091277373 Mon Sep 17 00:00:00 2001 From: FreeScout Date: Sat, 5 Dec 2020 09:59:45 -0800 Subject: [PATCH] Fix deactivating licenses --- app/Http/Controllers/ModulesController.php | 2 +- public/js/main.js | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/ModulesController.php b/app/Http/Controllers/ModulesController.php index eac2302d..a0de0aca 100644 --- a/app/Http/Controllers/ModulesController.php +++ b/app/Http/Controllers/ModulesController.php @@ -388,7 +388,7 @@ class ModulesController extends Controller $params = [ 'license' => $license, 'module_alias' => $alias, - 'url' => \App\Module::getAppUrl(), + 'url' => (!empty($request->any_url) ? '*' : \App\Module::getAppUrl()), ]; $result = WpApi::deactivateLicense($params); diff --git a/public/js/main.js b/public/js/main.js index 53b5dd68..3d2b7f97 100644 --- a/public/js/main.js +++ b/public/js/main.js @@ -470,7 +470,8 @@ function deactivateLicenseModal(modal) { action: 'deactivate_license', alias: $('.deactivate-license-module:visible:first').val(), - license: $('.deactivate-license-key:visible:first').val() + license: $('.deactivate-license-key:visible:first').val(), + any_url: 1, }, laroute.route('modules.ajax'), function(response) {