setPreference() public method

Set preferred model for the player.
public setPreference ( string $type )
$type string slim|default
 public function setPreference(Request $request)
 {
     $this->validate($request, ['preference' => 'required|preference']);
     $this->player->setPreference($request->preference);
     return json(trans('user.player.preference.success', ['name' => $this->player->player_name, 'preference' => $request->preference]), 0);
 }