Merge branch 'data-layer-rewrite' of https://github.com/rowyio/rowy into data-layer-rewrite

This commit is contained in:
Sidney Alcantara
2022-05-30 11:59:17 +10:00

View File

@@ -93,7 +93,6 @@ export const rowyRunAtom = atom((get) => {
const { method, path } = route;
let url = serviceUrl + path;
if (params && params.length > 0) url = url + "/" + params.join("/");
const response = await fetch(url, {
method: method,
mode: "cors",
@@ -101,7 +100,7 @@ export const rowyRunAtom = atom((get) => {
credentials: "same-origin",
headers: {
"Content-Type": "application/json",
Authorization: "Bearer " + authToken,
Authorization: "Bearer " + authToken.token,
},
redirect: "follow",
referrerPolicy: "no-referrer",