iOS SDK < 8 compatibility