From a15decb6f74b7ff809c2693417b2743336624525 Mon Sep 17 00:00:00 2001 From: William Mantly Date: Tue, 28 Jul 2026 21:19:28 -0400 Subject: [PATCH] Fix API-token reveal modal silently not showing after create app.modal.close() called immediately before showToken()'s app.modal.open() in the same tick collides with Bootstrap's hide-transition guard on the singleton modal, so the reveal never appears. open() alone already overwrites the already-visible modal's content in place. Same root cause as the OAuth-secret-reveal race fixed in sso-manager-node (v1.8.2) and the create-token race fixed in proxy (v1.7.0), found while auditing this exact pattern across all 3 apps this round. --- nodejs/views/dashboard.ejs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/nodejs/views/dashboard.ejs b/nodejs/views/dashboard.ejs index 271d89d..ad81ae6 100644 --- a/nodejs/views/dashboard.ejs +++ b/nodejs/views/dashboard.ejs @@ -231,7 +231,12 @@ expires_in_days: $('#new-token-days').val(), }, function(error, data){ if(error) return app.messages.action((data && data.message) || 'Failed to create token', app.modal.body(), 'danger'); - app.modal.close(); + // Deliberately no app.modal.close() here -- app.modal is a + // singleton, and close() immediately followed by open() (inside + // showToken) in the same tick collides with Bootstrap's + // hide-transition guard, so the reveal modal silently never + // shows. open() alone already overwrites the (already-visible) + // modal's content in place. showToken('API Token Created', data.token); loadApiTokens(); });