server/src/app/Services/ViafResolver.php
changeset 133 821253d361d1
parent 23 037687868bc4
child 524 85e8382852e7
--- a/server/src/app/Services/ViafResolver.php	Thu Feb 25 12:24:30 2016 +0100
+++ b/server/src/app/Services/ViafResolver.php	Thu Feb 25 21:26:15 2016 +0100
@@ -107,6 +107,11 @@
      *                   Each id can be an url starting with http://viaf.org/viaf/
      */
     public function getNames(array $ids) {
+
+        if(count($ids) > config('corpusparole.viaf_max_ids')) {
+            throw new ViafResolverException("Too manys ids provided");
+        }
+
         return array_combine($ids, array_map([$this,'getName'], $ids));
     }