make this work with iOS
Merge pull request #1 from khalidb91/ios

make this work with iOS