summaryrefslogtreecommitdiff
path: root/runtime/ops/worker_host.rs
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/ops/worker_host.rs')
-rw-r--r--runtime/ops/worker_host.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/runtime/ops/worker_host.rs b/runtime/ops/worker_host.rs
index cddde985a..424e7a70c 100644
--- a/runtime/ops/worker_host.rs
+++ b/runtime/ops/worker_host.rs
@@ -255,6 +255,14 @@ impl<'de> de::Visitor<'de> for ParseBooleanOrStringVec {
formatter.write_str("a vector of strings or a boolean")
}
+ // visit_unit maps undefined/missing values to false
+ fn visit_unit<E>(self) -> Result<UnaryPermissionBase, E>
+ where
+ E: de::Error,
+ {
+ self.visit_bool(false)
+ }
+
fn visit_bool<E>(self, v: bool) -> Result<UnaryPermissionBase, E>
where
E: de::Error,