Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#564/feat/event handler for csv #581

Merged
merged 12 commits into from
Apr 18, 2024
Prev Previous commit
Next Next commit
Allow get in fetchUtil to return data
akskokki committed Apr 17, 2024
commit d7397e545f2b58b357a85dd1532a04656286843a
4 changes: 1 addition & 3 deletions src/lib/response/fetchUtil.ts
Original file line number Diff line number Diff line change
@@ -5,9 +5,7 @@ import {
} from './responseUtil';

export const get = async (url: RequestInfo | URL) => {
const response = await fetch(url, { method: 'GET' });
const responseAsJson = await responseToJson(response);
return responseAsJson;
return await fetch(url, { method: 'GET' });
};

export const post = async (url: RequestInfo | URL, data?: unknown) => {