Fixes to work with iOS8.1