Skip to content

Update SocialiteWasCalled.php to Solve problem introduced by L13#243

Merged
atymic merged 2 commits intoSocialiteProviders:masterfrom
alperyazgan:master
Mar 18, 2026
Merged

Update SocialiteWasCalled.php to Solve problem introduced by L13#243
atymic merged 2 commits intoSocialiteProviders:masterfrom
alperyazgan:master

Conversation

@alperyazgan
Copy link
Copy Markdown
Contributor

@alperyazgan alperyazgan commented Mar 18, 2026

Solve problem introduced by L13

Laravel version 13 has broken changes for Support / Manager  [https://laravel.com/docs/13.x/upgrade#support]

Fixes #

Changes proposed in this pull request:

If you previously relied on another bound object (such as a service provider instance) as $this inside these callbacks, you should move those values into closure captures using use (...).

Solve problem introduced by L13

Laravel version 13 has broken changes for Support / Manager  [https://laravel.com/docs/13.x/upgrade#support]
@atymic atymic requested a review from Copilot March 18, 2026 19:45
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the Socialite provider extension callback to remain compatible with Laravel 13’s Support\Manager behavior change around callback $this binding.

Changes:

  • Capture the current SocialiteWasCalled instance into a local variable before registering the SocialiteManager::extend callback.
  • Use the captured instance inside the callback instead of relying on $this being bound as expected at invocation time.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@atymic atymic merged commit 32412c3 into SocialiteProviders:master Mar 18, 2026
4 checks passed
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 18, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 55.32%. Comparing base (a67f194) to head (9603310).
⚠️ Report is 10 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #243      +/-   ##
============================================
+ Coverage     55.10%   55.32%   +0.22%     
- Complexity       78       82       +4     
============================================
  Files            10       10              
  Lines           245      244       -1     
============================================
  Hits            135      135              
+ Misses          110      109       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants