Remove unused variable
[civicrm-core.git] / CRM / Utils / Token.php
index aa882def57d587d5134f2bd1b15bded10190fff7..ed97fbf8039eb0d1f1a9efc99c2ea8765a4f1f89 100644 (file)
@@ -1178,6 +1178,7 @@ class CRM_Utils_Token {
     $className = NULL,
     $jobID = NULL
   ) {
+    CRM_Core_Error::deprecatedFunctionWarning('If you hit this in mailing code you should use flexmailer - otherwise use the token processor');
     $params = [];
     foreach ($contactIDs as $contactID) {
       $params[] = [
@@ -1349,7 +1350,6 @@ class CRM_Utils_Token {
       return;
     }
     // check if there are any tokens
-    $greetingTokens = self::getTokens($tokenString);
     $context = $contactId ? ['contactId' => $contactId] : [];
     if ($contactDetails) {
       $context['contact'] = isset($contactDetails[0]) ? reset($contactDetails[0]) : $contactDetails;