Completed
Push — master ( 0967f1...338ec3 )
by Junior
49s queued 26s
created

index.js ➔ ... ➔ ???   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
cc 1
c 2
b 0
f 0
nc 1
dl 0
loc 1
rs 10
nop 1
1
import axios from 'axios'
2
import { setFollowing } from 'modules/Github'
3
4
export const getFollowingUsers = ({ username, dispatch }) =>
5
  axios
6
    .get(`https://api.github.com/users/${username}/following`)
7
    .then(res => res.data.map(users => users.login))
8
    .then(following => dispatch(setFollowing(following)))
9