Skip to content

Passing null to parameter #1 is deprecated #20

@sunscreem

Description

@sunscreem

Describe the bug
Just installed the package in a laravel 11 app and thought I'd try it out in Tinker.

 UserPreferences::set('test','test2')

   DEPRECATED  json_decode(): Passing null to parameter #1 ($json) of type string is deprecated in vendor/robtrehy/laravel-user-preferences/src/UserPreferences.php on line 79.

= null

All working great I just get that deprecation warning.

To Reproduce
Steps to reproduce the behavior:

  1. Go to Tinker
  2. Login as a user
  3. Run UserPreferences::set('test','test2')

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions