Added exists function to know if an entry exists or not