Skip to content

Commit

Permalink
Merge branch '4.12' of https://github.com/craftcms/cms into 5.4
Browse files Browse the repository at this point in the history
# Conflicts:
#	CHANGELOG-WIP.md
#	composer.lock
  • Loading branch information
brandonkelly committed Aug 29, 2024
2 parents 5d14bed + 859f974 commit 715b7c4
Show file tree
Hide file tree
Showing 6 changed files with 113 additions and 28 deletions.
1 change: 1 addition & 0 deletions CHANGELOG-WIP.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,5 @@
- MySQL mutex locks and PHP session names are now namespaced using the application ID combined with the environment name. ([#15313](https://github.com/craftcms/cms/issues/15313))
- Added support for “City/Town” address locality labels. ([#15585](https://github.com/craftcms/cms/pull/15585))
- `x-craft-preview` and `x-craft-live-preview` params are now hashed, and `craft\web\Request::getIsPreview()` will only return `true` if the param validates. ([#15605](https://github.com/craftcms/cms/discussions/15605))
- Updated Twig to 3.12. ([#15568](https://github.com/craftcms/cms/discussions/15568))
- Fixed styling issues. ([#15537](https://github.com/craftcms/cms/pull/15537))
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
"symfony/var-dumper": "^5.0|^6.0",
"symfony/yaml": "^5.2.3",
"theiconic/name-parser": "^1.2",
"twig/twig": "~3.8.0",
"twig/twig": "~3.12.0",
"voku/stringy": "^6.4.0",
"web-auth/webauthn-lib": "~4.9.0",
"webonyx/graphql-php": "~14.11.5",
Expand Down
129 changes: 106 additions & 23 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/helpers/Template.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
use craft\web\View;
use Twig\Environment;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Source;
Expand All @@ -25,7 +26,6 @@
use yii\base\UnknownPropertyException;
use yii\db\Query;
use yii\db\QueryInterface;
use function twig_get_attribute;

/**
* Class Template
Expand Down Expand Up @@ -145,7 +145,7 @@ public static function attribute(
}

try {
return twig_get_attribute(
return CoreExtension::getAttribute(
$env,
$source,
$object,
Expand Down
3 changes: 2 additions & 1 deletion src/web/twig/nodes/GetAttrNode.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
use Twig\Template;

/**
* GetAttrNode is an alternative to [[\Twig\Node\Expression\GetAttrExpression]], which sends attribute calls to [[TemplateHelper::attribute()]] rather than twig_get_attribute().
* GetAttrNode is an alternative to [[\Twig\Node\Expression\GetAttrExpression]], which sends attribute calls to
* [[TemplateHelper::attribute()]] rather than CoreExtension::getAttribute().
*
* @author Pixel & Tonic, Inc. <[email protected]>
* @since 3.0.0
Expand Down
2 changes: 1 addition & 1 deletion src/web/twig/nodes/NavNode.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function __construct(AssignNameExpression $keyTarget, AssignNameExpressio
$this->navItemNode = new NavItem_Node($valueTarget, $indent, $outdent, $lowerBody, $lineno, $tag);
$body = new Node([$this->navItemNode, $upperBody]);

parent::__construct($keyTarget, $valueTarget, $seq, null, $body, null, $lineno, $tag);
parent::__construct($keyTarget, $valueTarget, $seq, null, $body, null, $lineno);
}

/**
Expand Down

0 comments on commit 715b7c4

Please sign in to comment.