*/ class SubuserFactory extends Factory { /** * The name of the factory's corresponding model. * * @var string */ protected $model = Subuser::class; /** * Define the model's default state. */ public function definition(): array { return [ 'user_id' => User::factory(), 'server_id' => Server::factory()->withRelationships(), 'permissions' => [ Permissions::WebsocketConnect->value, ], ]; } }