Skip to content

Commit

Permalink
Merge branch 'master' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
NguyenBao10 authored Mar 28, 2024
2 parents 05434d5 + 40d8d84 commit a29553f
Show file tree
Hide file tree
Showing 4 changed files with 246 additions and 115 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}

Expand All @@ -40,7 +40,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2
uses: github/codeql-action/autobuild@v3

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v3
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"i18next": "^23.6.0",
"i18next-browser-languagedetector": "^7.1.0",
"murmurhash-js": "^1.0.0",
"next": "^13.5.4",
"next": "^14.1.0",
"query-string": "^7.1.1",
"react": "^18.2.0",
"react-bootstrap": "^2.8.0",
Expand Down Expand Up @@ -76,7 +76,7 @@
"@walletconnect/types": "^2.10.0",
"dotenv": "^16.0.3",
"esbuild-plugin-inline-image": "^0.0.9",
"esbuild-sass-plugin": "^2.15.0",
"esbuild-sass-plugin": "^3.0.0",
"esbuild-scss-modules-plugin": "^1.1.1",
"eslint": "^8.48.0",
"eslint-plugin-react": "^7.33.2",
Expand Down
12 changes: 10 additions & 2 deletions src/Hooks/useConsentStatus.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,12 +122,19 @@ const useConsentStatus = (endpoint?: string, props?: WalletConnectionProps) => {
sessionStorage.getItem('aesirx-analytics-revoke') !== '1' &&
sessionStorage.getItem('aesirx-analytics-revoke') !== '2'
) {
window.addEventListener('load', async function () {
if (window['concordium']) {
const address = (await window['concordium']?.requestAccounts()) ?? [];
if (window['concordium'] && address?.length) {
setActiveConnectorType(BROWSER_WALLET);
}
});
} else {
window.addEventListener('load', async function () {
const address = (await window['concordium']?.requestAccounts()) ?? [];
if (window['concordium'] && address?.length) {
setActiveConnectorType(BROWSER_WALLET);
}
});
}
}
};
initConnector();
Expand Down Expand Up @@ -159,6 +166,7 @@ const useConsentStatus = (endpoint?: string, props?: WalletConnectionProps) => {
setLevel(null);
l = 3;
let web3ID = false;
console.log('test', account);
if (account && sessionStorage.getItem('aesirx-analytics-consent-type') !== 'metamask') {
web3ID = await getWeb3ID(account, rpc, network?.name);
if (web3ID === true) {
Expand Down
Loading

0 comments on commit a29553f

Please sign in to comment.