← back to Wallco Ai
/design/:id admin toolbar: 'Sell on Etsy' button — (1) absolute-URL fetch so Basic-Auth credentials in the page URL don't break Request construction; (2) live elapsed-time progress during the 30-60s seam scan; (3) on gate-fail surfaces scores + an amber 'Sell anyway →' button that POSTs {force:true} to bypass — same pattern as the publish gate-held toast. Also fixed atb-fix (smart-fix) to use absolute URL for the same reason
d9d340ab05bea265d1e915d14e4ed39144ba215f · 2026-05-28 10:58:19 -0700 · Steve Abrams
Files touched
Diff
commit d9d340ab05bea265d1e915d14e4ed39144ba215f
Author: Steve Abrams <steve@designerwallcoverings.com>
Date: Thu May 28 10:58:19 2026 -0700
/design/:id admin toolbar: 'Sell on Etsy' button — (1) absolute-URL fetch so Basic-Auth credentials in the page URL don't break Request construction; (2) live elapsed-time progress during the 30-60s seam scan; (3) on gate-fail surfaces scores + an amber 'Sell anyway →' button that POSTs {force:true} to bypass — same pattern as the publish gate-held toast. Also fixed atb-fix (smart-fix) to use absolute URL for the same reason
---
server.js | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/server.js b/server.js
index 1cc6d8e..1fe23e1 100644
--- a/server.js
+++ b/server.js
@@ -10796,7 +10796,9 @@ try {
onClick('atb-fix', async function(b){
if (!confirm('Run smart-fix on #' + b.dataset.id + '? Generates a corrected child design — original stays put.')) return;
setStatus('Smart-fix running… (~30–60s)');
- var r = await fetch('/api/design/' + b.dataset.id + '/smart-fix', { method:'POST', headers:{'Content-Type':'application/json'}, body: '{}' });
+ // Absolute URL — same Basic-Auth-credential-scrub the unpublish handler uses.
+ var _o = location.protocol + '//' + location.host;
+ var r = await fetch(_o + '/api/design/' + b.dataset.id + '/smart-fix', { method:'POST', credentials:'include', headers:{'Content-Type':'application/json'}, body: '{}' });
var j = await r.json();
if (r.ok && j.ok) setStatus('✓ smart-fix → #' + (j.new_id || j.id || '?') + (j.kind ? ' (' + j.kind + ')' : ''), 'ok');
else setStatus('smart-fix failed: ' + (j.error || j.reason || r.status), 'err');
← b471c32 wall-room-viewer: add Wall HEIGHT slider matching the Wall W
·
back to Wallco Ai
·
/design/:id 'Sell on Etsy' button — go one-click force-add b f538318 →