Got rid of iOS6 deprecated calls