|
|
@ -10,7 +10,7 @@ import { |
|
|
|
} from 'fastify' |
|
|
|
import { Server, IncomingMessage, ServerResponse } from 'http' |
|
|
|
import request from 'request' |
|
|
|
import { PluginOptions, GiphyResponse } from '../../types' |
|
|
|
import { PluginOptions, GiphyResponse } from '../types' |
|
|
|
|
|
|
|
interface FetchOptions { |
|
|
|
url: string |
|
|
@ -65,7 +65,7 @@ async function fetch<T = any>(options: FetchOptions) { |
|
|
|
uri, |
|
|
|
method, |
|
|
|
json: true, |
|
|
|
}, function(error, response, body) { |
|
|
|
}, function(error, _, body) { |
|
|
|
if (error) { |
|
|
|
reject(error) |
|
|
|
return |