$user
$user : \WP_User
The user associated with these settings.
Manages user-specific settings for a given user.
__construct(integer|\WP_User $user) : \WP_Buoy_User_Settings
Constructor.
integer|\WP_User | $user |
set(string $key, mixed $value) : \WP_Buoy_User_Settings
Sets a user option.
Returns the current instance for chaining.
string | $key | |
mixed | $value |
save() : \WP_Buoy_User_Settings
Saves the current options to the database in user meta fields.
If an option doesn't exist in the $options array, after it was deleted with WP_Buoy_User_Settings::delete(), for instance, it will be deleted from the database, too.
Multiple user meta fields are used so that the WP database is more easily queryable to allow, for example, finding all users whose phone company is Verizon. This aids in debugging issues.
delete(string $key) : \WP_Buoy_User_Settings
Removes an option from the current instance's $options array.
Returns the current instance for chaining.
string | $key |