From 786805a63a4508fd3029e14348593d3ef35f31e2 Mon Sep 17 00:00:00 2001 From: voluntas Date: Tue, 16 Jan 2024 14:40:51 +0900 Subject: [PATCH] =?UTF-8?q?null=20=E3=83=81=E3=82=A7=E3=83=83=E3=82=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/sora.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/sora.cpp b/src/sora.cpp index d798c53c..0d29cb8e 100644 --- a/src/sora.cpp +++ b/src/sora.cpp @@ -269,7 +269,9 @@ Sora::ConvertForwardingFilter(const nb::handle value) { try { auto object = forwarding_filter_value.as_object(); - filter.action = std::string(object["action"].as_string()); + if (!object["action"].is_null()) { + filter.action = std::string(object["action"].as_string()); + } for (auto or_rule : object["rules"].as_array()) { std::vector rules; for (auto and_rule_value : or_rule.as_array()) {