fix the logic to show correctly the statusline