Skip to content

Commit 7fc20a4

Browse files
committed
fix controller camel2id
1 parent c35a980 commit 7fc20a4

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

components/AuthHelper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ private static function getControllerRoutes($module, $namespace, $prefix, &$resu
342342
}
343343
elseif ( strcmp(substr($file, -14), 'Controller.php') === 0 )
344344
{
345-
$id = Inflector::camel2id(substr(basename($file), 0, -14));
345+
$id = Inflector::camel2id(substr(basename($file), 0, -14), '-', true);
346346
$className = $namespace . Inflector::id2camel($id) . 'Controller';
347347
if ( strpos($className, '-') === false && class_exists($className) && is_subclass_of($className, 'yii\base\Controller') )
348348
{

0 commit comments

Comments
 (0)