correct small edge case in rotation option

This commit is contained in:
Jehan 2015-07-10 20:21:15 -07:00
parent 2c87364016
commit 74cb9f3a32

View File

@ -308,8 +308,8 @@ RCT_EXPORT_METHOD(stopCapture) {
CGImageRef cgImage;
cgImage = CGImageSourceCreateImageAtIndex(source, 0, NULL);
float rotation = [[options objectForKey:@"rotation"] floatValue];
if (rotation) {
if ([options objectForKey:@"rotation"]) {
float rotation = [[options objectForKey:@"rotation"] floatValue];
cgImage = [self CGImageRotatedByAngle:cgImage angle:rotation];
} else {
// Get metadata orientation