Code Duplication    Length = 11-11 lines in 2 locations

app/lib/FFCMS/Controllers/API/APIMapper.php 2 locations

@@ 260-270 (lines=11) @@
257
     * @param \Base $f3
258
     * @return void
259
     */
260
    public function listingAdmin(\Base $f3)
261
    {
262
        // must be an admin
263
        $isAdmin = $f3->get('isAdmin');
264
        if (!$isAdmin) {
265
            $this->failure('authentication_error', "User does not have permission.", 401);
266
            return $this->setOAuthError('access_denied');
267
        }
268
269
        $this->data = $this->getListingResults($f3, $this->getMapper());
270
    }
271
272
273
    /**
@@ 279-289 (lines=11) @@
276
     * @param \Base $f3
277
     * @return void
278
     */
279
    public function searchAdmin(\Base $f3)
280
    {
281
        // must be an admin
282
        $isAdmin = $f3->get('isAdmin');
283
        if (!$isAdmin) {
284
            $this->failure('authentication_error', "User does not have permission.", 401);
285
            return $this->setOAuthError('access_denied');
286
        }
287
288
        $this->data = $this->getSearchResults($f3, $this->getMapper());
289
    }
290
291
292
    /**