checkActivePage() {
        let activeItem = {}; // empty object is given so that the inner objects reference can be replace instead of pushing to the array
        for (let group of this.warehouse.navItems) {
            const activeLesson = group.lessons.filter((lesson) => lesson.current === true);
            if (activeLesson[0]) activeItem = activeLesson[0];
        }
        /* Preferred: Use for...of for no-destructive iteration over array or object values

        this.warehouse.navItems.forEach((group) => {
            const activeLesson = group.lessons.filter((lesson) => lesson.current === true);
            if (activeLesson[0]) activeItem = activeLesson[0];
        });*/

        const activeSiteNavItem = this.warehouse.siteNav.filter((navItem) => navItem.active === true);
        if (activeSiteNavItem[0]) activeItem = activeSiteNavItem[0];

        return activeItem;
    }
/**
     * checkActivePage  ::  Void  ->  {title: String, group: String, current/active: Boolean, pages: Number, currentPage: Number}
     * 
     * Method checks the warehouse navItems for a single page object that has a property of current or a active with a value of true
     * 
     * Returns the page object with a current/active property of true
     */


Method checks the warehouse navItems for a single page object that has a property of current or a active with a value of true

Returns the page object with a current/active property of true
Method checks the warehouse navItems for a single page object that has a property of current or a active with a value of true Returns the page object with a current / active property of true
checkActivePage() {
        let activeItem = {}; 
        for (let group of this.warehouse.navItems) {
            const activeLesson = group.lessons.filter((lesson) => lesson.current === true);
            if (activeLesson[0]) activeItem = activeLesson[0];
        }
        const activeSiteNavItem = this.warehouse.siteNav.filter((navItem) => navItem.active === true);
        if (activeSiteNavItem[0]) activeItem = activeSiteNavItem[0];
        return activeItem;
    }
checkActivePage ( ) { let activeItem = { } ; for ( let group of this . warehouse . navItems ) { const activeLesson = group . lessons . filter ( ( lesson ) => lesson . current === true ) ; if ( activeLesson [ 0 ] ) activeItem = activeLesson [ 0 ] ; } const activeSiteNavItem = this . warehouse . siteNav . filter ( ( navItem ) => navItem . active === true ) ; if ( activeSiteNavItem [ 0 ] ) activeItem = activeSiteNavItem [ 0 ] ; return activeItem ; }
checkActivePage  ::  Void  ->  {title: String, group: String, current/active: Boolean, pages: Number, currentPage: Number}
checkActivePage :: Void - > { title : String group : String current / active : Boolean pages : Number currentPage : Number }
// empty object is given so that the inner objects reference can be replace instead of pushing to the array /* Preferred: Use for...of for no-destructive iteration over array or object values

        this.warehouse.navItems.forEach((group) => {
            const activeLesson = group.lessons.filter((lesson) => lesson.current === true);
            if (activeLesson[0]) activeItem = activeLesson[0];
        });*/