So, the problem I see is that let's save uploadAndSave method throws an exception , but it's not 422 validation error. What this code will do is that even though thrown error is not 422, it will think it is 422 and redirect to articles/new url. I think this is not the best way and might be wrong.
Hello. Here is code I found in your project.
So, the problem I see is that let's save uploadAndSave method throws an exception , but it's not 422 validation error. What this code will do is that even though thrown error is not 422, it will think it is 422 and redirect to articles/new url. I think this is not the best way and might be wrong.