Added active class function