Skip to content

Commit 88eb0d5

Browse files
property-hooks: add missing $modified declaration to example 4 (#5124)
1 parent fa98755 commit 88eb0d5

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

language/oop5/property-hooks.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,8 @@ class Example
183183
<?php
184184
class Example
185185
{
186+
private bool $modified = false;
187+
186188
public string $foo = 'default value' {
187189
get => $this->foo . ($this->modified ? ' (modified)' : '');
188190
set => strtolower($value);

0 commit comments

Comments
 (0)