edited register in utils.py to be cleaner