UserDisplay: Handle both service accounts and user names when resolving "createdBy" (#98719)

* Handle both user and service accounts when resolving identity name for dashboards and folders

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
This commit is contained in:
Karl Persson
2025-01-10 10:06:59 +01:00
committed by GitHub
co-authored by Misi
parent 557820df56
commit bdb4725768
4 changed files with 34 additions and 21 deletions
+1 -1
View File
@@ -742,7 +742,7 @@ func TestDashboardVersionsAPIEndpoint(t *testing.T) {
},
}
getHS(&usertest.FakeUserService{
ExpectedUser: &user.User{ID: 1, Login: "test-user"},
ExpectedSignedInUser: &user.SignedInUser{Login: "test-user"},
}).callGetDashboardVersions(sc)
assert.Equal(t, http.StatusOK, sc.resp.Code)