refactor: removed unnecessary functions from remark
This commit is contained in:
@@ -13,19 +13,6 @@ export class RemarkService {
|
||||
private readonly taskService: TaskService,
|
||||
) {}
|
||||
|
||||
findAll(): Promise<TMRemark[]> {
|
||||
return this.remarkRepository.find({ relations: { task: true } });
|
||||
}
|
||||
|
||||
findByTask(taskId: string): Promise<TMRemark[]> {
|
||||
return this.remarkRepository.find({
|
||||
where: { taskId },
|
||||
relations: {
|
||||
task: true,
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
async findOneOrFail(id: string): Promise<TMRemark> {
|
||||
const remark = await this.remarkRepository.findOne({ where: { id } });
|
||||
if (!remark) throw new NotFoundException(remarkMessage.REMARK_NOT_FOUND);
|
||||
|
||||
Reference in New Issue
Block a user