Skip to content

Commit

Permalink
Upgrading to v4: Image upload API: max body size,
Browse files Browse the repository at this point in the history
  • Loading branch information
AmirHossein1372 committed Oct 23, 2021
1 parent 0271c66 commit 6da29ed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/App/routes.swift
Expand Up @@ -108,7 +108,7 @@ public func routes(_ app: Application) throws {
tokenProtected.put(uris.gifts_id, use: giftController.update)
tokenProtected.delete(uris.gifts_id, use: giftController.delete)

tokenProtected.post(uris.image_upload, use: imageController.uploadImage)
tokenProtected.on(.POST, uris.image_upload, body: .collect(maxSize: "20mb"), use: imageController.uploadImage)

tokenProtected.post(uris.gifts_userRegistered_id, use: userGifts.registeredGifts)
tokenProtected.post(uris.gifts_userDonated_id, use: userGifts.donatedGifts)
Expand Down

0 comments on commit 6da29ed

Please sign in to comment.