Are you sure you have chosen images of jpeg format?
As far as I tried, I could not get a URL for heic image with your code, but could get URLs for jpeg image.
Please try: configuration.preferredAssetRepresentationMode = .current
Use UTType.image.identifier ("public.image") for type identifier
Topic:
Programming Languages
SubTopic:
Swift
Tags: