From 13f10399e99574bc995a5db1d5b495f1b97dbf57 Mon Sep 17 00:00:00 2001 From: Sarah Poger Gladstone Date: Tue, 28 May 2019 04:39:35 -0400 Subject: [PATCH] api call for checksum expiration --- fancytokens.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/fancytokens.php b/fancytokens.php index 6fb0b9f..5ea6804 100644 --- a/fancytokens.php +++ b/fancytokens.php @@ -198,6 +198,9 @@ function fancytokens_civicrm_tokens( &$tokens ){ $today = date_create(); + $checksum_expire_result = civicrm_api3('Setting', 'get', [ 'sequential' => 1, 'return' => ["checksum_timeout"], ]); + $checksum_expire_date_tmp = "" ; + if ($checksum_expire_result['is_error'] == 0 && $checksum_expire_result['count'] == 1){ $tmp_checksum_int = $checksum_expire_result['values'][0]['checksum_timeout']; $interval_str = $tmp_checksum_int." days" ;