This function should probably have a more generic name. The pattern here is a general "if not loaded do this, then do this once loaded".

We can use this for all sorts of similar operations but it needs to have a better name.