Skip to content

Commit

Permalink
Fix README call examples
Browse files Browse the repository at this point in the history
  • Loading branch information
andrejewski committed Oct 4, 2018
1 parent 8e6e725 commit 1b00593
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ This first example does not use any composition.
import { run, call, callMethod } from 'affection'

const getJSON = url => [
call(fetch, url),
call(fetch, [url]),
resp => [callMethod(resp, 'json')]
]

Expand Down Expand Up @@ -182,7 +182,7 @@ For example, we are building a dictionary of the most used word for each country
We want to retain the country we are querying about in the result.

```js
const getMostUsedWordInCountry = country => call(MyAPI, country)
const getMostUsedWordInCountry = country => call(MyAPI, [country])
const countryWordStep = step(getMostUsedWordInCountry)
const getCountryWord = mapStep(countryWordStep, (result, country) => ({ country, word: result }))

Expand Down

0 comments on commit 1b00593

Please sign in to comment.