logic change to getSession()