Skip to content

Commit

Permalink
fix trailing slash
Browse files Browse the repository at this point in the history
  • Loading branch information
rithviknishad committed Sep 28, 2023
1 parent c0a4d38 commit fee12b3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/Redux/api.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -835,11 +835,11 @@ const routes = {
method: "GET",
},
getAssetService: {
path: "/api/v1/asset/{asset_external_id}/service_records/{external_id}",
path: "/api/v1/asset/{asset_external_id}/service_records/{external_id}/",
method: "GET",
},
updateAssetService: {
path: "/api/v1/asset/{asset_external_id}/service_records/{external_id}",
path: "/api/v1/asset/{asset_external_id}/service_records/{external_id}/",
method: "PUT",
},

Expand Down
4 changes: 2 additions & 2 deletions src/Redux/fireRequest.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ export const fireRequest = (
const request = Object.assign({}, (routes as any)[key]);

if (path.length > 0) {
request.path += path.join("/");
request.path += path.join("/") + "/";
}

if (request.method === undefined || request.method === "GET") {
Expand Down Expand Up @@ -193,7 +193,7 @@ export const legacyFireRequest = (
const request = Object.assign({}, (routes as any)[key]);

if (path.length > 0) {
request.path += path.join("/");
request.path += path.join("/") + "/";
}

if (request.method === undefined || request.method === "GET") {
Expand Down

0 comments on commit fee12b3

Please sign in to comment.