mirror of
https://github.com/go-gitea/gitea
synced 2024-12-26 02:24:27 +00:00
Fix lint errors
This commit is contained in:
parent
aa962c6ee9
commit
364838c11b
@ -12,5 +12,6 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func TestMain(m *testing.M) {
|
func TestMain(m *testing.M) {
|
||||||
unittest.MainTest(m, filepath.Join("..", ".."))
|
testOps := unittest.TestOptions{GiteaRootPath: filepath.Join("..", "..")}
|
||||||
|
unittest.MainTest(m, &testOps)
|
||||||
}
|
}
|
||||||
|
@ -76,12 +76,12 @@ func Person(ctx *context.APIContext) {
|
|||||||
publicKeyType.SetW3IDSecurityV1Owner(ownerProp)
|
publicKeyType.SetW3IDSecurityV1Owner(ownerProp)
|
||||||
|
|
||||||
publicKeyPemProp := streams.NewW3IDSecurityV1PublicKeyPemProperty()
|
publicKeyPemProp := streams.NewW3IDSecurityV1PublicKeyPemProperty()
|
||||||
if publicKeyPem, err := activitypub.GetPublicKey(user); err != nil {
|
publicKeyPem, err := activitypub.GetPublicKey(user)
|
||||||
|
if err != nil {
|
||||||
ctx.Error(http.StatusInternalServerError, "GetPublicKey", err)
|
ctx.Error(http.StatusInternalServerError, "GetPublicKey", err)
|
||||||
return
|
return
|
||||||
} else {
|
|
||||||
publicKeyPemProp.Set(publicKeyPem)
|
|
||||||
}
|
}
|
||||||
|
publicKeyPemProp.Set(publicKeyPem)
|
||||||
publicKeyType.SetW3IDSecurityV1PublicKeyPem(publicKeyPemProp)
|
publicKeyType.SetW3IDSecurityV1PublicKeyPem(publicKeyPemProp)
|
||||||
|
|
||||||
publicKeyProp.AppendW3IDSecurityV1PublicKey(publicKeyType)
|
publicKeyProp.AppendW3IDSecurityV1PublicKey(publicKeyType)
|
||||||
|
Loading…
Reference in New Issue
Block a user