Skip to content

Commit

Permalink
prevent HTML5 upload initialization failure caused by cloudflare rock…
Browse files Browse the repository at this point in the history
…et-loader
  • Loading branch information
ron4mac committed Apr 22, 2023
1 parent 013473b commit 44f0dbf
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 28 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @license GNU General Public License version 3 or later; see LICENSE
*
* CHANGELOG.txt
* @since 1.6.24
* @since 1.6.25
*/
Changelog
=========
Expand All @@ -20,6 +20,7 @@ Changelog
[S] = Security fix (issues that are related to security)
*********************************************

2023-04-21 [M] Prevent HTML5 upload initialization failure caused by cloudflare rocket-loader {ron4mac}
2023-04-13 [B] Correction for HTML5 upload admin notification {ron4mac}
2023-04-10 [B] Correct SMF2.1 bridge; correct install with PHP 8.1+ when using GD2 {ron4mac}
2023-03-22 [M] Reduce possibility of race condition at completion of uploads {ron4mac}
Expand Down
16 changes: 8 additions & 8 deletions include/cpg16x.files.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
<file_data>
<element>
<fullpath>CHANGELOG.txt</fullpath>
<version>1.6.24</version>
<version>1.6.25</version>
<status>optional</status>
<permission>read</permission>
<hash>1f08f51e740702be15d9dfb94b8bb7fe</hash>
<hash>866687453c865c9c2fae4e4144b129f7</hash>
</element>
<element>
<fullpath>LICENSE.txt</fullpath>
Expand Down Expand Up @@ -5371,10 +5371,10 @@
</element>
<element>
<fullpath>include/init.inc.php</fullpath>
<version>1.6.24</version>
<version>1.6.25</version>
<status>mandatory</status>
<permission>read</permission>
<hash>37baae5e922e11dac70dd78b0344b7db</hash>
<hash>3cb6e66a5a4d5b33078d58fb7c46b48c</hash>
</element>
<element>
<fullpath>include/inspekt.php</fullpath>
Expand Down Expand Up @@ -7700,17 +7700,17 @@
</element>
<element>
<fullpath>plugins/upload_h5a/js/upload.js</fullpath>
<version>1.6.23</version>
<version>1.6.25</version>
<status>mandatory</status>
<permission>read</permission>
<hash>9bd6b843e45bb892dc83b48163cba600</hash>
<hash>b479e0514ed9c0cda3ac15303bbd1c6f</hash>
</element>
<element>
<fullpath>plugins/upload_h5a/js/upload.min.js</fullpath>
<version>1.6.23</version>
<version>1.6.25</version>
<status>mandatory</status>
<permission>read</permission>
<hash>c4faed5a82d11667b3f4f565e8a528ab</hash>
<hash>a80143714b0483b96a15fd75385cbe0a</hash>
</element>
<element>
<fullpath>plugins/upload_sgl/</fullpath>
Expand Down
4 changes: 2 additions & 2 deletions include/init.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
* @license GNU General Public License version 3 or later; see LICENSE
*
* include/init.inc.php
* @since 1.6.24
* @since 1.6.25
*/

define('COPPERMINE_VERSION', '1.6.24');
define('COPPERMINE_VERSION', '1.6.25');
define('COPPERMINE_VERSION_STATUS', 'stable');
// Define path to jQuery for this version of Coppermine
define('CPG_JQUERY_VERSION', 'js/jquery-1.12.4.js');
Expand Down
10 changes: 8 additions & 2 deletions plugins/upload_h5a/js/upload.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* @license GNU General Public License version 3 or later; see LICENSE
*
* plugins/upload_h5a/js/upload.js
* @since 1.6.24
* @since 1.6.25
*/
"use strict";
var redirURL = '',
Expand Down Expand Up @@ -475,7 +475,13 @@ function H5up_done(okcount, errcnt) {

w.H5uQctrl = _qCtrl;

$ae(w, "DOMContentLoaded", function(){_setup()});
//$ae(w, "DOMContentLoaded", function(){_setup()});
// get around cloudfare highjack of DOMContentLoaded
$ae(document, 'readystatechange', (e) => {
if (e.target.readyState === 'interactive') {
_setup();
}
});

})(window,'uniload.php',['autorient','flistitl','title','caption','keywords','user1','user2','user3','user4']);

Expand Down
30 changes: 15 additions & 15 deletions plugins/upload_h5a/js/upload.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 44f0dbf

Please sign in to comment.