diff --git a/dist/assets/index-VxL4q8Bc.js b/dist/assets/index-V04a1n39.js similarity index 99% rename from dist/assets/index-VxL4q8Bc.js rename to dist/assets/index-V04a1n39.js index 37823b4..0b0df1c 100644 --- a/dist/assets/index-VxL4q8Bc.js +++ b/dist/assets/index-V04a1n39.js @@ -1539,8 +1539,8 @@ $(el.threadSyncBtn).on("click", async () => { if (remoteMap[t.id] && remoteMap[t.id].name !== newName) { await ghApi(`${info.apiPath}/${remoteMap[t.id].name}`, "DELETE", { message: `Rename thread ${t.id}`, sha: remoteMap[t.id].sha, branch: info.branch }); } - const ex = await ghApi(`${info.apiPath}/${newName}?ref=${info.branch}`); - await ghApi(`${info.apiPath}/${newName}`, "PUT", { message: `Sync thread ${t.id}`, content: utob(JSON.stringify(msgs, null, 2)), branch: info.branch, sha: ex?.sha }); + const x = await ghApi(`${info.apiPath}/${newName}?ref=${info.branch}`); + await ghApi(`${info.apiPath}/${newName}`, "PUT", { message: `Sync thread ${t.id}`, content: utob(JSON.stringify(msgs, null, 2)), branch: info.branch, sha: x?.sha }); t.status = "synced"; } } @@ -1606,7 +1606,7 @@ $(el.accountSettingsOption).on("click", () => { $(el.closeAccountSettings).on("click", closeAccountSettings); $(el.cancelAccountSettings).on("click", closeAccountSettings); $(el.accountSettingsModal).on("click", (e) => { - if (e.target === el.accountSettingsModal || e.target.classList.contains("bg-black/30")) closeSettings(); + if (e.target === el.accountSettingsModal || e.target.classList.contains("bg-black/30")) closeAccountSettings(); }); $(el.accountSettingsForm).on("submit", (e) => { e.preventDefault(); diff --git a/dist/index.html b/dist/index.html index 1a3f2dd..51400b7 100644 --- a/dist/index.html +++ b/dist/index.html @@ -15,7 +15,7 @@ - + diff --git a/dist/sw.js b/dist/sw.js index 3e16dc8..4efbfb7 100644 --- a/dist/sw.js +++ b/dist/sw.js @@ -1 +1 @@ -if(!self.define){let e,s={};const i=(i,n)=>(i=new URL(i+".js",n).href,s[i]||new Promise(s=>{if("document"in self){const e=document.createElement("script");e.src=i,e.onload=s,document.head.appendChild(e)}else e=i,importScripts(i),s()}).then(()=>{let e=s[i];if(!e)throw new Error(`Module ${i} didn’t register its module`);return e}));self.define=(n,r)=>{const t=e||("document"in self?document.currentScript.src:"")||location.href;if(s[t])return;let o={};const c=e=>i(e,t),d={module:{uri:t},exports:o,require:c};s[t]=Promise.all(n.map(e=>d[e]||c(e))).then(e=>(r(...e),o))}}define(["./workbox-8c29f6e4"],function(e){"use strict";self.skipWaiting(),e.clientsClaim(),e.precacheAndRoute([{url:"registerSW.js",revision:"1872c500de691dce40960bb85481de07"},{url:"index.html",revision:"c09dc86a60de6d473e79de3cf83c25ba"},{url:"assets/index-VxL4q8Bc.js",revision:null},{url:"assets/index-JLEDB1oP.css",revision:null},{url:"manifest.webmanifest",revision:"7a6c5c6ab9cb5d3605d21df44c6b17a2"}],{}),e.cleanupOutdatedCaches(),e.registerRoute(new e.NavigationRoute(e.createHandlerBoundToURL("index.html")))}); +if(!self.define){let e,s={};const i=(i,n)=>(i=new URL(i+".js",n).href,s[i]||new Promise(s=>{if("document"in self){const e=document.createElement("script");e.src=i,e.onload=s,document.head.appendChild(e)}else e=i,importScripts(i),s()}).then(()=>{let e=s[i];if(!e)throw new Error(`Module ${i} didn’t register its module`);return e}));self.define=(n,r)=>{const t=e||("document"in self?document.currentScript.src:"")||location.href;if(s[t])return;let o={};const c=e=>i(e,t),d={module:{uri:t},exports:o,require:c};s[t]=Promise.all(n.map(e=>d[e]||c(e))).then(e=>(r(...e),o))}}define(["./workbox-8c29f6e4"],function(e){"use strict";self.skipWaiting(),e.clientsClaim(),e.precacheAndRoute([{url:"registerSW.js",revision:"1872c500de691dce40960bb85481de07"},{url:"index.html",revision:"bbc38d08efe99c1646103184d9d92649"},{url:"assets/index-V04a1n39.js",revision:null},{url:"assets/index-JLEDB1oP.css",revision:null},{url:"manifest.webmanifest",revision:"7a6c5c6ab9cb5d3605d21df44c6b17a2"}],{}),e.cleanupOutdatedCaches(),e.registerRoute(new e.NavigationRoute(e.createHandlerBoundToURL("index.html")))});