Skip to content

Commit

Permalink
Remove legacy addToBody and callback API (#465)
Browse files Browse the repository at this point in the history
* remove deprecated method

* remove unused package

* revert modification

* remove addToBody documentation

* remove request.multipart type

* remove legacy comment
  • Loading branch information
gurgunday authored Sep 1, 2023
1 parent b1989fa commit 1d824e3
Show file tree
Hide file tree
Showing 11 changed files with 1 addition and 1,950 deletions.
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ npm i @fastify/multipart

## Usage

If you are looking for the documentation for the legacy callback-api please see [here](./callback.md).

```js
const fastify = require('fastify')()
const fs = require('fs')
Expand Down
194 changes: 0 additions & 194 deletions callback.md

This file was deleted.

30 changes: 0 additions & 30 deletions examples/example-legacy-validation.js

This file was deleted.

37 changes: 0 additions & 37 deletions examples/example-legacy.js

This file was deleted.

12 changes: 0 additions & 12 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,6 @@ declare module "fastify" {
options?: Omit<BusboyConfig, "headers">
) => AsyncIterableIterator<fastifyMultipart.Multipart>;

// legacy
multipart: (
handler: MultipartHandler,
next: (err: Error) => void,
options?: Omit<BusboyConfig, "headers">
) => Busboy;

// Stream mode
file: (
options?: Omit<BusboyConfig, "headers">
Expand Down Expand Up @@ -110,11 +103,6 @@ declare namespace fastifyMultipart {
}

export interface FastifyMultipartBaseOptions {
/**
* Append the multipart parameters to the body object
*/
addToBody?: boolean;

/**
* Add a shared schema to validate the input fields
*/
Expand Down
Loading

0 comments on commit 1d824e3

Please sign in to comment.