作者 lyh

gx

@@ -52,7 +52,7 @@ class ProductFileUpload extends Command @@ -52,7 +52,7 @@ class ProductFileUpload extends Command
52 if($fileInfo === false){ 52 if($fileInfo === false){
53 continue; 53 continue;
54 } 54 }
55 - $newName = rtrim($url, '/').'/'.$fileInfo['name']; 55 + $newName = $result = preg_replace('#/[^/]*$#', '/', $url).$fileInfo['name'];
56 @file_put_contents(storage_path('logs/lyh_error.log'), var_export($newName, true) . PHP_EOL, FILE_APPEND); 56 @file_put_contents(storage_path('logs/lyh_error.log'), var_export($newName, true) . PHP_EOL, FILE_APPEND);
57 } 57 }
58 } 58 }