blob for temp images created. code refactored.
unit tests added for image upload
it is not allowed to upload image larger than 1 Mb
protected against empty image saving