From: <ma...@ab...> - 2000-11-21 14:55:29
|
found the same "function does not always return a value"-bug in DynLayer.prototype.captureMouseEvents() solved it by quickly by adding a "return true" at the end of the function /matin > -----Original Message----- > From: martin ström [mailto:ma...@ab...] > Sent: den 21 november 2000 15:46 > To: dyn...@li... > Subject: netscape-bugs > > > i found that early netscape-versions (4.05 and below, both > win32 & mac) handles an empty array as false. > example: > > testArray=[] > if (testArray) alert(1) > else alert(2) > > normally this code should alert(1) but those > browsers alerts 2 which generates errors for > example in the include() method: > > if (DynAPI.packages[pckg]) group=DynAPI.packages[pckg].libs[groupname] > > then the group-var is not beeing set and no files are included. > > the DynAPI.removeFromArray() generates an error-message > "function does not always return a value" > > which i solved temporarly by changing the line > if (id) { delete array[which.id]; return } > > to > > if (id) { delete array[which.id]; return null} > > maybe not correctly but then i at least can make > some dynlayers on my testpage. > > i dont know if we should care about browsers this old > but thought you guys should know.. > (i think complete ns6-support is more important) > > /martin |