LoadLevel destroys objects too soon

For instance, I have a StoreManager which is a singleton. On another object I subscribe to a delegate on the StoreManager in Awake() and unsubscribe in OnDestroy().

However, sometimes the unsubscribe goes as planned, but sometimes the reference to the StoreManager is gone/destroyed by the LoadLevel function (null) when I’m trying to unsubscribe in OnDestroy().

Is there any way I can prevent this behavior?

the thing you are trying to unsubscribe from is already destroyed… just before the script itself is destroyed…

so… just a null check before you try to unsubscribe in the OnDestory?

if both parties are being destroyed does it really matter that you unsubscribe?