laravel-database-schedule icon indicating copy to clipboard operation
laravel-database-schedule copied to clipboard

Ignore csrf token field when saving schedule

Open areichardt-apo opened this issue 1 year ago • 1 comments

When i try to save a new schedule, it get the following error:

Add fillable property [_token] to allow mass assignment on [RobersonFaria\DatabaseSchedule\Models\Schedule].

Its because of the $request->all() - which contains the csrf _token field.

areichardt-apo avatar Jun 11 '24 05:06 areichardt-apo

PR Summary

  • Enhanced Data Handling in ScheduleController The 'store' and 'update' functions in ScheduleController.php have been updated to streamline data management. Now, these functions only draw in relevant request data, effectively ignoring the '_token' field. This adjustment improves efficiency and prevents unnecessary data overloading.

what-the-diff[bot] avatar Jun 11 '24 05:06 what-the-diff[bot]