fix logout issue