diff --git a/README.md b/README.md index 99de4d3..48add1a 100644 --- a/README.md +++ b/README.md @@ -1074,7 +1074,7 @@ use PhpParser\Node\Expr\List_; use PhpParser\Node\Expr\Variable; $variable = new Variable('variableName'); -$anotherVariable = new Variable('anoterVariableName'); +$anotherVariable = new Variable('anotherVariableName'); $arrayItems = [new ArrayItem($variable), new ArrayItem($anotherVariable)]; @@ -1084,7 +1084,7 @@ return new List_($arrayItems); ↓ ```php -list($variableName, $anoterVariableName) +list($variableName, $anotherVariableName) ```
@@ -2806,7 +2806,7 @@ $echo = new Echo_([new String_('one')]); $tryStmts = [$echo]; $echo2 = new Echo_([new String_('two')]); -$catch = new Catch_([new FullyQualified('CatchedType')], null, [$echo2]); +$catch = new Catch_([new FullyQualified('SomeType')], null, [$echo2]); $echo3 = new Echo_([new String_('three')]); $finally = new Finally_([$echo3]); @@ -2819,7 +2819,7 @@ return new TryCatch($tryStmts, [$catch]); ```php try { echo 'one'; -} catch (\CatchedType) { +} catch (\SomeType) { echo 'two'; } ``` diff --git a/snippet/list.php b/snippet/list.php index 37b9e4b..41b6067 100644 --- a/snippet/list.php +++ b/snippet/list.php @@ -7,7 +7,7 @@ use PhpParser\Node\Expr\Variable; $variable = new Variable('variableName'); -$anotherVariable = new Variable('anoterVariableName'); +$anotherVariable = new Variable('anotherVariableName'); $arrayItems = [new ArrayItem($variable), new ArrayItem($anotherVariable)]; diff --git a/snippet/try_catch.php b/snippet/try_catch.php index bfeb6c6..737c673 100644 --- a/snippet/try_catch.php +++ b/snippet/try_catch.php @@ -13,7 +13,7 @@ $tryStmts = [$echo]; $echo2 = new Echo_([new String_('two')]); -$catch = new Catch_([new FullyQualified('CatchedType')], null, [$echo2]); +$catch = new Catch_([new FullyQualified('SomeType')], null, [$echo2]); $echo3 = new Echo_([new String_('three')]); $finally = new Finally_([$echo3]);