simplified the theme handling