Skip to content

Commit

Permalink
SHIBUI-1437 Resolved merge conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
rmathis committed Sep 26, 2019
2 parents 71e9cdb + e9ef6e2 commit a50bbe0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export class MetadataConfigurationComponent implements OnChanges {
) {}

ngOnChanges(): void {
this.zero = this.configuration.sections.some(s => !s.properties.length);
this.zero = !this.configuration.sections.some(s => !!s.properties.length);
}

edit(id: string): void {
Expand Down
7 changes: 3 additions & 4 deletions ui/src/app/metadata/configuration/reducer/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,11 @@ export const processSchemaFn = (definition, schema) => {
};

export const getConfigurationSchema = createSelector(getConfigurationDefinition, getSchema, processSchemaFn);

export const getConfigurationModelEnabledFn =
(config: Metadata) => config ? ('serviceEnabled' in config) ? config.serviceEnabled : config.enabled : false;

export const getConfigurationModelNameFn =
(config: Metadata) => config ? ('serviceProviderName' in config) ? config.serviceProviderName : config.name : false;
(config: Metadata) => config ? ('serviceProviderName' in config) ? config.serviceProviderName : config.name : '';

export const getConfigurationModelTypeFn =
(config: Metadata) => config ? ('@type' in config) ? config['@type'] : 'resolver' : null;
Expand All @@ -82,8 +81,8 @@ export const isAdditionalFilter = (type) => filterPluginTypes.indexOf(type) ===

export const getVersionModelFiltersFn =
(model, kind) => kind === 'provider' ?
model.metadataFilters.filter(filter => isAdditionalFilter(filter['@type'])) :
null;
model.metadataFilters ? model.metadataFilters.filter(filter => isAdditionalFilter(filter['@type'])) :
[] : null;

// Version History

Expand Down

0 comments on commit a50bbe0

Please sign in to comment.