Code Duplication    Length = 11-11 lines in 3 locations

class/Utility.php 3 locations

@@ 120-130 (lines=11) @@
117
            $msg     = $res ? _AM_PUBLISHER_DIRCREATED : _AM_PUBLISHER_DIRNOTCREATED;
118
        }
119
120
        if (static::getPathStatus('images', true) < 0) {
121
            $thePath = static::getImageDir();
122
            $res     = static::mkdir($thePath);
123
124
            if ($res) {
125
                $source = PUBLISHER_ROOT_PATH . '/assets/images/blank.png';
126
                $dest   = $thePath . 'blank.png';
127
                static::copyr($source, $dest);
128
            }
129
            $msg = $res ? _AM_PUBLISHER_DIRCREATED : _AM_PUBLISHER_DIRNOTCREATED;
130
        }
131
132
        if (static::getPathStatus('images/category', true) < 0) {
133
            $thePath = static::getImageDir('category');
@@ 132-142 (lines=11) @@
129
            $msg = $res ? _AM_PUBLISHER_DIRCREATED : _AM_PUBLISHER_DIRNOTCREATED;
130
        }
131
132
        if (static::getPathStatus('images/category', true) < 0) {
133
            $thePath = static::getImageDir('category');
134
            $res     = static::mkdir($thePath);
135
136
            if ($res) {
137
                $source = PUBLISHER_ROOT_PATH . '/assets/images/blank.png';
138
                $dest   = $thePath . 'blank.png';
139
                static::copyr($source, $dest);
140
            }
141
            $msg = $res ? _AM_PUBLISHER_DIRCREATED : _AM_PUBLISHER_DIRNOTCREATED;
142
        }
143
144
        if (static::getPathStatus('images/item', true) < 0) {
145
            $thePath = static::getImageDir('item');
@@ 144-154 (lines=11) @@
141
            $msg = $res ? _AM_PUBLISHER_DIRCREATED : _AM_PUBLISHER_DIRNOTCREATED;
142
        }
143
144
        if (static::getPathStatus('images/item', true) < 0) {
145
            $thePath = static::getImageDir('item');
146
            $res     = static::mkdir($thePath);
147
148
            if ($res) {
149
                $source = PUBLISHER_ROOT_PATH . '/assets/images/blank.png';
150
                $dest   = $thePath . 'blank.png';
151
                static::copyr($source, $dest);
152
            }
153
            $msg = $res ? _AM_PUBLISHER_DIRCREATED : _AM_PUBLISHER_DIRNOTCREATED;
154
        }
155
156
        if (static::getPathStatus('content', true) < 0) {
157
            $thePath = static::getUploadDir(true, 'content');