feat: Moves database dependency directory.

This commit is contained in:
2025-01-11 00:26:08 -05:00
parent 9994644d21
commit 0e31d2c30c
11 changed files with 20 additions and 18 deletions

View File

@@ -24,9 +24,7 @@ struct VendorApiController: RouteCollection {
@Sendable
func create(req: Request) async throws -> Vendor.DTO {
try Vendor.Create.validate(content: req)
let model = try req.content.decode(Vendor.Create.self)
return try await vendors.create(model)
try await vendors.create(req.ensureValidContent(Vendor.Create.self))
}
@Sendable