Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
taylorotwell committed Nov 29, 2017
1 parent 9e81132 commit 100dabd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions seeding.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ To generate a seeder, execute the `make:seeder` [Artisan command](/docs/{{versio

A seeder class only contains one method by default: `run`. This method is called when the `db:seed` [Artisan command](/docs/{{version}}/artisan) is executed. Within the `run` method, you may insert data into your database however you wish. You may use the [query builder](/docs/{{version}}/queries) to manually insert data or you may use [Eloquent model factories](/docs/{{version}}/database-testing#writing-factories).

> {tip} [Mass assignment protection](/docs/{{version}}/eloquent#mass-assignment) is automatically disabled during database seeding.
As an example, let's modify the default `DatabaseSeeder` class and add a database insert statement to the `run` method:

<?php
Expand All @@ -44,8 +46,6 @@ As an example, let's modify the default `DatabaseSeeder` class and add a databas
}
}

> {note} Mass Assignment protection is disabled during seeding.
<a name="using-model-factories"></a>
### Using Model Factories

Expand Down

0 comments on commit 100dabd

Please sign in to comment.