Update user friendly errors for translations (#15000)

Force msg typing instead of string for user friendly errors
This commit is contained in:
Félix Malfait
2025-10-09 18:17:32 +02:00
committed by GitHub
parent 660cd38f35
commit e577c2d746
124 changed files with 796 additions and 563 deletions
@@ -1,6 +1,7 @@
import { Injectable } from '@nestjs/common';
import { InjectDataSource } from '@nestjs/typeorm';
import { msg } from '@lingui/core/macro';
import { type DataSource, type EntityManager } from 'typeorm';
import { DataSourceService } from 'src/engine/metadata-modules/data-source/data-source.service';
@@ -75,8 +76,7 @@ export class WorkspaceDataSourceService {
'Method not allowed as permissions are not handled at datasource level.',
PermissionsExceptionCode.METHOD_NOT_ALLOWED,
{
userFriendlyMessage:
'This operation is not allowed. Please try a different approach or contact support if you need assistance.',
userFriendlyMessage: msg`This operation is not allowed. Please try a different approach or contact support if you need assistance.`,
},
);
}