Skip to content

Commit

Permalink
Remove reference to port 3001 on localhost in custom extension
Browse files Browse the repository at this point in the history
  • Loading branch information
pbochynski committed Jan 8, 2025
1 parent b4819a3 commit 2606242
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions examples/custom-extension/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@ function fetchWrapper(url, options = {}) {
}

function proxyFetch(url, options = {}) {
const baseUrl = window.location.hostname.startsWith('localhost')
? 'http://localhost:3001/proxy'
: '/proxy';
const baseUrl = '/proxy';
const encodedUrl = encodeURIComponent(url);
const proxyUrl = `${baseUrl}?url=${encodedUrl}`;
return fetch(proxyUrl, options);
Expand Down

0 comments on commit 2606242

Please sign in to comment.