Skip to content

Commit

Permalink
Added missing underscore in front of private property #20267
Browse files Browse the repository at this point in the history
  • Loading branch information
jrajamaki committed Oct 19, 2024
1 parent 8a0992d commit 02ef942
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions framework/base/Widget.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class Widget extends Component implements ViewContextInterface
/**
* @var string[] used widget classes that have been resolved to their actual class name.
*/
private static $resolvedClasses = [];
private static $_resolvedClasses = [];

/**
* Initializes the object.
Expand Down Expand Up @@ -92,7 +92,7 @@ public static function begin($config = [])
/* @var $widget Widget */
$widget = Yii::createObject($config);
self::$stack[] = $widget;
self::$resolvedClasses[get_called_class()] = get_class($widget);
self::$_resolvedClasses[get_called_class()] = get_class($widget);

Check warning on line 95 in framework/base/Widget.php

View check run for this annotation

Codecov / codecov/patch

framework/base/Widget.php#L95

Added line #L95 was not covered by tests

return $widget;
}
Expand All @@ -109,7 +109,7 @@ public static function end()
if (!empty(self::$stack)) {
$widget = array_pop(self::$stack);

$calledClass = self::$resolvedClasses[get_called_class()] ?? get_called_class();
$calledClass = self::$_resolvedClasses[get_called_class()] ?? get_called_class();

Check warning on line 112 in framework/base/Widget.php

View check run for this annotation

Codecov / codecov/patch

framework/base/Widget.php#L112

Added line #L112 was not covered by tests

if (get_class($widget) === $calledClass) {
/* @var $widget Widget */
Expand Down

0 comments on commit 02ef942

Please sign in to comment.