fix duplicate logout