returning main after register