Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop' into fabo/56-bind-reque…
Browse files Browse the repository at this point in the history
…sts-to-tabs
  • Loading branch information
faboweb committed Jul 18, 2019
2 parents 5de91b2 + f827180 commit 6479c11
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 10 deletions.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"build": "cross-env NODE_ENV=production webpack --hide-modules",
"build:dev": "cross-env NODE_ENV=development webpack --hide-modules",
"build-zip": "node scripts/build-zip.js",
"initiate-submodule": "git submodule init && git submodule update && cd ./lunie && git checkout develop && yarn install && cd ..",
"initiate-submodule": "git submodule init && git submodule update && cd ./lunie && git checkout develop && cd ..",
"watch": "npm run build -- --watch",
"watch:dev": "cross-env HMR=true npm run build:dev -- --watch",
"test:unit": "jest --coverage ./test/unit/*spec.js ./test/unit/**/*spec.js",
Expand Down Expand Up @@ -54,6 +54,7 @@
"babel-polyfill": "^6.26.0",
"bech32": "^1.1.3",
"bignumber.js": "^9.0.0",
"moment": "^2.24.0",
"perfect-scrollbar": "^1.4.0",
"vue": "^2.6.10",
"vue-clipboard2": "^0.3.0",
Expand Down
1 change: 1 addition & 0 deletions pending/fabo_fix-async-issue
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[Fixed] [#64](https://github.com/cosmos/lunie/issues/64) Fix failures if the popup opens and closes (due to async response handling) @faboweb
11 changes: 6 additions & 5 deletions src/contentScript.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,12 @@ const filterMessages = callback => event => {
// Forward request to backgroud and handle responses to those requests
// on async responses we don't want to wait for a response right away
// waiting causes console errors

// Note: I think we can deal with async stuff by returinig true in the bg script.
// Will test
function executeRequestToExtension({ payload, _skipResponse }) {
chrome.runtime.sendMessage(payload, responseHandler(payload.type))
// Returning true in the extension message handlers doesn't fix the issue!
function executeRequestToExtension({ payload, skipResponse = false }) {
chrome.runtime.sendMessage(
payload,
skipResponse ? undefined : responseHandler(payload.type)
)
}

// Listen to messages from the extension
Expand Down
2 changes: 1 addition & 1 deletion test/e2e/create-account.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ test('Restores an account with backup code when has no accounts', async () => {
"textarea[placeholder='Must be exactly 24 words']",
signupData.seedPhrase
)
await page.click('div.session-footer')
await page.click('div.session-footer button')

const accountRenders = await page.$eval('h3', el => el.textContent)
expect(accountRenders).toEqual(signupData.name)
Expand Down
11 changes: 8 additions & 3 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5764,6 +5764,11 @@ [email protected], "mkdirp@>=0.5 0", mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@~0.5.0:
dependencies:
minimist "0.0.8"

moment@^2.24.0:
version "2.24.0"
resolved "https://registry.yarnpkg.com/moment/-/moment-2.24.0.tgz#0d055d53f5052aa653c9f6eb68bb5d12bf5c2b5b"
integrity sha512-bV7f+6l2QigeBBZSM/6yTNq4P2fNpSWj/0e7jQcy87A8e7o2nAfP/34/2ky5Vw4B9S446EtIhodAzkFCcR4dQg==

move-concurrently@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/move-concurrently/-/move-concurrently-1.0.1.tgz#be2c005fda32e0b29af1f05d7c4b33214c701f92"
Expand Down Expand Up @@ -8725,9 +8730,9 @@ webpack-sources@^1.0.1, webpack-sources@^1.1.0, webpack-sources@^1.3.0:
source-map "~0.6.1"

webpack@^4.20.2:
version "4.36.1"
resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.36.1.tgz#f546fda7a403a76faeaaa7196c50d12370ed18a9"
integrity sha512-Ej01/N9W8DVyhEpeQnbUdGvOECw0L46FxS12cCOs8gSK7bhUlrbHRnWkjiXckGlHjUrmL89kDpTRIkUk6Y+fKg==
version "4.35.3"
resolved "https://registry.yarnpkg.com/webpack/-/webpack-4.35.3.tgz#66bc35ef215a7b75e8790f84d560013ffecf0ca3"
integrity sha512-xggQPwr9ILlXzz61lHzjvgoqGU08v5+Wnut19Uv3GaTtzN4xBTcwnobodrXE142EL1tOiS5WVEButooGzcQzTA==
dependencies:
"@webassemblyjs/ast" "1.8.5"
"@webassemblyjs/helper-module-context" "1.8.5"
Expand Down

0 comments on commit 6479c11

Please sign in to comment.