ef009f73e2
We have quite a lot of `Error reading file` errors when uploading files. These errors are generated by ActiveStorage `file_checksum.js` component but it eats the actual reason of errors. (See https://github.com/rails/rails/blob/5-2-stable/activestorage/app/javascript/activestorage/file_checksum.js#L38) We can't really override the class to generate better errors, as they are deeply nested in ActiveStorage class hierarchy, and not exported to external code. Instead, we hook into the FileReader event handler, to insert a logger when this error occur. The original event handler will also still be called as usual. This is intended to be temporary. The debug code will be removed once we get a better idea of what is going on. |
||
---|---|---|
.. | ||
assets | ||
controllers | ||
dashboards | ||
fields | ||
graphql | ||
helpers | ||
javascript | ||
jobs | ||
lib | ||
mailers | ||
models | ||
policies | ||
serializers | ||
services | ||
validators | ||
views |