@defisaver/positions-sdk 2.1.127-uniswap-3-dev → 2.1.128

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -22,7 +22,7 @@ const EMPTY_DATA = (walletAddress) => ({
22
22
  });
23
23
  const fetchUniswapRewardsData = (walletAddress) => __awaiter(void 0, void 0, void 0, function* () {
24
24
  try {
25
- const res = yield fetch(`http://localhost:8888/api/rewards/uniswap?user=${walletAddress}`, { signal: AbortSignal.timeout(5000) });
25
+ const res = yield fetch(`https://fe.defisaver.com/api/rewards/uniswap?user=${walletAddress}`, { signal: AbortSignal.timeout(5000) });
26
26
  if (!res.ok)
27
27
  throw new Error(yield res.text());
28
28
  const data = yield res.json();
@@ -31,7 +31,6 @@ const fetchUniswapRewardsData = (walletAddress) => __awaiter(void 0, void 0, voi
31
31
  return data.data;
32
32
  }
33
33
  catch (err) {
34
- console.error('External API Error: Error fetching Uniswap rewards:', err);
35
34
  return EMPTY_DATA(walletAddress);
36
35
  }
37
36
  });
@@ -16,7 +16,7 @@ const EMPTY_DATA = (walletAddress) => ({
16
16
  });
17
17
  export const fetchUniswapRewardsData = (walletAddress) => __awaiter(void 0, void 0, void 0, function* () {
18
18
  try {
19
- const res = yield fetch(`http://localhost:8888/api/rewards/uniswap?user=${walletAddress}`, { signal: AbortSignal.timeout(5000) });
19
+ const res = yield fetch(`https://fe.defisaver.com/api/rewards/uniswap?user=${walletAddress}`, { signal: AbortSignal.timeout(5000) });
20
20
  if (!res.ok)
21
21
  throw new Error(yield res.text());
22
22
  const data = yield res.json();
@@ -25,7 +25,6 @@ export const fetchUniswapRewardsData = (walletAddress) => __awaiter(void 0, void
25
25
  return data.data;
26
26
  }
27
27
  catch (err) {
28
- console.error('External API Error: Error fetching Uniswap rewards:', err);
29
28
  return EMPTY_DATA(walletAddress);
30
29
  }
31
30
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@defisaver/positions-sdk",
3
- "version": "2.1.127-uniswap-3-dev",
3
+ "version": "2.1.128",
4
4
  "description": "",
5
5
  "main": "./cjs/index.js",
6
6
  "module": "./esm/index.js",
@@ -11,7 +11,7 @@ const EMPTY_DATA = (walletAddress: EthAddress) => ({
11
11
 
12
12
  export const fetchUniswapRewardsData = async (walletAddress: EthAddress) => {
13
13
  try {
14
- const res = await fetch(`http://localhost:8888/api/rewards/uniswap?user=${walletAddress}`,
14
+ const res = await fetch(`https://fe.defisaver.com/api/rewards/uniswap?user=${walletAddress}`,
15
15
  { signal: AbortSignal.timeout(5000) });
16
16
 
17
17
  if (!res.ok) throw new Error(await res.text());
@@ -21,7 +21,6 @@ export const fetchUniswapRewardsData = async (walletAddress: EthAddress) => {
21
21
 
22
22
  return data.data;
23
23
  } catch (err) {
24
- console.error('External API Error: Error fetching Uniswap rewards:', err);
25
24
  return EMPTY_DATA(walletAddress);
26
25
  }
27
26
  };