operasoftware / dragonfly

Opera Dragonfly is a fully featured development and debugging tool integrated into the Opera browser.
http://www.opera.com/dragonfly/
Apache License 2.0
160 stars 48 forks source link

Fix for DFL-3706, Exception in window.templates.resource_tree._get_short_distinguisher #125

Closed p01 closed 12 years ago

danfooo commented 12 years ago

Have you checked how a resource can not have a url? We should normally instantiate a new resource on urlload, that should have the URL already.

p01 commented 12 years ago

That's right. I have not seen instances of ResourceInfo without a URL. OTOH the ListDocuments command of the document-manager has returned documents without a URL.

danfooo commented 12 years ago

Is it not the resources that get mocked in resource_service.js:479?

p01 commented 12 years ago

The url and callback of cls.ResourceRequest are not optional. cls.ResourceRequest requests the resource for a given url and calls the callback when the payload comes back.

Also, checking the callstack in DFL-3706, shows it threw when called from window.templates.resource_tree.document(...)

danfooo commented 12 years ago

Okay, I see. Looks fine then.