0
0
Fork 0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-05-01 23:19:51 +00:00

Slack auth: Switched from community to laravel library

Tested locally before & after change, and looked at code to compare.
Nothing seen or experienced that should affect things, from testing all
is working as expected with no difference from before.
- Update composer requirement of socialite to that which included slack.
- Updated PHP depds while there.
- Updated format of socialite events to align with current documentation
  and to use class references instead of strings.
This commit is contained in:
Dan Brown 2023-09-11 15:26:04 +01:00
parent 05f2ec40cc
commit 4985e39db4
No known key found for this signature in database
GPG key ID: 46D9F943C24A2EF9
3 changed files with 185 additions and 220 deletions

View file

@ -3,7 +3,12 @@
namespace BookStack\App\Providers; namespace BookStack\App\Providers;
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider; use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
use SocialiteProviders\Azure\AzureExtendSocialite;
use SocialiteProviders\Discord\DiscordExtendSocialite;
use SocialiteProviders\GitLab\GitLabExtendSocialite;
use SocialiteProviders\Manager\SocialiteWasCalled; use SocialiteProviders\Manager\SocialiteWasCalled;
use SocialiteProviders\Okta\OktaExtendSocialite;
use SocialiteProviders\Twitch\TwitchExtendSocialite;
class EventServiceProvider extends ServiceProvider class EventServiceProvider extends ServiceProvider
{ {
@ -14,12 +19,11 @@ class EventServiceProvider extends ServiceProvider
*/ */
protected $listen = [ protected $listen = [
SocialiteWasCalled::class => [ SocialiteWasCalled::class => [
'SocialiteProviders\Slack\SlackExtendSocialite@handle', AzureExtendSocialite::class . '@handle',
'SocialiteProviders\Azure\AzureExtendSocialite@handle', OktaExtendSocialite::class . '@handle',
'SocialiteProviders\Okta\OktaExtendSocialite@handle', GitLabExtendSocialite::class . '@handle',
'SocialiteProviders\GitLab\GitLabExtendSocialite@handle', TwitchExtendSocialite::class . '@handle',
'SocialiteProviders\Twitch\TwitchExtendSocialite@handle', DiscordExtendSocialite::class . '@handle',
'SocialiteProviders\Discord\DiscordExtendSocialite@handle',
], ],
]; ];

View file

@ -23,7 +23,7 @@
"guzzlehttp/guzzle": "^7.4", "guzzlehttp/guzzle": "^7.4",
"intervention/image": "^2.7", "intervention/image": "^2.7",
"laravel/framework": "^9.0", "laravel/framework": "^9.0",
"laravel/socialite": "^5.2", "laravel/socialite": "^5.8",
"laravel/tinker": "^2.6", "laravel/tinker": "^2.6",
"league/commonmark": "^2.3", "league/commonmark": "^2.3",
"league/flysystem-aws-s3-v3": "^3.0", "league/flysystem-aws-s3-v3": "^3.0",
@ -37,7 +37,6 @@
"socialiteproviders/gitlab": "^4.1", "socialiteproviders/gitlab": "^4.1",
"socialiteproviders/microsoft-azure": "^5.1", "socialiteproviders/microsoft-azure": "^5.1",
"socialiteproviders/okta": "^4.2", "socialiteproviders/okta": "^4.2",
"socialiteproviders/slack": "^4.1",
"socialiteproviders/twitch": "^5.3", "socialiteproviders/twitch": "^5.3",
"ssddanbrown/htmldiff": "^1.0.2" "ssddanbrown/htmldiff": "^1.0.2"
}, },

386
composer.lock generated

File diff suppressed because it is too large Load diff