* Add new error message

* make i18n-extract

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
Co-authored-by: Harrison Healey <harrisonmhealey@gmail.com>
Этот коммит содержится в:
MeHow25
2024-05-13 21:55:12 +02:00
коммит произвёл GitHub
родитель 664e2ae782
Коммит 298fd6e839
3 изменённых файлов: 7 добавлений и 1 удалений

Просмотреть файл

@@ -48,7 +48,7 @@ func TestCreateTeam(t *testing.T) {
rteam.Id = ""
_, resp, err = client.CreateTeam(context.Background(), rteam)
CheckErrorID(t, err, "app.team.save.existing.app_error")
CheckErrorID(t, err, "store.sql_team.save_team.existing.app_error")
CheckBadRequestStatus(t, resp)
rteam.Name = ""

Просмотреть файл

@@ -120,6 +120,8 @@ func (a *App) CreateTeam(c request.CTX, team *model.Team) (*model.Team, *model.A
return nil, model.NewAppError("CreateTeam", "store.sql_channel.save.direct_channel.app_error", nil, "", http.StatusBadRequest).Wrap(err)
case invErr.Entity == "Channel" && invErr.Field == "Id":
return nil, model.NewAppError("CreateTeam", "store.sql_channel.save_channel.existing.app_error", nil, "id="+invErr.Value.(string), http.StatusBadRequest).Wrap(err)
case invErr.Entity == "Team" && invErr.Field == "id":
return nil, model.NewAppError("CreateTeam", "store.sql_team.save_team.existing.app_error", nil, "id="+invErr.Value.(string), http.StatusBadRequest).Wrap(err)
default:
return nil, model.NewAppError("CreateTeam", "app.team.save.existing.app_error", nil, "", http.StatusBadRequest).Wrap(err)
}

Просмотреть файл

@@ -9874,6 +9874,10 @@
"id": "store.sql_team.save_member.exists.app_error",
"translation": "A team member with that ID already exists."
},
{
"id": "store.sql_team.save_team.existing.app_error",
"translation": "A team with this URL already exists."
},
{
"id": "store.sql_user.get_for_login.app_error",
"translation": "Unable to find an existing account matching your credentials. This team may require an invite from the team owner to join."