Fix crash only occurring on iOS 7