mirror of
https://github.com/mjl-/mox.git
synced 2025-07-19 03:26:37 +03:00
web interfaces: don't include version number in html, only return it after authentication
second round for issue #322
This commit is contained in:
@ -18,6 +18,7 @@ import (
|
||||
"net/textproto"
|
||||
"os"
|
||||
"regexp"
|
||||
"runtime"
|
||||
"runtime/debug"
|
||||
"slices"
|
||||
"sort"
|
||||
@ -130,6 +131,11 @@ func (w Webmail) Logout(ctx context.Context) {
|
||||
xcheckf(ctx, err, "logout")
|
||||
}
|
||||
|
||||
// Version returns the version, goos and goarch.
|
||||
func (w Webmail) Version(ctx context.Context) (version, goos, goarch string) {
|
||||
return moxvar.Version, runtime.GOOS, runtime.GOARCH
|
||||
}
|
||||
|
||||
// Token returns a single-use token to use for an SSE connection. A token can only
|
||||
// be used for a single SSE connection. Tokens are stored in memory for a maximum
|
||||
// of 1 minute, with at most 10 unused tokens (the most recently created) per
|
||||
|
Reference in New Issue
Block a user