]> git.mxchange.org Git - fba.git/blobdiff - fba/http/federation.py
Continued:
[fba.git] / fba / http / federation.py
index f39bdc8aa561d44978cd48ac3db72e1aa02ced21..355036e76bad78314033e6ca62a128038fb40b79 100644 (file)
@@ -535,6 +535,8 @@ def add_peers(rows: dict) -> list:
 
     if not isinstance(rows, dict):
         raise ValueError(f"Parameter rows[]='{type(rows)}' is not of type 'dict'")
+    elif len(rows) == 0:
+        raise ValueError("Parameter 'rows' is empty")
 
     peers = list()
     for key in ["linked", "allowed", "blocked"]: