fix impagejpeg to allow jpg resize