Closed Bug 1627652 Opened 5 years ago Closed 5 years ago

"Undefined" message is received when running manual snippets for cookie clearance

Categories

(Core :: Privacy: Anti-Tracking, defect)

defect
Not set
normal

Tracking

()

RESOLVED INVALID
Tracking Status
firefox76 --- wontfix

People

(Reporter: sbadau, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

Attached image 2020-04-06_14h49_25.png

Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:76.0) Gecko/20100101 Firefox/76.0
Build ID: 20200406092400

Affected versions

  • Nightly 76.0a1

Affected platforms

  • all

Prerequisites

  • Go to about:config and set the preferences:
    -- privacy.purge_trackers.enabled = true.
    -- privacy.purge_trackers.logging.level = All

  • Make sure that in the Settings of the Web Console, "Enabled browser chrome and add-on debugging toolboxes" is checked.

Steps to reproduce

  1. Open Firefox.
  2. Open the Browser console
  3. Run the snippet to trigger the 30 days cookie clean-up manually:
    await Components.classes["@mozilla.org/purge-tracker-service;1"].getService(Components.interfaces.nsIPurgeTrackerService).purgeTrackingCookieJars()
  4. Run the snippet to trigger the idle-daily notification manually:
    Services.obs.notifyObservers(null, "idle-daily");

Expected result

  • In steps 3 and 4, the manual cookie clearance should be properly done and end in logs like:
    *** PurgeTrackerService: Purging trackers enabled, beginning batch.
    *** PurgeTrackerService: Batch finished, queueing next batch.
    *** PurgeTrackerService: Purging trackers enabled, beginning batch.
    *** PurgeTrackerService: All cookie purging finished, resetting list until tomorrow.

Actual result

  • In steps 3 and 4, an "undefined" message is triggered first.

Thanks for the report. This is expected since both of these commands do not have a return value. This is just a consequence of how the console displays null return values.

Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: