diff --git a/core/components/quickapi/elements/plugins/QuickApiRoute.php b/core/components/quickapi/elements/plugins/QuickApiRoute.php index 9c2a59d..a173c15 100644 --- a/core/components/quickapi/elements/plugins/QuickApiRoute.php +++ b/core/components/quickapi/elements/plugins/QuickApiRoute.php @@ -18,9 +18,9 @@ $pathRoot = $modx->getOption('quickapi.path_root', null, 'api/'); // If the identifier starts with the path root - if (substr($identifier, 0, 4) === $pathRoot) { + if (substr($identifier, 0, strlen($pathRoot)) === $pathRoot) { // Override the request alias $_REQUEST[$rAlias] = "quickapi-process"; $_REQUEST['_quickapi'] = str_replace('api/', '', $identifier); } -} \ No newline at end of file +}