Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions api/src/org/labkey/api/exp/api/SampleTypeDomainKind.java
Original file line number Diff line number Diff line change
Expand Up @@ -488,6 +488,7 @@ public void validateOptions(Container container, User user, SampleTypeDomainKind
ExpSampleType sampleType = options.getRowId() >= 0 ? ss.getSampleType(options.getRowId()) : null;
Domain stDomain = sampleType != null ? sampleType.getDomain() : null;
Set<String> reservedNames = new CaseInsensitiveHashSet(this.getReservedPropertyNames(stDomain, user));
reservedNames.add("Parent"); // Issue 52627: Don't allow "Parent" to be used for lineage parent import alias
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Surprises me that "Parent" isn't already a reserved name in general.

Set<String> existingAliases = new CaseInsensitiveHashSet();

try
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ private void updateLookupSchema(String newValue, String oldSchema, Container con
@Override
public void queryChanged(User user, Container container, ContainerFilter scope, SchemaKey schema, @NotNull QueryProperty property, @NotNull Collection<QueryPropertyChange<?>> changes)
{
if (!property.equals(QueryProperty.SchemaName) && !property.equals(QueryProperty.Name)) // Issue 53846
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: I tend to practice doing enumerated equivalency checks the other way around to avoid potential NPE. I see that this property is annotated as @NotNull.

if (!QueryProperty.SchemaName.equals(property) && !QueryProperty.Name.equals(property)) // Issue 53846
    return;

return;

// is there any other schema change other than assay renaming?
boolean isSchemaChange = schema.toString().toLowerCase().startsWith("assay.general.");

Expand Down