@Max - thanks, that solved my issue too.
I had "guard let path = path else { return }" , which when changed to "guard let goodPath = path else { return }" solved the problem.
Strange, as there are loads of examples online/tutorials/books that use that form, but for some reason Swift doesn't like it.
(Xcode 12.5.1, Swift 5)
Topic:
Programming Languages
SubTopic:
Swift
Tags: