I've come to the unfortunate point where I will need to recreate a singleton.
It looks like this
class Myplayer: AVPlayer {
    static let sharedInstance: Myplayer = {
        let instance = Myplayer()
        return instance
    }()
As you can see from this, the reason for this is that AVPlayer can sometimes come into a failed state (.status == .failed) and the documentation specifically mentions that the instance itself will need to be recreated in order to work any further.
I have wound up my app with this singleton pattern and have a few months of live traction with it so changing this to a non-singleton pattern would likely take too much work at this point.
So my question is, how can I recreate this singleton in a pretty way?
 
     
     
     
    