mirror of
https://github.com/freedbygrace/DynamoDNS.git
synced 2026-08-27 18:57:28 +00:00
Fix API token truncation in response
Replit-Commit-Author: Agent Replit-Commit-Session-Id: 9111ef36-26c8-4085-84ca-a35dc1fec1b5 Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/7083d608-d6d3-4a6a-9a27-6286c5109627/2bbe1ea8-d1a5-409a-a278-9a936411501f.jpg
This commit is contained in:
+2
-7
@@ -953,13 +953,8 @@ export async function registerRoutes(app: Express): Promise<Server> {
|
|||||||
: [];
|
: [];
|
||||||
}
|
}
|
||||||
|
|
||||||
// Mask token values
|
// Return full tokens (client will handle masking for display)
|
||||||
const maskedTokens = tokens.map(token => ({
|
res.json(tokens);
|
||||||
...token,
|
|
||||||
token: token.token.substring(0, 8) + '...'
|
|
||||||
}));
|
|
||||||
|
|
||||||
res.json(maskedTokens);
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error("Error fetching API tokens:", error);
|
console.error("Error fetching API tokens:", error);
|
||||||
res.status(500).json({ message: "Internal server error" });
|
res.status(500).json({ message: "Internal server error" });
|
||||||
|
|||||||
Reference in New Issue
Block a user