Code Duplication    Length = 3-3 lines in 2 locations

service/notesservice.php 2 locations

@@ 214-216 (lines=3) @@
211
        $files = $folder->getDirectoryListing();
212
        if(is_array($files)) {
213
            echo count($files).' result(s) from Folder->getDirectoryListing():'.PHP_EOL;
214
            foreach($files as $f) {
215
                echo $f->getPath().' (ID '.$f->getId().')'.PHP_EOL;
216
            }
217
        }
218
        echo count($file).' result(s) from Folder->getById('.$id.'):'.PHP_EOL;
219
        foreach($file as $f) {
@@ 219-221 (lines=3) @@
216
            }
217
        }
218
        echo count($file).' result(s) from Folder->getById('.$id.'):'.PHP_EOL;
219
        foreach($file as $f) {
220
             echo $f->getPath().' (ID '.$f->getId().')'.PHP_EOL;
221
        }
222
223
        if(count($file) <= 0 || !$this->isNote($file[0])) {
224
            echo '=> NoteDoesNotExistException'.PHP_EOL;