fix bug with adding labels

This commit is contained in:
Simon Larsen 2023-01-13 11:44:38 +00:00
parent e3479fc0fa
commit a242d8ba17

View File

@ -4,7 +4,6 @@ import DatabaseService, { OnCreate } from './DatabaseService';
import CreateBy from '../Types/Database/CreateBy';
import QueryHelper from '../Types/Database/QueryHelper';
import BadDataException from 'Common/Types/Exception/BadDataException';
import ObjectID from 'Common/Types/ObjectID';
export class Service extends DatabaseService<Model> {
public constructor(postgresDatabase?: PostgresDatabase) {
@ -19,12 +18,6 @@ export class Service extends DatabaseService<Model> {
existingProjectWithSameNameCount = (
await this.countBy({
query: {
_id:
createBy.props.userGlobalAccessPermission?.projectIds.map(
(item: ObjectID) => {
return item.toString();
}
) || [],
name: QueryHelper.findWithSameText(createBy.data.name!),
projectId: createBy.props.tenantId!,
},