too long

I have zip file like this

my.zip
    hello.json
    map
      test.png
      b.obj

use following code to extract

$zip = new ZipArchive;
$res = $zip->open('my.zip');
if ($res === TRUE) {
    $zip->extractTo('/my/destination/dir/');
    $zip->close();
    echo 'ok';
} else {
    echo 'failed';
}

It will create directory like this

/my/destination/dir/
     my
         hello.json
         map
            test.png
            b.obj

I'd like to get this result

/my/destination/dir/
         hello.json
         map
            test.png
            b.obj

how to do this in php?

Now I solved this problem using this [unzip] (https://gist.github.com/videni/d0b7690c67f63b66ffe37977e5967e9a) code