Skip to content
This repository was archived by the owner on May 13, 2026. It is now read-only.

Fixing patternTypePath assignment - Undefined variable: pattern in TwigUtil.php on line 65#31

Merged
EvanLovely merged 1 commit into
pattern-lab:masterfrom
bradwade:master
Oct 11, 2016
Merged

Fixing patternTypePath assignment - Undefined variable: pattern in TwigUtil.php on line 65#31
EvanLovely merged 1 commit into
pattern-lab:masterfrom
bradwade:master

Conversation

@bradwade
Copy link
Copy Markdown

If you do not prefix _pattern folders with numbers and dash (00-atoms, 01-molecules) and instead use simply "atoms" and "molecules", the patternTypePath would not get assigned properly as the "else" condition of the ternary logic uses an undefined $pattern variable.

This PR fixes this issue... and will stop the following notice:

php core/console --generate
configuring pattern lab...
PHP Notice:  Undefined variable: pattern in /Users/wadeb/Sites/patterlab-demo/bw-twig-drupal/vendor/pattern-lab/patternengine-twig/src/PatternLab/PatternEngine/Twig/TwigUtil.php on line 65

@EvanLovely EvanLovely merged commit a74edca into pattern-lab:master Oct 11, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants