JavaScript strict warning: ds is being redeclared in sidebarOverlay.js

RESOLVED WORKSFORME

Status

SeaMonkey
Sidebar
RESOLVED WORKSFORME
15 years ago
13 years ago

People

(Reporter: Brant Gurganus, Assigned: Samir Gehani)

Tracking

Trunk
x86
Windows XP

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

15 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3b) Gecko/20030122
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3b) Gecko/20030122

Apparently the variable named ds is being redeclared in sidebarOverlay.js

Reproducible: Always

Steps to Reproduce:
1. Exit Mozilla completely.
2. Start mozilla -jsconsole.
3. Click Tools > Navigator.
Actual Results:  
The following warning appears in the JavaScript console:

Warning: redeclaration of var ds
Source File: chrome://communicator/content/sidebar/sidebarOverlay.js
Line: 805, Column: 8
Source Code:
    var ds = RDF.GetDataSource(sidebarObj.datasource_uri);

Expected Results:  
There should be no redeclaration.

This is a strict warning so you need to enable them in Advanced preferences to
see this warning.

I searched for duplicates using "redeclaration ds" and found none.

The variable is being redeclared in the sidebar_open_default_panel(wait, tries)
function.  If the conditional is met in the function, the variable is declared
again.  I believe that the second var ds= withing the conditional can have the
var statement removed to solve the problem.

Updated

15 years ago
Summary: ds is being redeclared → JavaScript strict warning: ds is being redeclared in sidebarOverlay.js

Comment 1

14 years ago
Looks like this has been fixed. Marking WFM, please reopen if you can reproduce.
Status: NEW → RESOLVED
Last Resolved: 14 years ago
Resolution: --- → WORKSFORME
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.