Cleanup of the theme code