Code Duplication    Length = 9-9 lines in 3 locations

lib/CustomColumn.php 3 locations

@@ 447-455 (lines=9) @@
444
        return array($query, array($id));
445
    }
446
447
    public function getCustom($id)
448
    {
449
        $result = $this->getDb()->prepare(str_format("SELECT id, value AS name FROM {0} WHERE id = ?", $this->getTableName()));
450
        $result->execute(array($id));
451
        if ($post = $result->fetchObject()) {
452
            return new CustomColumn($id, $post->name, $this);
453
        }
454
        return NULL;
455
    }
456
457
    protected function getAllCustomValuesFromDatabase()
458
    {
@@ 545-553 (lines=9) @@
542
        return array($query, array($id));
543
    }
544
545
    public function getCustom($id)
546
    {
547
        $result = $this->getDb()->prepare(str_format("SELECT id, value AS name FROM {0} WHERE id = ?", $this->getTableName()));
548
        $result->execute(array($id));
549
        if ($post = $result->fetchObject()) {
550
            return new CustomColumn($id, $post->name, $this);
551
        }
552
        return NULL;
553
    }
554
555
    protected function getAllCustomValuesFromDatabase()
556
    {
@@ 640-648 (lines=9) @@
637
        return array($query, array($id));
638
    }
639
640
    public function getCustom($id)
641
    {
642
        $result = $this->getDb()->prepare(str_format("SELECT id, value AS name FROM {0} WHERE id = ?", $this->getTableName()));
643
        $result->execute(array($id));
644
        if ($post = $result->fetchObject()) {
645
            return new CustomColumn ($id, $post->name, $this);
646
        }
647
        return NULL;
648
    }
649
650
    protected function getAllCustomValuesFromDatabase()
651
    {