Snippets: Remove theme_mods set to their default value

By default WordPress saves any customizer setting that had been previously modified even if it was modified back to the default state. This means if you change for example your header background (which by default is an empty option) to black then change it back to the default state (empty) WordPress will save in your theme mods an empty value for this setting rather then removing it from your entire theme_mods array. By enabling this filter in the Total theme any setting currently set to it's default will be removed to slim down your theme_mods array. This process runs in the wp_head hook when the theme generates the inline CSS from the theme mods. See framework/customizer/customizer.php for more details.

add_filter( 'wpex_remove_default_mods', '__return_true' );
All PHP snippets should be added via a child theme's functions.php file.