Forráskód Böngészése

fix ombi if no tv requests

causefx 7 éve
szülő
commit
1fe64407bc
1 módosított fájl, 1 hozzáadás és 1 törlés
  1. 1 1
      api/functions/homepage-connect-functions.php

+ 1 - 1
api/functions/homepage-connect-functions.php

@@ -1978,7 +1978,7 @@ function getOmbiRequests($type = "both")
 				if (isset($tv) && (is_array($tv) || is_object($tv))) {
 					$tv = json_decode($tv->body, true);
 					foreach ($tv as $key => $value) {
-						if (is_array($value['childRequests'][0])) {
+						if (count($value['childRequests']) > 0) {
 							$requests[] = array(
 								'test' => $value,
 								'id' => $value['tvDbId'],