TOCropViewController icon indicating copy to clipboard operation
TOCropViewController copied to clipboard

CALayer position contains NaN

Open Rochester-Ting opened this issue 9 years ago • 1 comments

image

image

what's wrong

Rochester-Ting avatar Nov 24 '17 02:11 Rochester-Ting

Hi @Rochester-Ting!

Hmm, that usually happens if the controller was initialized with the UIImage being nil. It tries to call image.size, but because it's nil, it causes layout errors in Core Animation.

I thought that the controller had better provisions for checking if image == nil, but in any case, the best way to avoid this is to make sure your code only provides valid UIImage instances to this library. :)

Hope that helped!

TimOliver avatar Nov 27 '17 04:11 TimOliver