Skip to content

Commit

Permalink
Revert "Remove role listitem from sourceCache attribution"
Browse files Browse the repository at this point in the history
This reverts commit 0f614e2.
  • Loading branch information
kumilange committed Aug 19, 2023
1 parent 0f614e2 commit 73706e6
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/ui/control/attribution_control.js
Original file line number Diff line number Diff line change
Expand Up @@ -168,12 +168,9 @@ class AttributionControl {
const sourceCache = sourceCaches[id];
if (sourceCache.used) {
const source = sourceCache.getSource();
if (source?.attribution && attributions.indexOf(source.attribution) < 0) {
if (source.attribution && attributions.indexOf(source.attribution) < 0) {
// $FlowFixMe[incompatible-call] - Flow can't infer that attribution is a string
if (typeof source.attribution === "string") {
const attributionRoleRemoved = source.attribution.replaceAll(`role=\"listitem\"`, "");
attributions.push(attributionRoleRemoved);
}
attributions.push(source.attribution);
}
}
}
Expand Down

0 comments on commit 73706e6

Please sign in to comment.