Fix the sidebar refresh issue