|
@@ -31,12 +31,12 @@ class StorageHandle{
|
|
|
}
|
|
|
private function get_file($key,$pre = true){
|
|
|
if(NO_KEY || NO_SECOND_FLODER){
|
|
|
- $dir = $this->data_dir.$key;
|
|
|
+ $dir = dirname($this->data_dir.$key);
|
|
|
if(!is_dir($dir)){
|
|
|
if(!mkdir($dir,0777,true)) die(json_encode(array('error'=>'cannot_make_dir')));
|
|
|
}
|
|
|
if(!$pre) return $key;
|
|
|
- return $dir;
|
|
|
+ return $dir.'/'.$key;
|
|
|
}
|
|
|
$letter1 = substr($key,0,1);
|
|
|
$letter2 = substr($key,0,2);
|