I have a problem with MochiKit.Signal in IE 6.
When I leave a page that uses MochiKit.Signal (even if it's just
included not really used) i get the error: "Object 'length' is null or
..." (Freely translated from German error message).
This is the corresponding code where the error happens:
Signal.js:
_unloadCache: function () {
var self = MochiKit.Signal;
var observers = self._observers;
for (var i = 0; i < observers.length; i++) {
-----------------------------------------------^ that's the bad boy
self._disconnect(observers[i]);
}
Some hints that I can come up with:
- It works on FF and IE 7
- Tests are passing
- Fails with some earlier version from SVN trunk and current SVN trunk
- I'm also using MochiKit.Sortable
- MochiKit.Signal._observer seems to disappear too early. But the
unload method seems not to be called twice.
Thanks for any help in advance,
Christian
Always include the MochiKit javascript first, and then your own user
libraries. Otherwise you'll get weird errors that are hard to
understand and hard to debug.