Closed Bug 228433 Opened 21 years ago Closed 21 years ago

Error ``node has no properties'' [xs] in file ``chrome://communicator/content/bookmarks/bookmarks.js'', line 1077, character 0.

Categories

(SeaMonkey :: Bookmarks & History, defect)

x86
Windows XP
defect
Not set
trivial

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: timeless, Assigned: neil)

Details

Attachments

(2 files)

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.6b) Gecko/20031208

Error ``node has no properties'' [xs] in file
``chrome://communicator/content/bookmarks/bookmarks.js'', line 1077, character 0.
Stopped for error handler.
#0: function anonymous(aInput=XPComponent:{7},
aArcURI=string:"http://home.netscape.com/NC-rdf#FolderGroup", aDS=void:void) in
<chrome://communicator/content/bookmarks/bookmarks.js> line 1077
1075: node = aDS .GetTarget(aInput, arc, true);
1076: try {
1077: return node.QueryInterface(kRDFRSCIID).Value;
Attachment #137393 - Flags: superreview?(bz-vacation)
Attachment #137393 - Flags: review?(neil.parkwaycc.co.uk)
Comment on attachment 137393 [details] [diff] [review]
skip the try block for null node

er, sure.  sr=bzbarsky
Attachment #137393 - Flags: superreview?(bz-vacation) → superreview+
Attached patch instanceofSplinter Review
This is an excellent example of the usefulness of instanceof.
Attachment #137654 - Flags: review?(timeless)
Attachment #137654 - Flags: superreview?(bz-vacation)
Attachment #137654 - Flags: review?(timeless)
Attachment #137654 - Flags: review+
Attachment #137393 - Flags: review?(neil.parkwaycc.co.uk)
Assignee: timeless → neil.parkwaycc.co.uk
Comment on attachment 137654 [details] [diff] [review]
instanceof

sr=bzbarsky if you combine those if statements into a single if statement:

if (node instanceof foo || node instanceof bar)
  return node.Value;
Attachment #137654 - Flags: superreview?(bz-vacation) → superreview+
I also changed it to a ?:
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: