diff --git a/autotag/src/AutoTagForm.jsx b/autotag/src/AutoTagForm.jsx index 952b8a6..be356d0 100644 --- a/autotag/src/AutoTagForm.jsx +++ b/autotag/src/AutoTagForm.jsx @@ -93,12 +93,6 @@ export default class AutoTagForm extends React.Component { token = tokenMap.get(value); token.increment(tokenType); - // Also, update the maxTokenCardinality if this is higher than the current - // maximum recorded value - if (token.count > this.state.maxTokenCardinality) { - this.state.maxTokenCardinality = token.count; - } - // Otherwise, create the entry and do any token -> tag matching } else { token = new Token(value, tokenType); @@ -341,7 +335,7 @@ export default class AutoTagForm extends React.Component { tokenMap: tokenMap, unmappedTags: unmappedTags, requiredTokenCardinality: images.size === 1 ? 1 : 2, - maxTokenCardinality: this.state.maxTokenCardinality + maxTokenCardinality: images.size }); } diff --git a/autotag/static/autotag/js/bundle.js b/autotag/static/autotag/js/bundle.js index 3751950..3656776 100644 --- a/autotag/static/autotag/js/bundle.js +++ b/autotag/static/autotag/js/bundle.js @@ -19808,12 +19808,6 @@ var autotagform = token = tokenMap.get(value); token.increment(tokenType); - // Also, update the maxTokenCardinality if this is higher than the current - // maximum recorded value - if (token.count > this.state.maxTokenCardinality) { - this.state.maxTokenCardinality = token.count; - } - // Otherwise, create the entry and do any token -> tag matching } else { token = new _Token2.default(value, tokenType); @@ -20031,7 +20025,7 @@ var autotagform = tokenMap: tokenMap, unmappedTags: unmappedTags, requiredTokenCardinality: images.size === 1 ? 1 : 2, - maxTokenCardinality: _this2.state.maxTokenCardinality + maxTokenCardinality: images.size }); });