Caught old string helper function usage

Found by Laravel Shift Workbench
This commit is contained in:
Dan Brown 2021-09-26 15:41:11 +01:00
parent c32b315cd7
commit 5c7eb0df57
No known key found for this signature in database
GPG key ID: 46D9F943C24A2EF9

View file

@ -1,5 +1,6 @@
<?php
use Illuminate\Support\Str;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
@ -53,7 +54,7 @@ class CreateJointPermissionsTable extends Migration
// Ensure unique name
while (DB::table('roles')->where('name', '=', $publicRoleData['display_name'])->count() > 0) {
$publicRoleData['display_name'] = $publicRoleData['display_name'] . str_random(2);
$publicRoleData['display_name'] = $publicRoleData['display_name'] . Str::random(2);
}
$publicRoleId = DB::table('roles')->insertGetId($publicRoleData);