Made a method private in Session class as it shouldn't be used outside the class.