@gnosis.pm/safe-apps-react-sdk
Advanced tools
Comparing version 2.3.0 to 2.3.1
@@ -26,5 +26,9 @@ "use strict"; | ||
react_1.useEffect(() => { | ||
let active = true; | ||
const fetchSafeInfo = () => __awaiter(void 0, void 0, void 0, function* () { | ||
try { | ||
const safeInfo = yield sdk.getSafeInfo(); | ||
if (!active) { | ||
return; | ||
} | ||
setSafe(safeInfo); | ||
@@ -34,2 +38,5 @@ setConnected(true); | ||
catch (err) { | ||
if (!active) { | ||
return; | ||
} | ||
setConnected(false); | ||
@@ -39,2 +46,5 @@ } | ||
fetchSafeInfo(); | ||
return () => { | ||
active = false; | ||
}; | ||
}, [sdk]); | ||
@@ -41,0 +51,0 @@ if (!connected && loader) { |
{ | ||
"name": "@gnosis.pm/safe-apps-react-sdk", | ||
"private": false, | ||
"version": "2.3.0", | ||
"version": "2.3.1", | ||
"main": "dist/index.js", | ||
@@ -14,4 +14,3 @@ "types": "dist/index.d.ts", | ||
"dependencies": { | ||
"@gnosis.pm/safe-apps-sdk": "2.3.0", | ||
"@types/jest": "^26.0.22" | ||
"@gnosis.pm/safe-apps-sdk": "2.3.0" | ||
}, | ||
@@ -25,8 +24,9 @@ "peerDependencies": { | ||
"devDependencies": { | ||
"@types/jest": "^26.0.23", | ||
"@types/react-dom": "^17.0.2", | ||
"eslint-config-react-app": "^6.0.0", | ||
"eslint-plugin-flowtype": "^5.3.1", | ||
"eslint-plugin-flowtype": "^5.7.2", | ||
"eslint-plugin-import": "^2.22.0", | ||
"eslint-plugin-jsx-a11y": "^6.3.1", | ||
"eslint-plugin-react": "^7.23.1", | ||
"eslint-plugin-react": "^7.23.2", | ||
"eslint-plugin-react-hooks": "^4.2.0", | ||
@@ -33,0 +33,0 @@ "rimraf": "^3.0.2" |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8213
5
88
9
- Removed@types/jest@^26.0.22
- Removed@jest/types@26.6.2(transitive)
- Removed@types/istanbul-lib-coverage@2.0.6(transitive)
- Removed@types/istanbul-lib-report@3.0.3(transitive)
- Removed@types/istanbul-reports@3.0.4(transitive)
- Removed@types/jest@26.0.24(transitive)
- Removed@types/yargs@15.0.19(transitive)
- Removed@types/yargs-parser@21.0.3(transitive)
- Removedansi-regex@5.0.1(transitive)
- Removedansi-styles@4.3.0(transitive)
- Removedchalk@4.1.2(transitive)
- Removedcolor-convert@2.0.1(transitive)
- Removedcolor-name@1.1.4(transitive)
- Removeddiff-sequences@26.6.2(transitive)
- Removedhas-flag@4.0.0(transitive)
- Removedjest-diff@26.6.2(transitive)
- Removedjest-get-type@26.3.0(transitive)
- Removedpretty-format@26.6.2(transitive)
- Removedreact-is@17.0.2(transitive)
- Removedsupports-color@7.2.0(transitive)