Chore: Fix various spelling errors in back-end code (#25241)

* Chore: Fix various spelling errors in back-end code
Co-authored-by: Sofia Papagiannaki <papagian@users.noreply.github.com>
Co-authored-by: Josh Soref <jsoref@users.noreply.github.com>>
This commit is contained in:
Arve Knudsen
2020-06-01 17:11:25 +02:00
committed by GitHub
parent 13787294c6
commit 07582a8e85
60 changed files with 174 additions and 168 deletions

View File

@@ -5,7 +5,7 @@ import (
"github.com/grafana/grafana/pkg/models"
)
func (server *HTTPServer) AdminProvisioningReloadDasboards(c *models.ReqContext) Response {
func (server *HTTPServer) AdminProvisioningReloadDashboards(c *models.ReqContext) Response {
err := server.ProvisioningService.ProvisionDashboards()
if err != nil && err != context.Canceled {
return Error(500, "", err)

View File

@@ -403,7 +403,7 @@ func (hs *HTTPServer) registerRoutes() {
adminRoute.Get("/users/:id/auth-tokens", Wrap(hs.AdminGetUserAuthTokens))
adminRoute.Post("/users/:id/revoke-auth-token", bind(models.RevokeAuthTokenCmd{}), Wrap(hs.AdminRevokeUserAuthToken))
adminRoute.Post("/provisioning/dashboards/reload", Wrap(hs.AdminProvisioningReloadDasboards))
adminRoute.Post("/provisioning/dashboards/reload", Wrap(hs.AdminProvisioningReloadDashboards))
adminRoute.Post("/provisioning/datasources/reload", Wrap(hs.AdminProvisioningReloadDatasources))
adminRoute.Post("/provisioning/notifications/reload", Wrap(hs.AdminProvisioningReloadNotifications))
adminRoute.Post("/ldap/reload", Wrap(hs.ReloadLDAPCfg))

View File

@@ -169,7 +169,7 @@ func TestFolderPermissionApiEndpoint(t *testing.T) {
})
})
Convey("When trying to override inherited permissions with lower presedence", func() {
Convey("When trying to override inherited permissions with lower precedence", func() {
origNewGuardian := guardian.New
guardian.MockDashboardGuardian(&guardian.FakeDashboardGuardian{
CanAdminValue: true,

View File

@@ -30,7 +30,7 @@ func (hs *HTTPServer) setIndexViewData(c *models.ReqContext) (*dtos.IndexViewDat
}
prefs := prefsQuery.Result
// Read locale from acccept-language
// Read locale from accept-language
acceptLang := c.Req.Header.Get("Accept-Language")
locale := "en-US"

View File

@@ -309,7 +309,7 @@ func (server *HTTPServer) GetUserFromLDAP(c *models.ReqContext) Response {
err = u.FetchOrgs()
if err != nil {
return Error(http.StatusBadRequest, "An oganization was not found - Please verify your LDAP configuration", err)
return Error(http.StatusBadRequest, "An organization was not found - Please verify your LDAP configuration", err)
}
cmd := &models.GetTeamsForLDAPGroupCommand{Groups: user.Groups}

View File

@@ -146,7 +146,7 @@ func TestGetUserFromLDAPApiEndpoint_OrgNotfound(t *testing.T) {
expected := `
{
"error": "Unable to find organization with ID '2'",
"message": "An oganization was not found - Please verify your LDAP configuration"
"message": "An organization was not found - Please verify your LDAP configuration"
}
`
assert.JSONEq(t, expected, sc.resp.Body.String())