MDL-38303 cache: fixed purging of session cache when switching users