Skip to content

Commit

Permalink
Reduce call within Strings::startsWith
Browse files Browse the repository at this point in the history
  • Loading branch information
bajb committed Apr 18, 2019
1 parent ce8037c commit c493e8c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ResourceManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ protected static function _componentManager($fullClass, Dispatch $dispatch = nul
{
$trimNs = ltrim($namespace, '\\');
$len = strlen($trimNs);
if(Strings::startsWith($class, $trimNs) && $len > $prefixLen)
if(Strings::startsWith($class, $trimNs, true, $len) && $len > $prefixLen)
{
$maxPrefix = $trimNs;
$prefixLen = $len;
Expand Down

0 comments on commit c493e8c

Please sign in to comment.