Browse Source

Fix: module "root" not exists ! (deprecated api)

Regis Houssin 8 years ago
parent
commit
c5442c3553
1 changed files with 1 additions and 1 deletions
  1. 1 1
      htdocs/api/index.php

+ 1 - 1
htdocs/api/index.php

@@ -206,7 +206,7 @@ if (! empty($reg[1]) && $reg[1] == 'explorer' && ($reg[2] == '/resources.json' |
 }
 
 // Call one APIs or one definition of an API
-if (! empty($reg[1]) && ($reg[1] != 'explorer' || ($reg[2] != '/resources.json' && preg_match('/^\/resources.json\/(.+)$/', $reg[2], $regbis))))
+if (! empty($reg[1]) && ($reg[1] != 'explorer' || ($reg[2] != '/resources.json' && preg_match('/^\/resources.json\/(.+)$/', $reg[2], $regbis) && $regbis[1] != 'root')))
 {
     $module = $reg[1];
     if ($module == 'explorer')  // If we call page to explore details of a service