update code to xcode 6.0.1