Skip to content
Snippets Groups Projects
Commit 6453acd5 authored by Andreas Gohr's avatar Andreas Gohr
Browse files

skip empty line when reading jQuery versions. fixes #1886

parent 924e477e
No related branches found
No related tags found
No related merge requests found
...@@ -132,7 +132,8 @@ function getCdnUrls() { ...@@ -132,7 +132,8 @@ function getCdnUrls() {
$versions = array(); $versions = array();
$lines = file(DOKU_INC . 'lib/scripts/jquery/versions'); $lines = file(DOKU_INC . 'lib/scripts/jquery/versions');
foreach($lines as $line) { foreach($lines as $line) {
$line = preg_replace('/#.*$/', '', $line); $line = trim(preg_replace('/#.*$/', '', $line));
if($line === '') continue;
list($key, $val) = explode('=', $line, 2); list($key, $val) = explode('=', $line, 2);
$key = trim($key); $key = trim($key);
$val = trim($val); $val = trim($val);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment