{"size": 417, "ext": "js", "max_stars_repo_path": "app/hocs/withTokensData.js", "max_stars_repo_name": "baophucct/neon-wallet", "max_stars_repo_stars_event_min_datetime": "2017-07-27T20:37:08.000Z", "max_stars_repo_stars_event_max_datetime": "2022-03-27T00:24:43.000Z", "max_issues_repo_path": "app/hocs/withTokensData.js", "max_issues_repo_name": "baophucct/neon-wallet", "max_issues_repo_issues_event_min_datetime": "2017-07-27T18:36:50.000Z", "max_issues_repo_issues_event_max_datetime": "2022-03-31T02:18:29.000Z", "max_forks_repo_path": "app/hocs/withTokensData.js", "max_forks_repo_name": "baophucct/neon-wallet", "max_forks_repo_forks_event_min_datetime": "2017-07-28T14:03:04.000Z", "max_forks_repo_forks_event_max_datetime": "2022-01-05T18:40:49.000Z"}
{"max_stars_count": 1241, "max_issues_count": 2042, "max_forks_count": 412, "avg_line_length": 29.7857142857, "max_line_length": 72, "alphanum_fraction": 0.726618705}
// @flow
import { withData, withRecall } from 'spunky'
import { compose } from 'recompose'

import settingsActions from '../actions/settingsActions'
import icoTokensActions from '../actions/icoTokensActions'

export default function withTokensData(key: string = 'tokens') {
  return compose(
    withData(settingsActions, settings => ({ [key]: settings.tokens })),
    withRecall(icoTokensActions, ['tokens']),
  )
}
