sergiogonzalez/liferay-portal — pull request #1346 by zsagia (2014-04-04 09:03:52+00:00)
Title: [TECHNICAL-SUPPORT] LPS-43148 Logo Editor (image_uploader) generates FileExtensionException when property "dl.file.extensions" is restricted to certain types, even if the user uploads a file with an extension allowed

Hey Sergio,

I cut Tibor's comment, please review it.

"Thank you for looking into this.
Yes, I know there are several commits. However, I like separating the modifications as much as possible to avoid "logical gaps". This way the we can see the progress clearly. There are plenty of place in Git History, so don't save the commits. ;-)

You can consider the first 3 commits as "initial commits" that started to get the Image Uploader closer to DL.
The next one, "Fix possible NPE" is trivial.
Then, I added a form-validator to the file input - like we have in DL. I would have initially desired this I had been the developer. :-)
Then, it turned out that the UploadImageAction doesn't use the correct file name when it attempts to add the tempfile, so I applied the pattern from EFEA. However, as you know, there are some differences between the image uploader and DL, because the former one is used within an iframe, so has some special requirements (that's why I needed to clear the renderparameterpool in a commit, to avoid duplicated params in the resourceURL every time a user hides & reopens the po-up)

The last ones are also trivial commits."

Thanks,
Zsaga