Skip to content

Commit

Permalink
fix: php fatal error when fof/oauth not installed (#10)
Browse files Browse the repository at this point in the history
  • Loading branch information
imorland authored Oct 14, 2023
1 parent 91b4ba1 commit fcc9ea1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions extend.php
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,8 @@

(new Extend\Conditional())
->whenExtensionEnabled('fof-oauth', [
(new \FoF\Extend\Extend\OAuthController())
->afterOAuthSuccess(TwoFactorOAuthCheck::class),
class_exists(\FoF\Extend\Extend\OAuthController) ? (new \FoF\Extend\Extend\OAuthController())
->afterOAuthSuccess(TwoFactorOAuthCheck::class) : null,

(new Extend\Routes('forum'))
->get('/twofactor/oauth/verify', 'twoFactor.oauth', Api\Controller\TwoFactorOAuthController::class)
Expand Down

0 comments on commit fcc9ea1

Please sign in to comment.