Browse Source

Rename Options to ProjectFields

pull/2093/head
Hironsan 1 year ago
parent
commit
4a33e90bcf
1 changed files with 3 additions and 4 deletions
  1. 7
      frontend/services/application/project/projectApplicationService.ts

7
frontend/services/application/project/projectApplicationService.ts

@ -3,7 +3,7 @@ import { Project } from '~/domain/models/project/project'
import { TagItem } from '~/domain/models/tag/tag'
import { APIProjectRepository, SearchQuery } from '~/repositories/project/apiProjectRepository'
type Options = {
type ProjectFields = {
name: string
description: string
guideline: string
@ -53,7 +53,7 @@ export class ProjectApplicationService {
useRelation,
tags,
guideline = ''
}: Options): Promise<Project> {
}: ProjectFields): Promise<Project> {
const project = Project.create(
0,
name,
@ -88,7 +88,7 @@ export class ProjectApplicationService {
enableGraphemeMode,
useRelation,
guideline = ''
}: Omit<Options, 'tags'>
}: Omit<ProjectFields, 'tags'>
): Promise<void> {
const project = Project.create(
projectId,
@ -106,7 +106,6 @@ export class ProjectApplicationService {
)
try {
// item.tags = [] // TODO: somewhat hacky
await this.repository.update(project)
} catch (e: any) {
throw new Error(e.response.data.detail)

Loading…
Cancel
Save