Fixed logout from edit issue