You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When validating a specific field in a form, files that are nested within objects inside arrays are still being sent with the request payload. This behaviour is unexpected, as all Files should be removed unless specified with form.validateFiles.
This issue originates from the forgetFiles function (in validator.ts), which does not handle files nested in arrays of objects properly.
Expected behaviour:
Files within an object in an array should also be filtered to avoid sending unnecessary (large) data multiple times.
As forgetFiles is a core function this problem probably exists in all environments. (Vue, React, Blade, ...)
Laravel Precognition Plugin Version
0.5.14
Laravel Version
11.36.1
Plugin
Vue w/ Inertia
Description
When validating a specific field in a form, files that are nested within objects inside arrays are still being sent with the request payload. This behaviour is unexpected, as all Files should be removed unless specified with
form.validateFiles
.This issue originates from the
forgetFiles
function (invalidator.ts
), which does not handle files nested in arrays of objects properly.Expected behaviour:
Files within an object in an array should also be filtered to avoid sending unnecessary (large) data multiple times.
As
forgetFiles
is a core function this problem probably exists in all environments. (Vue, React, Blade, ...)Steps To Reproduce
When an input is made, the whole form data is sent, including the files:
The text was updated successfully, but these errors were encountered: