From 1e18235c1d007c19913d8151205d1145eed35769 Mon Sep 17 00:00:00 2001 From: Ildar Kamalov Date: Thu, 11 Oct 2018 15:27:01 +0300 Subject: [PATCH] Send json for addFilter request --- client/src/api/Api.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/client/src/api/Api.js b/client/src/api/Api.js index c194ddfa..0e9a1c74 100644 --- a/client/src/api/Api.js +++ b/client/src/api/Api.js @@ -169,10 +169,11 @@ export default class Api { addFilter(url, name) { const { path, method } = this.FILTERING_ADD_FILTER; - const requestBody = `url=${url}&name=${name}`; const config = { - data: requestBody, - header: { 'Content-Type': 'text/plain' }, + data: { + name, + url, + }, }; return this.makeRequest(path, method, config); }