Skip to content

Releases: OneOffTech/laravel-connect-identity

v0.4.0

22 Feb 19:45
73f4a31
Compare
Choose a tag to compare

This release require Laravel 11. If you are upgrading from an older version follow the upgrade guide.

What's Changed

Upgrade guide

This release has two breaking changes and one minor change.

Default user model and identity model namespace (breaking change)

It is assumed that a User model exists and it is in the App\Models namespace. Additionally the Identity model, generated by the package, is assumed to be the Models directory. If you previously set models namespace manually to use the models folder you can now remove the configuration.

You can move both the User and Identity models to the App/Models directory or explicitly configure the package to use your model location.

To configure the location of the models include the following in the AppServiceProvider's boot method.

\Oneofftech\Identities\Facades\Identity::useIdentityModel(\App\Identity::class);
\Oneofftech\Identities\Facades\Identity::useUserModel(\App\User::class);

Default redirect URL

The default redirect after login/registration is now to /. Previously it was pointing to the RouteServiceProvider::HOME constant. To retain the previous behavior define, on each controller, the redirectTo() method returning the route. The redirectTo method is now the preferred way of telling the package where to redirect after successful actions.

protected function redirectTo(): string
{
    return RouteServiceProvider::HOME;
}

Switch to casts method in models

The generated Identity model used to have the casts property. This should be changed to use the cast method

/**
  * Get the attributes that should be cast.
  *
  * @return array<string, string>
  */
protected function casts(): array
{
    return [
        'expires_at' => 'datetime',
        'registration' => 'bool',
    ];
}

Full Changelog: v0.3.4...v0.4.0

v0.3.4

04 Jan 18:23
Compare
Choose a tag to compare

What's Changed

  • Laravel 10 support by @avvertix in #15
  • Drop support for PHP 7.4, 8.0 and 8.1

Full Changelog: v.0.3.2...v0.3.4

v0.3.3

17 Jul 16:00
d48215c
Compare
Choose a tag to compare

Re-release to fix version not available on packagist

What's Changed

Full Changelog: v0.3.1...v0.3.3

v0.3.2

04 May 12:45
d48215c
Compare
Choose a tag to compare

What's Changed

Full Changelog: v0.3.1...v.0.3.2

v0.3.1

19 Feb 11:12
Compare
Choose a tag to compare

What's Changed

  • Add PHP 8.x support by @avvertix in #12
  • Fix models created outside of the Models directory on Laravel 8 by @avvertix in #13

Full Changelog: v0.3.0...v0.3.1

v0.3.0

19 Jan 11:07
Compare
Choose a tag to compare

What's Changed

  • Drop Laravel 7 and PHP 7.2 support by @avvertix in #9
  • Remove dependency on legacy laravel/ui package by @avvertix in #8

Full Changelog: v0.2.1...v0.3.0

v0.2.1

15 Nov 20:24
Compare
Choose a tag to compare

Added

  • Support post routes for redirect to providers (#7)

Fixed

  • Ensure connect handling do not set registration flag (#6)

Changes

  • Gitlab: use bare minimum permission for obtaining user information

v0.2.0

13 Nov 11:26
Compare
Choose a tag to compare

Added

  • Allow to connect an identity after registration (#3)
  • Laravel 8 support (#5)
  • Improve unit test coverage

Fixes

  • Read wrong configuration while decrypting using the old key

v0.1.1

07 Sep 11:22
Compare
Choose a tag to compare

Added

  • Initial set of unit tests
  • Workflow for running unit tests on PHP 7.2, 7.3 and 7.4

Fixed

  • PHP 7.2 compatibility of inline blade template

v0.1.0

04 Sep 16:47
Compare
Choose a tag to compare

Added

  • Handle user registration via third party providers
  • Handle user log in via third party providers
  • Customizable controllers, migration and models that will live in your application namespace
  • Save identity and token inside the database, using encryption and pseudoanonimization
  • Provide login/register button as Blade component
  • Support all Laravel Socialite and Socialite Providers