adding conditional macro for compatibility with pre-iOS 8 SDKs