Skip to content

Instantly share code, notes, and snippets.

@tmcw
Last active August 29, 2015 14:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tmcw/7f46b270c4f6b0dbf12a to your computer and use it in GitHub Desktop.
Save tmcw/7f46b270c4f6b0dbf12a to your computer and use it in GitHub Desktop.
geocode: function(origin, destination) {
this._geocode(origin, L.bind(function(err, originResult) {
if (err) {
return this.fire('error', err);
}
this.fire('origin', {origin: originResult, invisible: true});
this._geocode(destination, L.bind(function(err, destinationResult) {
if (err) return this.fire('error', err);
this.fire('destination', {destination: destinationResult, invisible: true});
}, this));
}, this));
return this;
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment