moving registration code in interface