feat: show admin panel in sidebar for Stalwart admin users

This commit is contained in:
Linus Rath
2026-03-27 01:53:16 +01:00
parent b75d064f20
commit a9002763e2
5 changed files with 135 additions and 34 deletions
+2 -1
View File
@@ -23,7 +23,8 @@ export interface StalwartCredentials {
* (e.g. `https://admin.example.com`).
*/
function getStalwartApiUrl(jmapServerUrl: string): string {
return process.env.STALWART_API_URL || jmapServerUrl;
const url = process.env.STALWART_API_URL || jmapServerUrl;
return url.replace(/\/+$/, '');
}
/**