Code Duplication    Length = 9-10 lines in 2 locations

lib/Payone/Api/Mapper/Currency.php 2 locations

@@ 86-95 (lines=10) @@
83
     * @return string
84
     * @throws Payone_Api_Exception_MappingNotFound
85
     */
86
    public function getIdByCode($code)
87
    {
88
        $code = strtolower($code);
89
        if (!$this->hasMappingByCode($code, self::PROPERTY_NAME_ID)) {
90
            throw new Payone_Api_Exception_MappingNotFound();
91
        }
92
93
        $mapping = $this->getMappingByCode($code);
94
        return $mapping[self::PROPERTY_NAME_ID];
95
    }
96
97
    /**
98
     * @param $id
@@ 118-126 (lines=9) @@
115
     * @return string
116
     * @throws Payone_Api_Exception_MappingNotFound
117
     */
118
    public function getCurrencySymbolByCode($code)
119
    {
120
        $code = strtolower($code);
121
        if (!$this->hasMappingByCode($code, self::PROPERTY_NAME_SIGN)) {
122
            throw new Payone_Api_Exception_MappingNotFound();
123
        }
124
125
        $mapping = $this->getMappingByCode($code);
126
        return $mapping[self::PROPERTY_NAME_SIGN];
127
    }
128
129
    /**