Closed
Bug 188800
Opened 22 years ago
Closed 21 years ago
js errors on addressing pref panel with --disable-ldap, address collection prefs broken
Categories
(MailNews Core :: LDAP Integration, defect)
MailNews Core
LDAP Integration
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla1.6alpha
People
(Reporter: tuukka.tolvanen, Assigned: Stefan.Borggraefe)
Details
Attachments
(1 file, 1 obsolete file)
2.04 KB,
patch
|
timeless
:
review+
dmosedale
:
superreview+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3a) Gecko/20030107 Phoenix/0.5 Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3b) Gecko/20030112 In my builds with --disable-ldap, displaying the mail>addressing pref panel gives the following errors on js console: -------------------------------- Warning: reference to undefined property Components.classes['@mozilla.org/ldapprefs-service;1'] Source File: chrome://messenger/content/addressbook/pref-directory.js Line: 12 Warning: reference to undefined property Components.classes['@mozilla.org/ldapprefs-service;1'] Source File: chrome://messenger/content/addressbook/pref-directory.js Line: 12 Error: Components.classes['@mozilla.org/ldapprefs-service;1'] has no properties Source File: chrome://messenger/content/addressbook/pref-directory.js Line: 12 Error: gAvailDirectories has no properties Source File: chrome://messenger/content/addressbook/pref-directory.js Line: 65 -------------------------------- The email collection prefs on the panel don't stick -- changing them, hitting OK and reopening prefs reverts them. Building without --disable-ldap fixes these issues. Reproducible: Always Steps to Reproduce: 1. build with --disable-ldap 2. menu: edit > prefs > mail > addressing -> above 4 js errors 3. change address collection prefs, hit ok 4. bring up the pref panel again -> changed prefs reverted Actual Results: js errors, prefs reverted Expected Results: no js errors, pref changes retained
Comment 1•22 years ago
|
||
We need some try/catch blocks here...
Assignee | ||
Comment 2•21 years ago
|
||
Fixes the bug. Is there a way to avoid the JS strict warning, too?
Assignee | ||
Updated•21 years ago
|
Attachment #133483 -
Flags: review?(timeless)
Comment on attachment 133483 [details] [diff] [review] Patch it occurs to me that i probably have a tree with this patched... anyway, if you use this in your init function people should be happier: const LDAP_PREF_CONTRACT="@mozilla.org/ldapprefs-service;1"; if (LDAP_PREF_CONTRACT in Components.classes) gLDAPPrefsService = Components.classes[LDAP_PREF_CONTRACT].getService(Components.interfaces.nsILDAP PrefsService);
Attachment #133483 -
Flags: review?(timeless) → review-
oh and you should only call the function if the object is non null: if (gLDAPPrefsService) arrayOfDirectories = gLDAPPrefsService.getServerList(gPrefInt, prefCount);
Assignee: srilatha → borggraefe
Assignee | ||
Comment 5•21 years ago
|
||
Assignee | ||
Updated•21 years ago
|
Attachment #133483 -
Attachment is obsolete: true
Assignee | ||
Updated•21 years ago
|
Attachment #133512 -
Flags: review?(timeless)
Assignee | ||
Updated•21 years ago
|
OS: Linux → All
Hardware: PC → All
Target Milestone: --- → mozilla1.6alpha
Attachment #133512 -
Flags: superreview?(dmose)
Attachment #133512 -
Flags: review?(timeless)
Attachment #133512 -
Flags: review+
Comment 6•21 years ago
|
||
Comment on attachment 133512 [details] [diff] [review] Updated Patch sr=dmose@mozilla.org
Attachment #133512 -
Flags: superreview?(dmose) → superreview+
Assignee | ||
Comment 7•21 years ago
|
||
Thanks for checking this in, timeless! :-) Marking FIXED.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
Updated•20 years ago
|
Product: MailNews → Core
Updated•16 years ago
|
Product: Core → MailNews Core
You need to log in
before you can comment on or make changes to this bug.
Description
•