Skip to content

Commit

Permalink
Add deprecation log messages
Browse files Browse the repository at this point in the history
  • Loading branch information
spvickers committed Aug 30, 2024
1 parent 387a2f8 commit 7290b68
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Jwt/FirebaseClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,8 @@ public static function getLastPayload(): array|object|null
*/
public function verify(?string $publicKey, ?string $jku = null): bool
{
Util::logDebug('Method ceLTIc\LTI\Jwt\FirebaseClient->verify has been deprecated; please use ceLTIc\LTI\Jwt\FirebaseClient->verifySignature instead.',
true);
return $this->verifySignature($publicKey, $jku);
}

Expand Down
2 changes: 2 additions & 0 deletions src/Jwt/WebTokenClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,8 @@ public static function getLastPayload(): array|object|null
*/
public function verify(?string $publicKey, ?string $jku = null): bool
{
Util::logDebug('Method ceLTIc\LTI\Jwt\WebTokenClient->verify has been deprecated; please use ceLTIc\LTI\Jwt\WebTokenClient->verifySignature instead.',
true);
return $this->verifySignature($publicKey, $jku);
}

Expand Down
2 changes: 2 additions & 0 deletions src/Service/LineItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,8 @@ public function get(): LTI\LineItem|bool
*/
public static function getLineItem(Platform $platform, string $endpoint): LTI\LineItem|bool
{
Util::logDebug('Method ceLTIc\LTI\Service\LineItem::getLineItem has been deprecated; please use ceLTIc\LTI\LineItem::fromEndpoint or ceLTIc\LTI\Service\LineItem->get instead.',
true);
return LTI\LineItem::fromEndpoint($platform, $endpoint);
}

Expand Down

0 comments on commit 7290b68

Please sign in to comment.