diff --git a/src/base-utils/src/Helper/system.php b/src/base-utils/src/Helper/system.php index e3ecfca..d09d67d 100644 --- a/src/base-utils/src/Helper/system.php +++ b/src/base-utils/src/Helper/system.php @@ -85,7 +85,9 @@ if (!function_exists('move_local_file_to_filesystem')) { if ($private) { $filesystem->setVisibility($save_file_path, AdapterInterface::VISIBILITY_PRIVATE); } - $filesystem->chmod($save_file_path, 0644); + if (method_exists($filesystem, 'chmod')) { + $filesystem->chmod($save_file_path, 0644); + } $meta = $filesystem->getMetadata($save_file_path); switch (config("file.storage.{$bucket}.driver")) { case \Hyperf\Filesystem\Adapter\LocalAdapterFactory::class: