<?php
/**
 * Body Classes.
 * @package Omega Digital Store
 */

if (!function_exists('omega_digital_store_body_classes')) :

    function omega_digital_store_body_classes($omega_digital_store_classes)
    {
        $omega_digital_store_defaults = omega_digital_store_get_default_theme_options();
        $omega_digital_store_layout = omega_digital_store_get_final_sidebar_layout();

        // Adds a class of hfeed to non-singular pages.
        if (!is_singular()) {
            $omega_digital_store_classes[] = 'hfeed';
        }

        // Sidebar layout logic
        $omega_digital_store_classes[] = $omega_digital_store_layout;

        // Copyright alignment
        $copyright_alignment = get_theme_mod('omega_digital_store_copyright_alignment', 'Default');
        $omega_digital_store_classes[] = 'copyright-' . strtolower($copyright_alignment);

        return $omega_digital_store_classes;
    }

endif;

add_filter('body_class', 'omega_digital_store_body_classes');