Archive for May, 2022

Secret Photo Folder App fix coming

May 28, 2022

First things first, if you are one of the thousands of current users coming here to check for the status, I’m pleased to announce that it is fixed and under review by Apple. It should be published in the next 48 hours.

The app should be available as an update in the store. Direct link here:

Now, let me explain the issue.

Apple recently released iOS 15.5 and I had to update many of my apps. If you are familiar with Apple App development, you know that Apple enforces developers to constantly update the apps in the store otherwise they get removed. This is the reason why even though I’ve developed more than 80 apps, you will find only a few in the store. I don’t have time to keep updating all of them and Apple removes them as time passes by.

This system has some advantages, mainly that Apple makes sure your apps are always updated to the current iOS. But it also comes with two serious caveats:

  1. Most people do not have the time and resources to keep updating apps that do not really need any updating if not enforced by Apple.
  2. Apple constantly deprecates and breaks features with new iOS updates. Even if your app hasn’t changed a bit, it will begin malfunctioning unless rewritten with the newer iOS. This brings me back to point 1 and you enter the endless loop.

Enter my app: Secret Photo Folder.

I developed this app years ago. The app allows you to import photos and videos, organize them into folders, add descriptions and keep them hidden with a password and outside your camera roll. It has millions of downloads and it worked perfectly. No issues whatsoever with the app. Well, no issues until Apple released the iOS 15 update. With the iOS update, I begin receiving emails that the “forgot password” option is not working any longer. Apple decided that when you press “face id” to identify yourself, you have to add a text saying something as silly as “We require Face Id to identify you”. As if pressing “face id” was not clear enough of what was about to happen.

So I load my Xcode, modify the app to add that line, compile and… errors. Tons of them. Apple has deprecated many of its APIs that handle photos and videos. And my app is mainly a photos and videos app! I find myself in a bad place: my app is working fine, but if I don’t update it to the latest iOS, it will be removed soon. On the other hand, to update it, I need to spend weeks developing and rewriting thousands of lines of code to use their new APIs. Doing the latter means I need to retest everything almost as if it was the first time I wrote this app.

After some thought, knowing that this app is used by many people I decided to bite the bullet. Weeks later I have the update ready and submit it to Apple. And guess what… that same day the app is updated, iOS 15.5 update hits the public and they included several more bugs. In particular, the app is not even able to import photos!

I’ve spent the last 3 days upgrading again the code to the latest iOS. The update is ready and submitted but the users (thousands of them) are not happy (rightly so) with the current version. I’ve gotten over 1000 emails and reviews in the app are horrible. I hope Apple releases the update asap. The problem is that Apple keeps doing this release after release. If you check the app reviews throughout the years, you will see reviews complaining about “photos can’t be imported anymore” or “colors changed”. In 2017, 2019, and now 2022. Ironically, nothing changed in the app. It was Apple making changes that broke the app with its iOS updates. Most developers give up and their apps get delisted. Myself included, I’ve let over 50 apps get delisted at this point because I don’t have enough hands to keep up. I will continue updating Secret Photo Folder because it is used by many, but oh boy! it gets hard!

If you are a developer and are having a similar experience, let me try to help you out a bit.

This code now fails to work in iOS 15.5:

[PHAsset fetchAssetsWithLocalIdentifiers:@[assetId] options:nil];

You will probably get some errors when importing Photos or Videos. Instead you need to use the url with:

[PHAsset fetchAssetsWithALAssetURLs:@[_assetURL] options:nil];

This is crazy because the last line of code is now deprecated. In theory, the correct line is the first one. I will expect Apple to fix it in the next iOS update, but for now we have no choice.

Another issue, is that the photos and videos showed up rotated. The reason is because this line does not create images as they used to:

image = [UIImage imageWithCIImage:image];

Now you need to specify the scale and orientation. Otherwise you will find most of your photos loading up in landscape. The correct method now:

image = [UIImage imageWithCIImage:image scale:1 orientation:orientation ];

Lastly, videos used to be able to load and import them with a simple call to:

PHImageManager requestImageDataForAsset:self.asset options:options resultHandler:^(NSData *imageData, NSString *uti, UIImageOrientation orientation, NSDictionary *info)

This will only work for images with the iOS update. To import videos you need to handle them independently with:

PHImageManager requestAVAssetForVideo:self.asset options:nil resultHandler:^(AVAsset *asset, AVAudioMix *audioMix, NSDictionary *info) {
AVURLAsset* urlAsset = (AVURLAsset*)asset;
                                NSNumber *size;
                                [urlAsset.URL getResourceValue:&size forKey:NSURLFileSizeKey error:nil];
                                NSData *imageData = [NSData dataWithContentsOfURL:urlAsset.URL];


And then, save that imageData to the destination folder. Happy development!