Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
[skip ci]
  • Loading branch information
mwjames authored Jan 27, 2019
1 parent b27e88b commit 2af64e3
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ PHP 5.3/HHVM 3.3 or later
## Installation

The recommended installation method for this library is by either adding
the dependency to your [composer.json][composer]
the dependency to your [composer.json][composer].

```json
{
Expand All @@ -25,7 +25,6 @@ the dependency to your [composer.json][composer]
}
}
```
or to execute `composer require onoi/event-dispatcher:~1.0`.

## Usage

Expand All @@ -42,7 +41,7 @@ class BarListener implements EventListener {
}
```
```php
class ListenerCollectionRegistery implements EventListenerCollection {
class ListenerCollectionRegistry implements EventListenerCollection {

private $eventListenerCollection;

Expand All @@ -69,12 +68,12 @@ class ListenerCollectionRegistery implements EventListenerCollection {
```php
$eventDispatcherFactory = new EventDispatcherFactory();

$listenerCollectionRegistery = new ListenerCollectionRegistery(
$listenerCollectionRegistry = new ListenerCollectionRegistry(
$eventDispatcherFactory->newGenericEventListenerCollection()
);

$eventDispatcher = $eventDispatcherFactory->newGenericEventDispatcher();
$eventDispatcher->addListenerCollection( $listenerCollectionRegistery );
$eventDispatcher->addListenerCollection( $listenerCollectionRegistry );

class Foo {

Expand Down

0 comments on commit 2af64e3

Please sign in to comment.