removed unused rregister and added doc