Fixed iOS 8 bugs