diff options
-rw-r--r-- | src/exchange/taler-exchange-httpd_kyc-info.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/exchange/taler-exchange-httpd_kyc-info.c b/src/exchange/taler-exchange-httpd_kyc-info.c index f229231ee..15c4a4ca8 100644 --- a/src/exchange/taler-exchange-httpd_kyc-info.c +++ b/src/exchange/taler-exchange-httpd_kyc-info.c @@ -602,6 +602,7 @@ TEH_handler_kyc_info ( /* Get rules. */ { json_t *jnew_rules; + qs = TEH_plugin->lookup_rules_by_access_token ( TEH_plugin->cls, &kyp->h_payto, @@ -616,13 +617,9 @@ TEH_handler_kyc_info ( "lookup_rules_by_access_token"); goto cleanup; } - if (GNUNET_DB_STATUS_SUCCESS_NO_RESULTS == qs) - { - /* Nothing was triggered, return the measures - that apply for any amount. */ - lrs = NULL; - } - else + lrs = NULL; + if ( (GNUNET_DB_STATUS_SUCCESS_ONE_RESULT == qs) && + (NULL != jnew_rules) ) { lrs = TALER_KYCLOGIC_rules_parse (jnew_rules); GNUNET_break (NULL != lrs); |