Skip to content

Commit

Permalink
Fix configuration/feature-mapping enabling (#3216)
Browse files Browse the repository at this point in the history
  • Loading branch information
seriva authored Jul 13, 2022
1 parent 19c9770 commit 84f4fc6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG-1.0.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog 1.0

## [1.0.6] 2022-xx-xx

### Fixed

- [#3189](https://github.com/epiphany-platform/epiphany/issues/3189) - Fix configuration/feature-mapping enabling

## [1.0.5] 2022-06-24

### Fixed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ def get_inventory(self):

def get_roles_for_feature(self, component_key):
features_map = select_single(self.config_docs, lambda x: x.kind == 'configuration/feature-mapping')
return features_map.specification.roles_mapping[component_key]
feature_roles = features_map.specification.roles_mapping[component_key]
enabled_roles = self.get_enabled_roles()
return [role for role in feature_roles if role in enabled_roles]

def get_available_roles(self):
features_map = select_single(self.config_docs, lambda x: x.kind == 'configuration/feature-mapping')
Expand Down

0 comments on commit 84f4fc6

Please sign in to comment.