Changed the Cache handling and cleaned up the Registration module code.