Code Duplication    Length = 7-9 lines in 3 locations

src/Form/Admin/Game.php 1 location

@@ 770-778 (lines=9) @@
767
        return $categories;
768
    }
769
770
    public function getEventManager()
771
    {
772
        if ($this->event === NULL) {
773
            $this->event = new EventManager(
774
                $this->getServiceManager()->get('SharedEventManager'), [get_class($this)]
775
            );
776
        }
777
        return $this->event;
778
    }
779
780
    /**
781
     * Retrieve service manager instance

src/Service/Game.php 1 location

@@ 64-70 (lines=7) @@
61
        $this->serviceLocator = $locator;
62
    }
63
64
    public function getEventManager() {
65
        if (null === $this->event) {
66
            $this->event = new EventManager($this->serviceLocator->get('SharedEventManager'), [get_class($this)]);
67
        }
68
69
        return $this->event;
70
    }
71
72
    public function getGameUserPath($game, $user)
73
    {

src/Service/PrizeCategory.php 1 location

@@ 45-51 (lines=7) @@
42
        $this->serviceLocator = $locator;
43
    }
44
45
    public function getEventManager() {
46
        if (null === $this->event) {
47
            $this->event = new EventManager($this->serviceLocator->get('SharedEventManager'), [get_class($this)]);
48
        }
49
50
        return $this->event;
51
    }
52
53
    /**
54
     *