Skip to content

Commit

Permalink
Cleanup unnecessary stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
MareStare committed Feb 25, 2025
1 parent e1f2129 commit 325056a
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
7 changes: 0 additions & 7 deletions assets/js/utils/http-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ export class HttpClient {
throw new Error('Manually defined "Accept" header is not allowed in "fetchJson"');
}

// TODO: figure out how to enable `Accept: application/json` plug in
// the routes on backend.
// (params.headers ??= {}).Accept = 'application/json';

const response = await this.fetch(path, params);
return response.json();
}
Expand All @@ -55,9 +51,6 @@ export class HttpClient {
params.headers!['X-Request-Id'] = generateId('req-');
params.headers!['X-Retry-Attempt'] = String(attempt);

// TODO: we should respect the `Retry-After` header from the response,
// to allow for granular rerty control from the backend side.
// https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Retry-After
const response = await fetch(url, params);

if (!response.ok) {
Expand Down
1 change: 1 addition & 0 deletions lib/philomena_web/router.ex
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
defmodule PhilomenaWeb.Router do
alias IEx.Autocomplete
use PhilomenaWeb, :router

import PhilomenaWeb.UserAuth
Expand Down

0 comments on commit 325056a

Please sign in to comment.