mirror of
https://github.com/nasa/openmct.git
synced 2025-03-23 04:25:27 +00:00
[Core] Obey priority for capabilities
Obey priority for capabilities to allow this to be overridden for other domain object types, WTD-1223.
This commit is contained in:
parent
3b62add011
commit
71ca9803c2
@ -53,7 +53,7 @@ define(
|
||||
function packageCapabilities(capabilities) {
|
||||
var result = {};
|
||||
capabilities.forEach(function (capability) {
|
||||
if (capability.key) {
|
||||
if (capability.key && !result[capability.key]) {
|
||||
result[capability.key] = capability;
|
||||
} else {
|
||||
$log.warn("No key defined for capability; skipping.");
|
||||
@ -91,4 +91,4 @@ define(
|
||||
|
||||
return CoreCapabilityProvider;
|
||||
}
|
||||
);
|
||||
);
|
||||
|
Loading…
x
Reference in New Issue
Block a user