Added id function to session