Disable large UIImages for UIImageView

One core feature from my app is that the User can use his own images.
But the image size should be restricted to certain size. For example the User shouldn't be allowed to load panorama pictures in the imageView. What would be the best way to restrict this?

Should I just do an if statement after the imagePickerController? And what would be a good maximum size?