Cleanup of custom theme code