Fix PoliciesUtils to handle missing default/user preference values
Categories
(Firefox Enterprise :: Client, defect)
Tracking
(Not tracked)
People
(Reporter: janika, Assigned: janika)
References
(Blocks 2 open bugs)
Details
(Whiteboard: [size=1])
Attachments
(1 file)
When a policy changes a default preference, we save the default and user value of the preference when applying the policy and we restore the them when the policy is removed.
The test browser/components/enterprisepolicies/tests/browser/trackingprotection/browser_policy_trackingprotection.js is failing because in saveDefaultPref we call defaults.getStringPref for a preference that has no default preference value.
We should add a fallback when retrieving preference values that potentially don't exist, and only restore the preference when the stored preference value is not null.
Comment 1•29 days ago
|
||
Comment 2•28 days ago
|
||
Authored by https://github.com/1rneh
https://github.com/mozilla/enterprise-firefox/commit/11acd910851157e4c161e4eb32623217ab1d0f0a
[enterprise-main] Bug 2034176 - Fix PoliciesUtils to handle missing default/user pref values (#769)
Description
•