aboutsummaryrefslogtreecommitdiff
path: root/src/pages/ProfilePage
diff options
context:
space:
mode:
authorEugene Sokolov <eug-vs@keemail.me>2020-07-03 18:22:40 +0300
committerGitHub <noreply@github.com>2020-07-03 18:22:40 +0300
commitcb521315c2291eda6b273b5f8a2e014c24ea9758 (patch)
tree3a3a42a347760ccdf54dadeb7dfbcfd673f32947 /src/pages/ProfilePage
parent2e7f7610169391c78d852caea73190e5d8c0b978 (diff)
parent7fe63f3be94d8711bdfdf714d9a6129318546ef1 (diff)
downloadwhich-ui-cb521315c2291eda6b273b5f8a2e014c24ea9758.tar.gz
Merge pull request #58 from which-ecosystem/improvements
Improvements
Diffstat (limited to 'src/pages/ProfilePage')
-rw-r--r--src/pages/ProfilePage/ProfilePage.tsx1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/pages/ProfilePage/ProfilePage.tsx b/src/pages/ProfilePage/ProfilePage.tsx
index 2c18466..b7106bb 100644
--- a/src/pages/ProfilePage/ProfilePage.tsx
+++ b/src/pages/ProfilePage/ProfilePage.tsx
@@ -22,6 +22,7 @@ const ProfilePage: React.FC = () => {
setUserInfo(response.data);
});
get(`/profiles/${id}`).then(response => {
+ setPolls([]);
setPolls(response.data);
setTotalVotes(response.data.reduce(
(total: number, current: Poll) => {