500 error regarding query after update
-
After updating to version 8 I got a fatal error in regards to a query in another plugin. That seems rather unexpected.
Here the error:Fatal error: Uncaught Error: Call to a member function get() on null in /wp-includes/query.php:28 Stack trace: #0 /wp-content/plugins/mapper-plugin/inc/query.php(35): get_query_var('mlat', false) #1 /wp-includes/class-wp-hook.php(305): MapperPlugin\Query->posts_join(' INNER JOIN imL...') #2 /wp-includes/plugin.php(233): WP_Hook->apply_filters(' INNER JOIN imL...', Array) #3 /wp-includes/class-wp-query.php(2578): apply_filters_ref_array('posts_join', Array) #4 /wp-includes/class-wp-query.php(3465): WP_Query->get_posts() #5 /wp-includes/class-wp-query.php(3576): WP_Query->query(Array) #6 /wp-content/plugins/better-wp-security/core/modules/dashboard/setup.php(57): WP_Query->__construct(Array) #7 /wp-includes/query.php on line 28
The Plugin code around line 35 is:
public function posts_join($join) { global $wpdb; $lat = \get_query_var( 'mlat', false ); //line 35 $lat = \get_query_var( 'mlng', false ); if ($lat && $lng) { $join .= "LEFT JOIN {cache->table()} AS mapper_cache ON {$wpdb->posts}.ID = mapper_cache.post_id "; } return $join; }
What is happening?
Cheers Sascha
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘500 error regarding query after update’ is closed to new replies.