Code Duplication    Length = 7-10 lines in 2 locations

Bundle/ViewReferenceBundle/Connector/ViewReferenceManager.php 2 locations

@@ 101-110 (lines=10) @@
98
     *
99
     * @param ViewReference $viewReference
100
     */
101
    public function removeReference(ViewReference $viewReference)
102
    {
103
        $referenceId = $viewReference->getId();
104
        if ($url = $this->repository->findValueForId('url', $referenceId)) {
105
            // Remove url
106
            $this->manager->removeUrl($url, $viewReference->getLocale());
107
        }
108
        // Remove reference
109
        $this->manager->remove($referenceId);
110
    }
111
112
    /**
113
     * Find the transformer for an element.
@@ 135-141 (lines=7) @@
132
     *
133
     * @param ViewReference $viewReference
134
     */
135
    public function removeUrlForViewReference(ViewReference $viewReference)
136
    {
137
        $id = $viewReference->getId();
138
        if ($url = $this->repository->findValueForId('url', $id)) {
139
            $this->manager->removeUrl($url, $this->repository->findValueForId('locale', $id));
140
        }
141
    }
142
}
143