PluginProbe
ThinkRank AI SEO – AI SEO Plugin for WordPress: Schema, XML Sitemaps, Meta Tags, Search Console & Local SEO / 2.14.3
ThinkRank AI SEO – AI SEO Plugin for WordPress: Schema, XML Sitemaps, Meta Tags, Search Console & Local SEO v2.14.3
2.14.3 2.14.2 2.14.1 2.14.0 2.13.0 2.12.0 2.11.0 2.10.0 2.9.0 2.8.0 2.7.0 2.6.0 2.5.0 2.4.0 2.3.0 2.2.0 2.1.1 2.1.0 2.0.2 2.0.1 2.0.0 1.32.0 1.31.0 1.30.0 1.29.0 All 58 releases
← All changes | includes/core/class-capability-manager.php +6 -0 2.7.0 → 2.14.3 View file →
@@ -307,8 +307,14 @@
307 307 * @param string $route Full REST route (e.g. /thinkrank/v1/schema/...).
308 308 * @return string
309 309 */
310 310 public static function capability_for_route(string $route): string {
311 + // Routes match case-insensitively in WP_REST_Server, and every key in
312 + // route_map() and settings_category_map() is lowercase, so a section
313 + // spelled /SiteMap/ must resolve to the same capability as /sitemap/
314 + // rather than fall back to the base access cap (#975).
315 + $route = strtolower($route);
316 +
311 317 // Settings-management categories resolve by category rather than by
312 318 // prefix — see settings_category_map() for why this one route differs.
313 319 if (preg_match('#/thinkrank(?:-pro)?/v1/settings-management/category/([a-zA-Z0-9_-]+)#', $route, $c)) {
314 320 return self::capability_for_settings_category($c[1]);