Got the registration part working