Skip to content

Commit

Permalink
Merge pull request #560 from octava/master
Browse files Browse the repository at this point in the history
Update FormExtractor.php
  • Loading branch information
goetas authored Feb 15, 2022
2 parents 9d8df7f + dfc28a1 commit abb7df8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Translation/Extractor/File/FormExtractor.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ public function enterNode(Node $node)

// look for options containing a message
foreach ($node->items as $item) {
if (!$item->key instanceof Node\Scalar\String_) {
if (!$item || !$item->key instanceof Node\Scalar\String_) {
continue;
}

Expand Down Expand Up @@ -171,7 +171,7 @@ public function getDomain(Node $node)
$domain = null;

foreach ($node->items as $item) {
if (!$item->key instanceof Node\Scalar\String_) {
if (!$item || !$item->key instanceof Node\Scalar\String_) {
continue;
}

Expand Down

0 comments on commit abb7df8

Please sign in to comment.