Skip to content

Commit

Permalink
remove unnecessary withCredentials
Browse files Browse the repository at this point in the history
- withCredentials is not part of the fetch api and was just being ignored
  • Loading branch information
jaredgalanis committed Jul 5, 2024
1 parent 09403e0 commit 89a1d99
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 4 deletions.
1 change: 0 additions & 1 deletion app/adapters/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ export default class ApplicationAdapter extends JSONAPIAdapter {

get headers() {
return {
withCredentials: true,
'X-XSRF-TOKEN': document.cookie.match(/XSRF-TOKEN\=([^;]*)/)['1'],
};
}
Expand Down
1 change: 0 additions & 1 deletion app/components/workflow-files/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,6 @@ export default class WorkflowFiles extends Component {
async uploadFile(FileUpload) {
try {
const response = await FileUpload.upload(ENV.fileServicePath, {
withCredentials: true,
headers: {
'X-XSRF-TOKEN': document.cookie.match(/XSRF-TOKEN\=([^;]*)/)['1'],
},
Expand Down
1 change: 0 additions & 1 deletion app/services/doi.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ export default class DoiService extends Service {
let rawResponse = yield fetch(url, {
headers: {
Accept: 'application/json; charset=utf-8',
withCredentials: 'include',
'X-XSRF-TOKEN': document.cookie.match(/XSRF-TOKEN\=([^;]*)/)['1'],
},
});
Expand Down
1 change: 0 additions & 1 deletion app/services/oa-manuscript-service.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ export default class OAManuscriptService extends Service {
method: 'GET',
headers: {
Accept: 'application/json; charset=utf-8',
withCredentials: 'include',
'X-XSRF-TOKEN': document.cookie.match(/XSRF-TOKEN\=([^;]*)/)['1'],
},
})
Expand Down

0 comments on commit 89a1d99

Please sign in to comment.