mirror of
https://github.com/flynx/features.js.git
synced 2025-12-25 04:21:58 +00:00
bugfix...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
abd5da3dac
commit
d3122cb15d
10
features.js
10
features.js
@ -710,6 +710,7 @@ var FeatureSetProto = {
|
|||||||
// Handle exclusive feature groups and aliases...
|
// Handle exclusive feature groups and aliases...
|
||||||
var conflicts = {}
|
var conflicts = {}
|
||||||
var done = []
|
var done = []
|
||||||
|
var aliases = []
|
||||||
Object.keys(features)
|
Object.keys(features)
|
||||||
.forEach(function(f){
|
.forEach(function(f){
|
||||||
// alias...
|
// alias...
|
||||||
@ -732,8 +733,10 @@ var FeatureSetProto = {
|
|||||||
// remove the alias...
|
// remove the alias...
|
||||||
// NOTE: exclusive tag can match a feature tag, thus
|
// NOTE: exclusive tag can match a feature tag, thus
|
||||||
// we do not want to delete such tags...
|
// we do not want to delete such tags...
|
||||||
|
// NOTE: we are not removing aliases here as they may
|
||||||
|
// get added/expanded back in by other features...
|
||||||
if(!(f in that)){
|
if(!(f in that)){
|
||||||
delete features[f]
|
aliases.push(f)
|
||||||
}
|
}
|
||||||
// replace dependencies...
|
// replace dependencies...
|
||||||
Object.keys(features)
|
Object.keys(features)
|
||||||
@ -758,6 +761,11 @@ var FeatureSetProto = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
// XXX remove exclusive aliases...
|
||||||
|
aliases
|
||||||
|
.forEach(function(f){
|
||||||
|
delete features[f]
|
||||||
|
})
|
||||||
// resolve any exclusivity conflicts found...
|
// resolve any exclusivity conflicts found...
|
||||||
var excluded = []
|
var excluded = []
|
||||||
Object.keys(conflicts)
|
Object.keys(conflicts)
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "ig-features",
|
"name": "ig-features",
|
||||||
"version": "3.3.2",
|
"version": "3.3.3",
|
||||||
"description": "",
|
"description": "",
|
||||||
"main": "features.js",
|
"main": "features.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user