Fix to session usage