Kuldeep Tanwar
Kuldeep Tanwar

Reputation: 3526

How to save the video as the most recent item in iOS Photo LIbrary

I'm using Photos framework to save a video to Photos Library in Swift.

I used this method -

PHPhotoLibrary.shared().performChanges {
    PHAssetChangeRequest.creationRequestForAssetFromVideo(atFileURL: url)
}

It is working fine and saving the video in the Photos Library. The only issue is the video file that I'm using might old so if the file is from yesterday and I have recent photos in my library from today as an exported item it will not appear as the latest exported item. Specially if the video you are trying to save in the photos library is too old I have to scroll and find it in the Photos Library after exporting it.

Is there a way I can save it as the most recent item in the Photos Library?

Upvotes: 0

Views: 43

Answers (0)

Related Questions