mirror of
https://github.com/sbrl/Pepperminty-Wiki.git
synced 2024-11-22 04:23:01 +00:00
patching PHP 7.3.11 issue and double dot in file uploads
This commit is contained in:
parent
dbbd9e7514
commit
171f9f4874
2 changed files with 131 additions and 131 deletions
|
@ -99,7 +99,7 @@ register_module([
|
|||
break;
|
||||
|
||||
case "POST":
|
||||
// Recieve file
|
||||
// Receive file
|
||||
|
||||
if(!$settings->editing) {
|
||||
exit(page_renderer::render_main("Upload failed - $settings->sitename", "<p>Your upload couldn't be processed because editing is currently disabled on $settings->sitename. Please contact $settings->admindetails_name, $settings->sitename's administrator for more information - their contact details can be found at the bottom of this page. <a href='index.php'>Go back to the main page</a>."));
|
||||
|
@ -194,7 +194,7 @@ register_module([
|
|||
|
||||
// The path to the place (relative to the wiki data root)
|
||||
// that we're actually going to store the uploaded file itself
|
||||
$new_filename = "$paths->upload_file_prefix$target_name.$file_extension";
|
||||
$new_filename = "$paths->upload_file_prefix$target_name$file_extension";
|
||||
// The path (relative, as before) to the description file
|
||||
$new_description_filename = "$new_filename.md";
|
||||
|
||||
|
|
|
@ -193,7 +193,7 @@ function do_password_hash_code_update() {
|
|||
global $settings, $paths;
|
||||
|
||||
// There's no point if we're using Argon2i, as it doesn't take a cost
|
||||
if(hash_password_properties()["algorithm"] == PASSWORD_ARGON2I)
|
||||
if(defined("PASSWORD_ARGON2I") && hash_password_properties()["algorithm"] == PASSWORD_ARGON2I)
|
||||
return;
|
||||
|
||||
// Skip rechecking if the automatic check has been disabled
|
||||
|
|
Loading…
Reference in a new issue