- add getUsername function on register lib