small refactor

This commit is contained in:
Ivan Smolin 2016-06-01 13:08:46 +03:00
parent 77b1414f86
commit efdfdf5da6
1 changed files with 1 additions and 1 deletions

View File

@ -20,7 +20,7 @@ extension UIImage {
public func renderWithSize(size: CGSize) -> UIImage {
UIGraphicsBeginImageContextWithOptions(size, false, 0.0)
self.drawInRect(CGRect(x: 0.0, y: 0.0, width: size.width, height: size.height))
self.drawInRect(CGRect(origin: CGPoint.zero, size: size))
let resizedImage = UIGraphicsGetImageFromCurrentImageContext()