Skip to content

Commit

Permalink
Use the actual value, not just the index in the array.
Browse files Browse the repository at this point in the history
  • Loading branch information
ahocevar committed Mar 3, 2013
1 parent db52ff9 commit 63c048e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/ol/layer/vectorlayer.js
Expand Up @@ -42,7 +42,7 @@ ol.layer.Vector.prototype.groupFeaturesBySymbolizerLiteral =
var uniqueLiterals = {},
featuresBySymbolizer = [],
style = this.style_,
feature, literals, literal, key;
feature, literals, literal, uniqueLiteral, key;
for (var i = 0, ii = features.length; i < ii; ++i) {
feature = features[i];
literals = goog.isNull(style) ?
Expand All @@ -51,8 +51,9 @@ ol.layer.Vector.prototype.groupFeaturesBySymbolizerLiteral =
for (var j = 0, jj = literals.length; j < jj; ++j) {
literal = literals[j];
for (var l in uniqueLiterals) {
if (literal.equals(uniqueLiterals[l])) {
literal = uniqueLiterals[l];
uniqueLiteral = featuresBySymbolizer[uniqueLiterals[key]][1];
if (literal.equals(uniqueLiteral)) {
literal = uniqueLiteral;
break;
}
}
Expand Down

0 comments on commit 63c048e

Please sign in to comment.