I am creating an app where a user signs in and uploads a profile image from the photo library, the image displays fine where i want it to but as soon as the simulator is stopped and the app is run again the image dissapears. I have done a lot of searching and have found code that looks like what i need but i can not get this line of code to work in swift 3.0 xcode 8 beta 3:
data.writeToFile(localPath, atomically: true)
Does anybody know the updated syntax?