Skip to content

Commit

Permalink
Merge pull request #725 from ombhardwajj/spacefix
Browse files Browse the repository at this point in the history
#707 | Leading spaces when creating users are now trimmed!
  • Loading branch information
vinayvenu authored May 6, 2024
2 parents b60b6c9 + 0bb271d commit fedb871
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ public String getUsername() {
}

public void setUsername(String username) {
this.username = username;
this.username = username != null ? username.trim() : null;
}

public String getName() {
return name;
}

public void setName(String name) {
this.name = name;
this.name = name != null ? name.trim() : null;
}

public Long getId() {
Expand All @@ -49,4 +49,5 @@ public String getUuid() {
public void setUuid(String uuid) {
this.uuid = uuid;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,4 @@ public InputStream downloadErrorFile(String jobUuid) {
S3File s3File = S3File.organisationFile(UserContextHolder.getOrganisation(), format("%s.csv", jobUuid), S3FileType.BulkUploadsError);
return s3Service.getFileStream(s3File);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -202,4 +202,4 @@ private UserCreateStatus createCognitoUser(AdminCreateUserRequest createUserRequ
}
return userCreateStatus;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -121,4 +121,4 @@ public User getUserFromToken(String token) throws SigningKeyNotFoundException {
return null;
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ public ResponseEntity<?> doit(@RequestParam MultipartFile file,
@RequestParam String type,
@RequestParam boolean autoApprove,
@RequestParam String locationUploadMode) throws IOException {

accessControlService.checkPrivilege(PrivilegeType.UploadMetadataAndData);
validateFile(file, type.equals("metadataZip") ? ZipFiles : Collections.singletonList("text/csv"));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public String getUsername() {
}

public void setUsername(String username) {
this.username = username;
this.username = username != null ? username.trim() : null;
}

public Long getCatchmentId() {
Expand Down Expand Up @@ -196,4 +196,5 @@ public List<String> getUserGroupNames() {
public void setUserGroupNames(List<String> userGroupNames) {
this.userGroupNames = userGroupNames;
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public String getUsername() {
}

public void setUsername(String username) {
this.username = username;
this.username = username != null ? username.trim() : null;
}

public String getOrganisationName() {
Expand All @@ -69,7 +69,7 @@ public String getName() {
}

public void setName(String name) {
this.name = name;
this.name = name != null ? name.trim() : null;
}

public JsonObject getSyncSettings() {
Expand All @@ -95,4 +95,5 @@ public List<String> getUserGroupNames() {
public void setUserGroupNames(List<String> userGroupNames) {
this.userGroupNames = userGroupNames;
}

}

0 comments on commit fedb871

Please sign in to comment.