* add checks that session != NULL