Skip to content

Commit

Permalink
Fix golang linter
Browse files Browse the repository at this point in the history
  • Loading branch information
haoming29 committed Jan 18, 2024
1 parent ed670df commit 553cfac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion registry/registry_validation.go
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ func validateInstitution(instID string) (bool, error) {
// backward compatible with legacy custom fields that were once defined but removed
func validateCustomFields(customFields map[string]interface{}, exactMatch bool) (bool, error) {
if len(customRegFieldsConfigs) == 0 {
if customFields != nil && len(customFields) > 0 {
if len(customFields) > 0 {
return false, errors.New("Bad configuration, Registry.CustomRegistrationFields is not set while validate against custom fields")
} else {
return true, nil
Expand Down

0 comments on commit 553cfac

Please sign in to comment.