one guard instead two
This commit is contained in:
parent
17f672737b
commit
16b49f217c
Binary file not shown.
|
|
@ -68,10 +68,7 @@ public extension UIImage {
|
|||
CGContextSetInterpolationQuality(context, interpolationQuality)
|
||||
CGContextDrawImage(context, rect, CGImage)
|
||||
|
||||
guard let newContext = context else {
|
||||
return nil
|
||||
}
|
||||
guard let cgImage = CGBitmapContextCreateImage(newContext) else {
|
||||
guard let newContext = context, cgImage = CGBitmapContextCreateImage(newContext) else {
|
||||
return nil
|
||||
}
|
||||
return UIImage(CGImage: cgImage,
|
||||
|
|
|
|||
Loading…
Reference in New Issue