Skip to content

Commit

Permalink
FIX minor corrections to the README
Browse files Browse the repository at this point in the history
  • Loading branch information
DaveLiddament committed Aug 12, 2024
1 parent 2457e5b commit 2128043
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ $person = new Person();

## MustUseResult

Add #[MustUseResult] attribute that can be used on methods. This enforces the result from the method call must be used.
A `#[MustUseResult]` attribute can be used on methods. This enforces the result from the method call must be used.

E.g. if you have a class like this:

Expand All @@ -158,7 +158,7 @@ You might misuse the `add` method in this way:

```php
$cost = new Money(5);
$cost->add(6); // ERROR - This statement has no effect.
$cost->add(6); // ERROR - The call to the add method has no effect.
```

But this would be OK:
Expand Down

0 comments on commit 2128043

Please sign in to comment.