MCPcopy Create free account
hub / github.com/ClearURLs/Addon / resetGlobalCounter

Function resetGlobalCounter

core_js/popup.js:161–181  ·  view source on GitHub ↗

* Reset the global statistic

()

Source from the content-addressed store, hash-verified

159* Reset the global statistic
160*/
161function resetGlobalCounter(){
162 browser.runtime.sendMessage({
163 function: "setData",
164 params: ['cleanedCounter', 0]
165 }).catch(handleError);
166
167 browser.runtime.sendMessage({
168 function: "setData",
169 params: ['totalCounter', 0]
170 }).catch(handleError);
171
172 browser.runtime.sendMessage({
173 function: "saveOnExit",
174 params: []
175 }).catch(handleError);
176
177 cleanedCounter = 0;
178 totalCounter = 0;
179
180 changeStatistics();
181}
182
183(function() {
184 loadData("cleanedCounter")

Callers

nothing calls this directly

Calls 1

changeStatisticsFunction · 0.85

Tested by

no test coverage detected