[golangci-lint]: regexp: Simplify code.

This commit is contained in:
Martin Dosch 2023-06-04 16:00:16 +02:00
parent 94e82bdef5
commit fd3d9f0d9f
No known key found for this signature in database
GPG Key ID: 52A57CFCE13D657D

4
ox.go
View File

@ -341,7 +341,7 @@ func oxGetPrivKeyLoc(jid string) (string, error) {
}
dataDir = homeDir + "/.local/share"
}
dataDir = dataDir + "/go-sendxmpp/oxprivkeys/"
dataDir += "/go-sendxmpp/oxprivkeys/"
if _, err = os.Stat(dataDir); os.IsNotExist(err) {
err = os.MkdirAll(dataDir, 0700)
if err != nil {
@ -374,7 +374,7 @@ func oxGetPubKeyLoc(fingerprint string) (string, error) {
}
dataDir = homeDir + "/.local/share"
}
dataDir = dataDir + "/go-sendxmpp/oxpubkeys/"
dataDir += "/go-sendxmpp/oxpubkeys/"
if _, err = os.Stat(dataDir); os.IsNotExist(err) {
err = os.MkdirAll(dataDir, 0700)
if err != nil {