fix logout, by adding sid