[issue #86] [Updated] adds maximum validation to username
[issue #86] [Updated] fixes redundant code
[issue #86] [Updated] deletes reduntant conde