fix error with sending responses

This commit is contained in:
2026-03-10 08:19:07 +01:00
parent 756382a496
commit ecdabab5a1
28 changed files with 1255 additions and 985 deletions

View File

@@ -24,7 +24,7 @@ public class CreateBookEndpoint(BookRepository bookRepository, AuthorRepository
}
await bookRepository.AddAsync(mapper.Map<Book>(req), ct);
await Send.OkAsync(cancellation: ct);
await Send.NoContentAsync(ct);
}
}

View File

@@ -37,6 +37,6 @@ public class DeleteBookEndpoint(BookRepository bookRepository, LoanRepository lo
}
await bookRepository.DeleteAsync(book, ct);
await Send.OkAsync(cancellation: ct);
await Send.NoContentAsync(ct);
}
}

View File

@@ -25,6 +25,6 @@ public class UpdateBookEndpoit(BookRepository bookRepository, AutoMapper.IMapper
mapper.Map(req, book);
await bookRepository.SaveChangesAsync(ct);
await Send.OkAsync(cancellation: ct);
await Send.NoContentAsync(ct);
}
}