compatibility fix for new version

This commit is contained in:
Thomas Günther 2024-09-22 21:46:14 +02:00
parent 9318732f07
commit 3cbb6415b6
2 changed files with 3 additions and 3 deletions

View File

@ -55,8 +55,8 @@ add_action('admin_menu', function () {
});
add_action('wp_ajax_kompass_show_ajax', 'kompass_load_ajax_content');
add_action('wp_ajax_nopriv_kompass_show_ajax', 'kompass_load_ajax_content');
add_action('wp_ajax_bdp_kompass_show_ajax', 'bdp_kompass_load_ajax_content');
add_action('wp_ajax_nopriv_bdp_kompass_show_ajax', 'bdp_kompass_load_ajax_content');
function register_custom_theme_directory() {
if (is_dir(ABSPATH . '/wp-content/themes/mareike-theme/')) {

View File

@ -70,7 +70,7 @@ function kompass_get_age(string $birthday) : int {
return $compare->y;
}
function kompass_load_ajax_content() {
function bdp_kompass_load_ajax_content() {
$class = 'Bdp\\Modules\\' . $_REQUEST['module'] . '\\Controllers\\AjaxRouterController';
if (!class_exists($class)) {
wp_die('Invalid module call: Module=' . $_REQUEST['module']);