bugfix for empty session