Renamed function from digestIds to updateIdRegister
Added methods to unique id generation & improved code formatting