Added comments and get user by username

Added extensive commenting and an useful method.