fixes for scss and autoloading

Signed-off-by: Andy Miller <rhuk@mac.com>
This commit is contained in:
Andy Miller
2025-12-29 02:59:32 -07:00
parent 6c0349ac4c
commit c5cb89338e
3 changed files with 73 additions and 15 deletions

View File

@@ -1323,15 +1323,16 @@ class AdminController extends AdminBaseController
$result = Gpm::install(array_keys($dependencies), ['theme' => $type === 'themes']);
if ($result) {
$this->admin->json_response = ['status' => 'success', 'message' => 'Dependencies installed successfully'];
$json_response = ['status' => 'success', 'message' => 'Dependencies installed successfully'];
} else {
$this->admin->json_response = [
$json_response = [
'status' => 'error',
'message' => $this->admin::translate('PLUGIN_ADMIN.INSTALLATION_FAILED')
];
}
return true;
// Exit early to prevent any post-install code from running with potentially mismatched autoloaders
$this->sendJsonResponse($json_response);
}
/**
@@ -1376,19 +1377,20 @@ class AdminController extends AdminBaseController
}
if ($result) {
$this->admin->json_response = [
$json_response = [
'status' => 'success',
'message' => $this->admin::translate(is_string($result) ? $result : sprintf($this->admin::translate($reinstall ?: 'PLUGIN_ADMIN.PACKAGE_X_REINSTALLED_SUCCESSFULLY',
null), $package))
];
} else {
$this->admin->json_response = [
$json_response = [
'status' => 'error',
'message' => $this->admin::translate($reinstall ?: 'PLUGIN_ADMIN.INSTALLATION_FAILED')
];
}
return true;
// Exit early to prevent any post-install code from running with potentially mismatched autoloaders
$this->sendJsonResponse($json_response);
}
/**
@@ -1501,19 +1503,20 @@ class AdminController extends AdminBaseController
$result = Gpm::directInstall($url);
if ($result === true) {
$this->admin->json_response = [
$json_response = [
'status' => 'success',
'message' => $this->admin::translate(sprintf($this->admin::translate('PLUGIN_ADMIN.PACKAGE_X_REINSTALLED_SUCCESSFULLY',
null), $package_name))
];
} else {
$this->admin->json_response = [
$json_response = [
'status' => 'error',
'message' => $this->admin::translate('PLUGIN_ADMIN.REINSTALLATION_FAILED')
];
}
return true;
// Exit early to prevent any post-install code from running with potentially mismatched autoloaders
$this->sendJsonResponse($json_response);
}
/**