Skip to content

Commit 4c5c02d

Browse files
authored
fix(mac): refresh file list after import (#1767)
Closes #1763
1 parent 81e648d commit 4c5c02d

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/add-to-ipfs.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ async function makeShareableObject (ipfs, results) {
4545
return { cid: baseCID, path: '' }
4646
}
4747

48-
function sendNotification (failures, successes, launch, path) {
48+
function sendNotification (failures, successes, launchWebUI, path) {
4949
let link, title, body, fn
5050

5151
if (failures.length === 0) {
@@ -69,7 +69,7 @@ function sendNotification (failures, successes, launch, path) {
6969
}
7070

7171
fn({ title, body }, () => {
72-
launch(link)
72+
launchWebUI(link, { forceRefresh: true })
7373
})
7474
}
7575

src/webui/index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,8 @@ module.exports = async function (ctx) {
101101
url.hash = '/blank'
102102
url.searchParams.set('deviceId', ctx.countlyDeviceId)
103103

104-
ctx.launchWebUI = (path, { focus = true } = {}) => {
104+
ctx.launchWebUI = (path, { focus = true, forceRefresh = false } = {}) => {
105+
if (forceRefresh) window.webContents.reload()
105106
if (!path) {
106107
logger.info('[web ui] launching web ui')
107108
} else {

0 commit comments

Comments
 (0)