mirror of https://github.com/logseq/logseq
fix(electron): auto updater callback payload error
parent
13beeb4c93
commit
a25bff4d83
|
@ -111,10 +111,11 @@
|
||||||
(emit "completed" nil))))))))
|
(emit "completed" nil))))))))
|
||||||
|
|
||||||
(defn- new-version-downloaded-cb
|
(defn- new-version-downloaded-cb
|
||||||
[_ & args]
|
[_ notes name date url]
|
||||||
(.info logger "[update-downloaded]" args)
|
(.info logger "[update-downloaded]" name notes date url)
|
||||||
(when-let [web-contents (and @*win (. ^js @*win -webContents))]
|
(when-let [web-contents (and @*win (. ^js @*win -webContents))]
|
||||||
(.send web-contents "auto-updater-downloaded" (bean/->js args))))
|
(.send web-contents "auto-updater-downloaded"
|
||||||
|
(bean/->js {:notes notes :name name :date date :url url}))))
|
||||||
|
|
||||||
(defn init-auto-updater
|
(defn init-auto-updater
|
||||||
[repo]
|
[repo]
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
_ (rum/use-effect!
|
_ (rum/use-effect!
|
||||||
(fn []
|
(fn []
|
||||||
(when-let [channel (and (util/electron?) "auto-updater-downloaded")]
|
(when-let [channel (and (util/electron?) "auto-updater-downloaded")]
|
||||||
(let [callback (fn [_ & args]
|
(let [callback (fn [_ args]
|
||||||
(js/console.debug "[new-version downloaded] args:" args)
|
(js/console.debug "[new-version downloaded] args:" args)
|
||||||
(let [args (bean/->clj args)]
|
(let [args (bean/->clj args)]
|
||||||
(set-downloaded args)
|
(set-downloaded args)
|
||||||
|
|
|
@ -44,7 +44,9 @@
|
||||||
|
|
||||||
> p {
|
> p {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: 0 0 6px 0;
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
a {
|
a {
|
||||||
|
@ -53,8 +55,9 @@
|
||||||
|
|
||||||
a.restart {
|
a.restart {
|
||||||
position: relative;
|
position: relative;
|
||||||
top: 3px;
|
|
||||||
cursor: pointer !important;
|
cursor: pointer !important;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
|
||||||
svg {
|
svg {
|
||||||
color: currentColor !important;
|
color: currentColor !important;
|
||||||
|
|
Loading…
Reference in New Issue