add first register function