Code Duplication    Length = 8-8 lines in 2 locations

src/Mouf/Database/TDBM/Utils/PivotTableMethodsDescriptor.php 2 locations

@@ 65-72 (lines=8) @@
62
     *
63
     * @return string
64
     */
65
    private function getPluralName() : string
66
    {
67
        if (!$this->useAlternateName) {
68
            return TDBMDaoGenerator::toCamelCase($this->remoteFk->getForeignTableName());
69
        } else {
70
            return TDBMDaoGenerator::toCamelCase($this->remoteFk->getForeignTableName()).'By'.TDBMDaoGenerator::toCamelCase($this->pivotTable->getName());
71
        }
72
    }
73
74
    /**
75
     * Returns the singular name.
@@ 79-86 (lines=8) @@
76
     *
77
     * @return string
78
     */
79
    private function getSingularName() : string
80
    {
81
        if (!$this->useAlternateName) {
82
            return TDBMDaoGenerator::toCamelCase(TDBMDaoGenerator::toSingular($this->remoteFk->getForeignTableName()));
83
        } else {
84
            return TDBMDaoGenerator::toCamelCase(TDBMDaoGenerator::toSingular($this->remoteFk->getForeignTableName())).'By'.TDBMDaoGenerator::toCamelCase($this->pivotTable->getName());
85
        }
86
    }
87
88
    /**
89
     * Returns the code of the method.