Added a check to a ios7 feature that was crashing on ios6