Skip to content

Commit

Permalink
Release 0.4.2
Browse files Browse the repository at this point in the history
  • Loading branch information
emuvente committed Feb 2, 2016
1 parent 70b0441 commit cf904b7
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "backbone.siren",
"version": "0.4.1",
"version": "0.4.2",
"dependencies": {
"backbone": "~1.1.0",
"jquery": "~2.0.0",
Expand Down
6 changes: 3 additions & 3 deletions dist/amd/backbone.siren.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Backbone.Siren v0.4.1
* Backbone.Siren v0.4.2
*
* Copyright (c) 2016 Kiva Microfunds
* Licensed under the MIT license.
Expand Down Expand Up @@ -1232,8 +1232,8 @@ define(['jquery', 'underscore', 'backbone'], function ($, _, Backbone) {
, getRootForPath: function (path) {
// remove parameters an anchor tags from path
var strippedPath = path.split(/[\?#]/)[0];
// grab the parent path (0 is "", 1 is parent)
var strippedPathParent = '/' + strippedPath.split('/')[1];
// grab the parent path
var strippedPathParent = strippedPath.split('/')[0];
return this.alternateRoots[strippedPath] ? this.alternateRoots[strippedPath] : this.alternateRoots[strippedPathParent] ? this.alternateRoots[strippedPathParent] : this.apiRoot;
}

Expand Down
4 changes: 2 additions & 2 deletions dist/amd/backbone.siren.min.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions dist/iife/backbone.siren.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Backbone.Siren v0.4.1
* Backbone.Siren v0.4.2
*
* Copyright (c) 2016 Kiva Microfunds
* Licensed under the MIT license.
Expand Down Expand Up @@ -1232,8 +1232,8 @@
, getRootForPath: function (path) {
// remove parameters an anchor tags from path
var strippedPath = path.split(/[\?#]/)[0];
// grab the parent path (0 is "", 1 is parent)
var strippedPathParent = '/' + strippedPath.split('/')[1];
// grab the parent path
var strippedPathParent = strippedPath.split('/')[0];
return this.alternateRoots[strippedPath] ? this.alternateRoots[strippedPath] : this.alternateRoots[strippedPathParent] ? this.alternateRoots[strippedPathParent] : this.apiRoot;
}

Expand Down
4 changes: 2 additions & 2 deletions dist/iife/backbone.siren.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "backbone.siren",
"version": "0.4.1",
"version": "0.4.2",
"description": "Converts Siren JSON representations into Backbone Models and Collections",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit cf904b7

Please sign in to comment.