Linking up logout handling