UI: end database session on close