Move add_shortcode() and add_filter() to below function definitions