From 645b18eb1acf33c9b11723b992b1f62c829574ec Mon Sep 17 00:00:00 2001 From: Johannes Millan Date: Fri, 17 Jan 2025 14:50:59 +0100 Subject: [PATCH] fix: validation msg #3885 --- src/app/features/issue/providers/github/github.const.ts | 4 +--- src/assets/i18n/en.json | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/app/features/issue/providers/github/github.const.ts b/src/app/features/issue/providers/github/github.const.ts index 8b56e4bb3c1..a506909a60b 100644 --- a/src/app/features/issue/providers/github/github.const.ts +++ b/src/app/features/issue/providers/github/github.const.ts @@ -7,7 +7,6 @@ import { } from '../../../config/global-config.model'; import { IssueProviderGithub } from '../../issue.model'; import { ISSUE_PROVIDER_COMMON_FORM_FIELDS } from '../../common-issue-form-stuff.const'; -import { FormlyFieldConfig } from '@ngx-formly/core'; export const DEFAULT_GITHUB_CFG: GithubCfg = { isEnabled: false, @@ -49,8 +48,7 @@ export const GITHUB_CONFIG_FORM: LimitedFormlyFieldConfig[] validators: { token: { expression: (c: { value: string | undefined }) => c.value?.startsWith('ghp_'), - message: (error: any, field: FormlyFieldConfig) => - `${field.formControl?.value} ${T.F.GITHUB.FORM.INVALID_TOKEN_MESSAGE}`, + message: T.F.GITHUB.FORM.INVALID_TOKEN_MESSAGE, }, }, }, diff --git a/src/assets/i18n/en.json b/src/assets/i18n/en.json index 2a5a41b037e..0f83b32e1e8 100644 --- a/src/assets/i18n/en.json +++ b/src/assets/i18n/en.json @@ -228,7 +228,7 @@ "IS_ASSIGNEE_FILTER": "Only import issues assigned to me to backlog", "REPO": "username/repositoryName", "TOKEN": "Access Token", - "INVALID_TOKEN_MESSAGE": "is not a valid GitHub token. It must start with \"ghp_\"." + "INVALID_TOKEN_MESSAGE": "Not a valid GitHub token. It must start with \"ghp_\"." }, "FORM_SECTION": { "HELP": "

Here you can configure SuperProductivity to list open GitHub issues for a specific repository in the task creation panel in the daily planning view. They will be listed as suggestions and will provide a link to the issue as well as more information about it.

In addition you can automatically import all open issues.

To get by usage limits and to access you can provide a an access token. More info about its scopes can be found here.",