add getConfig to api

This commit is contained in:
igoradamenko
2018-02-13 01:15:09 +02:00
parent 94244f9751
commit 37c2e8b3fd
+4
View File
@@ -4,6 +4,8 @@ import fetcher from './fetcher'
/* common */
export const getConfig = () => fetcher.get(`/config`);
export const find = ({ url }) => fetcher.get(`/find?url=${url}&sort=-score&format=tree`);
export const getComment = ({ id }) => fetcher.get(`/id/${id}?url=${url}`);
@@ -33,11 +35,13 @@ export const blockUser = ({ id }) => fetcher.put(`/admin/user/${id}?block=1`);
export const unblockUser = ({ id }) => fetcher.put(`/admin/user/${id}?block=0`);
export default {
getConfig,
find,
getComment,
vote,
send,
getUser,
pin,
unpin,
remove,