Skip to content

Commit 30bde29

Browse files
author
Dominik Liebler
committed
Merge pull request DesignPatternsPHP#125 from SephVelut/patch-1
Update Colleague.php
2 parents 539f636 + 1807186 commit 30bde29

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

Behavioral/Mediator/Colleague.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,7 @@ abstract class Colleague
1414
* @var MediatorInterface
1515
*/
1616
private $mediator;
17-
18-
// for subclasses
19-
protected function getMediator()
20-
{
21-
return $this->mediator;
22-
}
23-
17+
2418
/**
2519
* @param MediatorInterface $medium
2620
*/
@@ -29,4 +23,10 @@ public function __construct(MediatorInterface $medium)
2923
// in this way, we are sure the concrete colleague knows the mediator
3024
$this->mediator = $medium;
3125
}
26+
27+
// for subclasses
28+
protected function getMediator()
29+
{
30+
return $this->mediator;
31+
}
3232
}

0 commit comments

Comments
 (0)