Fixed logout directive bug