Skip to content

Commit

Permalink
Fully deprecate CRM_Core_SelectValues::eventTokens()
Browse files Browse the repository at this point in the history
  • Loading branch information
eileenmcnaughton committed Feb 6, 2023
1 parent 4efa297 commit 198e3b9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
1 change: 1 addition & 0 deletions CRM/Core/SelectValues.php
Original file line number Diff line number Diff line change
Expand Up @@ -564,6 +564,7 @@ public static function membershipTokens(): array {
* @return array
*/
public static function eventTokens(): array {
CRM_Core_Error::deprecatedFunctionWarning('token processor');
$tokenProcessor = new TokenProcessor(Civi::dispatcher(), ['schema' => ['eventId']]);
$allTokens = $tokenProcessor->listTokens();
foreach (array_keys($allTokens) as $token) {
Expand Down
3 changes: 1 addition & 2 deletions tests/phpunit/CRM/Utils/TokenConsistencyTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -811,8 +811,7 @@ public function testEventTokenConsistency(): void {
$mut = new CiviMailUtils($this);
$this->setupParticipantScheduledReminder();

$tokens = CRM_Core_SelectValues::eventTokens();
$this->assertEquals(array_merge($this->getEventTokens()), $tokens);
$tokens = array_merge($this->getEventTokens());
$tokenProcessor = new TokenProcessor(\Civi::dispatcher(), [
'controller' => __CLASS__,
'smarty' => FALSE,
Expand Down

0 comments on commit 198e3b9

Please sign in to comment.