Fixed problems caused by iOS 7