Skip to content

Commit

Permalink
优化配置读取
Browse files Browse the repository at this point in the history
  • Loading branch information
WHBLeer committed May 30, 2023
1 parent df51502 commit f245923
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/StorageManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ public function upload(Request $request)

$path_arr = explode('/',$filename);
$sha1 = md5(filesize($file).'+'.sha1_file($file));
MYDB::insert("INSERT INTO `{$config['insert_table']}` (user_id, name, org_name, path, size, category, mime_type, disk, sha1) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", [
MYDB::insert("INSERT INTO `{$config['insert_table']}` (user_id, name, org_name, path, size, category, mime_type, disk, sha1) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?)", [
$request->get('user'),
end($path_arr),
$response['original'],
Expand Down Expand Up @@ -375,7 +375,8 @@ protected function getUploadConfig($action)
break;
}
}


$config['insert_table'] = config('ueditor-plus.insert_table');
return $config;
}

Expand Down

0 comments on commit f245923

Please sign in to comment.