Open Bug 1870135 Opened 11 months ago Updated 8 months ago

Revamp logic behind data size parameters for clear history dialog

Categories

(Toolkit :: Data Sanitization, enhancement, P3)

enhancement

Tracking

()

People

(Reporter: hsohaney, Unassigned)

References

(Blocks 1 open bug)

Details

The logic behind connecting the Sanitizer and Sanitize Dialog to get data sizes can be simplified and made easier to read. The data fetching code is currently inefficient since it has to loop through all sites and count data, instead of doing db fetching through the clearDataService.
https://searchfox.org/mozilla-central/rev/8340afd1fb3e7b2727d2efb47df1bd3112db7213/browser/modules/SiteDataManager.sys.mjs#401

Harshit, is this bug still applicable? If so, could you please update the description to explain better what needs to be updated?

Severity: -- → N/A
Flags: needinfo?(hsohaney)

I think the code is a bit inefficient right now since it has to loop through all the sites to get the values: https://searchfox.org/mozilla-central/rev/8340afd1fb3e7b2727d2efb47df1bd3112db7213/browser/modules/SiteDataManager.sys.mjs#401
We should probably make this better, but it is a backlog item. What are your thoughts?

Flags: needinfo?(hsohaney) → needinfo?(pbz)

How could we make it more efficient? :) Could you please add that to the bug description?

Flags: needinfo?(pbz) → needinfo?(hsohaney)
Flags: needinfo?(hsohaney)
You need to log in before you can comment on or make changes to this bug.