Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 369007 - Navigator error in Safari
Summary: Navigator error in Safari
Status: RESOLVED FIXED
Alias: None
Product: Orion
Classification: ECD
Component: Client (show other bugs)
Version: 0.4   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: 0.4 M2   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-18 16:20 EST by Mark Macdonald CLA
Modified: 2012-01-23 17:22 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Macdonald CLA 2012-01-18 16:20:01 EST
There is an implementation of Function.prototype.bind in editor.js. It is injected into Function.prototype as a patch for browsers that don't support bind (namely, Safari).

Since bind() is now required by the Navigator code, this patch should be moved into common code that's used by the navigator as well.

Note: bug 369004 currently prevents you from seeing this issue, since editor.js is pulled in by the navigator. Once that's fixed, bind() will not be injected and the navigator will blow up in Safari like so:

Error
  line: 888
  message: "'undefined' is not a function (evaluating 'uriTemplate.expand.bind(uriTemplate)')"
  sourceURL: "http://localhost:8080/orion/fileCommands.js"
Comment 1 Mark Macdonald CLA 2012-01-23 17:22:21 EST
Disregard the suggestion in Comment 0... it's easier to just use dojo.hitch in this case. bind can be moved later if it's needed by more dojoless code.

http://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?id=aba4b30218fac777dd6616e167eb459745c232c6