Send json for addFilter request

This commit is contained in:
Ildar Kamalov 2018-10-11 15:27:01 +03:00 committed by Eugene Bujak
parent 4b8ee9ce83
commit 1e18235c1d

View File

@ -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);
}