A UrlbarProvider would expect to receive onEngagement only for its own results, but currently we notify it to ALL providers. This is very error prone as if one forgets about this detail they may end up handling the wrong results. IIRC there was a reason related to either telemetry or the experimental API (that we'd like to remove in bug 1855958 anyway) We could then remove the various checks for result.providerName in the onEngagement implementations.
Bug 1857236 Comment 0 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
A UrlbarProvider would expect to receive onEngagement only for its own results, but currently we notify it to ALL providers. This is very error prone as if one forgets about this detail they may end up handling the wrong results. IIRC there was a reason related to either telemetry or the experimental API (that we'd like to remove in bug 1855958 anyway), we must check. We could then remove the various checks for result.providerName in the onEngagement implementations.
A UrlbarProvider would expect to receive onEngagement only for its own results, but currently we notify it to ALL providers. This is very error prone as if one forgets about this detail they may end up handling the wrong results. IIRC there was a reason related to either telemetry, impressions counting, or the experimental API (that we'd like to remove in bug 1855958 anyway), we must check. We could then remove the various checks for result.providerName in the onEngagement implementations.