Code Duplication    Length = 10-10 lines in 2 locations

core/libs/cache/drivers/file_cache.php 1 location

@@ 99-108 (lines=10) @@
96
     * @param string $group
97
     * @return boolean
98
     */
99
    public function clean($group='')
100
    {
101
        $pattern = $group ? APP_PATH . 'temp/cache/' . '*.' . md5($group) : APP_PATH . 'temp/cache/*';
102
        foreach (glob($pattern) as $filename) {
103
            if (!unlink($filename)) {
104
                return false;
105
            }
106
        }
107
        return true;
108
    }
109
110
    /**
111
     * Elimina un elemento de la cache

core/libs/cache/drivers/nixfile_cache.php 1 location

@@ 99-108 (lines=10) @@
96
     * @param string $group
97
     * @return boolean
98
     */
99
    public function clean($group = '')
100
    {
101
        $pattern = $group ? APP_PATH . 'temp/cache/' . '*.' . md5($group) : APP_PATH . 'temp/cache/*';
102
        foreach (glob($pattern) as $filename) {
103
            if (!unlink($filename)) {
104
                return false;
105
            }
106
        }
107
        return true;
108
    }
109
110
    /**
111
     * Elimina un elemento de la cache