Skip to content

Instantly share code, notes, and snippets.

@gertig
Last active August 29, 2015 13:56
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 gertig/8851148 to your computer and use it in GitHub Desktop.
Save gertig/8851148 to your computer and use it in GitHub Desktop.
App.ApplicationAdapter = DS.RESTAdapter.extend({
host: 'http://hackerbarapp.com',
buildURL: function (type, id) {
var s = this._super("api", id);
console.log("URL: ", s);
return s + "?version=v1&api_key=2659a3fd-2f13-40ed-86ca-b7a40692979c";
},
pathForType: function(type) {
if (type == "api") {
return "api";
}
else {
var camelized = Ember.String.camelize(type);
return Ember.String.pluralize(camelized);
}
},
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment