I have string column in my table which supposed to store unique tokens but instead it stores something like this:
??6?i!a\????5?&?9?
Code
controller
use Illuminate\Support\Str;
public function store(Request $request)
{
$recipient = new RsvpPerson;
$recipient->token = Str::random(20);
$recipient->save();
}
Schema
Schema::create('rsvp_people', function (Blueprint $table) {
$table->uuid('id')->primary();
$table->string('token')->unique();
$table->timestamps();
}
any idea?