Skip to content

Feature: codelens to convert $fillable to $guarded #82

Description

@damms005

When php artisan make:model, Laravel defaults to protected $fillable = [];

Add a codelens that shows Convert to $guarded if:

  • currently opened file is an Eloquent model
  • underlying table has an id column that is a primary key.

The codelens action will be to replace the above with protected $guraded = ['id']

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions