I am trying to create an API in Typescript using the plugin. but i am getting the error :
TypeError: error.json is not a function
at getErrorMessage (D:\personal\projects\blogger\node_modules\wordpress-api-client\dist\util.js:35:30)
at FetchClient.fetch (D:\personal\projects\blogger\node_modules\wordpress-api-client\dist\fetch-client.js:54:62)
at processTicksAndRejections (internal/process/task_queues.js:95:5)
at FetchClient.post (D:\personal\projects\blogger\node_modules\wordpress-api-client\dist\fetch-client.js:90:17)
at NewsService.blogHandler (D:\personal\projects\blogger\src\news\news.service.ts:35:22)
at NewsController.getNews (D:\personal\projects\blogger\src\news\news.controller.ts:10:22)
at D:\personal\projects\blogger\node_modules\@nestjs\core\router\router-execution-context.js:46:28
at D:\personal\projects\blogger\node_modules\@nestjs\core\router\router-proxy.js:9:17
I am trying to create an API in Typescript using the plugin. but i am getting the error :