Code Duplication    Length = 18-18 lines in 2 locations

src/Model/BlogController.php 2 locations

@@ 217-234 (lines=18) @@
214
     *
215
     * @return null|HTTPResponse
216
     */
217
    public function tag()
218
    {
219
        $tag = $this->getCurrentTag();
220
221
        if ($tag) {
222
            $this->blogPosts = $tag->BlogPosts();
223
224
            if ($this->isRSS()) {
225
                return $this->rssFeed($this->blogPosts, $tag->getLink());
226
            } else {
227
                return $this->render();
228
            }
229
        }
230
231
        $this->httpError(404, 'Not Found');
232
233
        return null;
234
    }
235
236
    /**
237
     * Tag Getter for use in templates.
@@ 263-280 (lines=18) @@
260
     *
261
     * @return null|HTTPResponse
262
     */
263
    public function category()
264
    {
265
        $category = $this->getCurrentCategory();
266
267
        if ($category) {
268
            $this->blogPosts = $category->BlogPosts();
269
270
            if ($this->isRSS()) {
271
                return $this->rssFeed($this->blogPosts, $category->getLink());
272
            } else {
273
                return $this->render();
274
            }
275
        }
276
277
        $this->httpError(404, 'Not Found');
278
279
        return null;
280
    }
281
282
    /**
283
     * Category Getter for use in templates.