Remove url interpolation from tutorial app
This commit is contained in:
parent
34d6a710a9
commit
5e654452e1
1 changed files with 3 additions and 5 deletions
|
|
@ -392,8 +392,7 @@ var User = {
|
||||||
load: function(id) {
|
load: function(id) {
|
||||||
return m.request({
|
return m.request({
|
||||||
method: "GET",
|
method: "GET",
|
||||||
url: "https://rem-rest-api.herokuapp.com/api/users/:id",
|
url: "https://rem-rest-api.herokuapp.com/api/users/" + id,
|
||||||
data: {id: id},
|
|
||||||
withCredentials: true,
|
withCredentials: true,
|
||||||
})
|
})
|
||||||
.then(function(result) {
|
.then(function(result) {
|
||||||
|
|
@ -508,8 +507,7 @@ var User = {
|
||||||
load: function(id) {
|
load: function(id) {
|
||||||
return m.request({
|
return m.request({
|
||||||
method: "GET",
|
method: "GET",
|
||||||
url: "https://rem-rest-api.herokuapp.com/api/users/:id",
|
url: "https://rem-rest-api.herokuapp.com/api/users/" + id,
|
||||||
data: {id: id},
|
|
||||||
withCredentials: true,
|
withCredentials: true,
|
||||||
})
|
})
|
||||||
.then(function(result) {
|
.then(function(result) {
|
||||||
|
|
@ -520,7 +518,7 @@ var User = {
|
||||||
save: function() {
|
save: function() {
|
||||||
return m.request({
|
return m.request({
|
||||||
method: "PUT",
|
method: "PUT",
|
||||||
url: "https://rem-rest-api.herokuapp.com/api/users/:id",
|
url: "https://rem-rest-api.herokuapp.com/api/users/" + User.current.id,
|
||||||
data: User.current,
|
data: User.current,
|
||||||
withCredentials: true,
|
withCredentials: true,
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue