aboutsummaryrefslogtreecommitdiff
path: root/src/kyclogic/kyclogic_api.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2024-08-25 10:43:52 +0200
committerChristian Grothoff <christian@grothoff.org>2024-08-25 10:43:52 +0200
commit7abd317b7b9b9abe096a60f364510b912b94bf48 (patch)
treea48a7aed05d1fbc364f10e3eb78bc3d38d4eca39 /src/kyclogic/kyclogic_api.c
parent57e7b57f7dae7a203d7221e224f5a4c918431e11 (diff)
custom_measures is a mandatory field, check it exists and generate it in the helpers
Diffstat (limited to 'src/kyclogic/kyclogic_api.c')
-rw-r--r--src/kyclogic/kyclogic_api.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/kyclogic/kyclogic_api.c b/src/kyclogic/kyclogic_api.c
index def2cbd29..3fb62d5fa 100644
--- a/src/kyclogic/kyclogic_api.c
+++ b/src/kyclogic/kyclogic_api.c
@@ -495,7 +495,7 @@ TALER_KYCLOGIC_rules_parse (const json_t *jlrs)
struct GNUNET_TIME_Timestamp expiration_time;
const char *successor_measure = NULL;
const json_t *jrules;
- const json_t *jcustom_measures = NULL;
+ const json_t *jcustom_measures;
struct GNUNET_JSON_Specification spec[] = {
GNUNET_JSON_spec_timestamp (
"expiration_time",
@@ -507,10 +507,8 @@ TALER_KYCLOGIC_rules_parse (const json_t *jlrs)
NULL),
GNUNET_JSON_spec_array_const ("rules",
&jrules),
- GNUNET_JSON_spec_mark_optional (
- GNUNET_JSON_spec_object_const ("custom_measures",
- &jcustom_measures),
- NULL),
+ GNUNET_JSON_spec_object_const ("custom_measures",
+ &jcustom_measures),
GNUNET_JSON_spec_end ()
};
struct TALER_KYCLOGIC_LegitimizationRuleSet *lrs;