diff --git a/lib/models/Site.dart b/lib/models/Site.dart index 07153a8..daecef3 100644 --- a/lib/models/Site.dart +++ b/lib/models/Site.dart @@ -285,7 +285,7 @@ class Site { Future> listHostmap() async { try { var ret = await platform.invokeMethod("active.listHostmap", {"id": id}); - if (ret == null) { + if (ret == null || ret == "null") { return []; } @@ -307,7 +307,7 @@ class Site { Future> listPendingHostmap() async { try { var ret = await platform.invokeMethod("active.listPendingHostmap", {"id": id}); - if (ret == null) { + if (ret == null || ret == "null") { return []; }