Skip to content

Commit 3a525a4

Browse files
committed
Fix a bug when merging higher level attributes into lower level attributes
1 parent ba3f4cc commit 3a525a4

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

Utils/MPDUtility.php

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ function profileListContainsAtLeastOne($list, $profiles)
7474
}
7575
return false;
7676
}
77+
7778
function mpdProfilesContainsAtLeastOne($profiles)
7879
{
7980
global $mpdHandler;
@@ -118,7 +119,7 @@ function nextElementSibling($node)
118119

119120
function timeParsing($var)
120121
{
121-
return include 'impl/MPDUtility/timeParsing.php';
122+
return include 'impl/MPDUtility/timeParsing.php';
122123
}
123124

124125

@@ -140,7 +141,7 @@ function checkYearMonth($str)
140141
}
141142

142143
$duration = ($Y[0] * 365 * 24 * 60 * 60) +
143-
($Mo[0] * 30 * 24 * 60 * 60);
144+
($Mo[0] * 30 * 24 * 60 * 60);
144145

145146
return ($duration > 0);
146147
}
@@ -167,18 +168,20 @@ function formSegmentAccess($highLevel, $lowLevel)
167168
if (!$lowValue[$k]) {
168169
$lowValue[$k] = $v;
169170
} elseif (gettype($lowValue[$k]) == 'array') {
170-
//$v would also work, but this is more clear in meaning
171+
//$v would also work, but this is more clear in meaning
171172
$lowValue[$k] = formSegmentAccess($highValue[$k], $lowValue[$k]);
172173
}
173174
}
175+
$lowLevel[$key] = $lowValue;
174176
}
177+
return $lowLevel;
175178
}
176179

177180
function parseDoc($path)
178181
{
179182
$return_val = false;
180183

181-
$contents = file_get_contents($path);
184+
$contents = file_get_contents($path);
182185

183186
$loaded = simplexml_load_file($path);
184187
if (!$loaded) {

0 commit comments

Comments
 (0)