Move theme initialisation to happen earlier