rs/SDWebImage — pull request #581 by bpoplauschi (2013-12-10 13:47:36+00:00)
Title: Added PNG detection to be able to determine at runtime if a downloaded image should be saved as PNG or as JPEG

After properly reviewing the code, I noticed the change is not as big as I initially thought:
- the case where we need to extract a NSData from UIImage is only when an image was downloaded and via the ```SDWebImageManagerDelegate``` method ```- (UIImage *)imageManager:(SDWebImageManager *)imageManager transformDownloadedImage:(UIImage *)image withURL:(NSURL *)imageURL```, the image was changed.
- otherwise, we either use the NSData that was received from the network or, if ```- (void)storeImage:(UIImage *)image forKey:(NSString *)key``` or ```- (void)storeImage:(UIImage *)image forKey:(NSString *)key toDisk:(BOOL)toDisk``` are called, the imageData is nil so we can't determine if the file is PNG or JPEG.

For my project, the case I described first applies, since we are transforming the data after it arrives. And we do have JPEG images that would have been saved as PNG.