Skip to content

Commit

Permalink
Merge pull request #40 from izumin5210/release/droidux-thunk-v0.2.0
Browse files Browse the repository at this point in the history
Droidux Thunk v0.2.0
  • Loading branch information
Masayuki IZUMI committed Dec 26, 2015
2 parents b75164b + 308eb5d commit e0a1d0a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ And also you need to setup [Data Binding][databinding].
When you use `AsyncAction`, you need to add [droidux-thunk](https://github.com/izumin5210/Droidux/tree/master/middlewares/droidux-thunk).

```groovy
compile 'info.izumin.android:droidux-thunk:0.1.0'
compile 'info.izumin.android:droidux-thunk:0.2.0'
```

## Usage
Expand Down Expand Up @@ -333,8 +333,9 @@ class FetchTodoListAction implements AsyncAction {
this.client = client;
}

public Observable<ReceiveTodoListAction> call() {
return client.fetch()
public Observable<ReceiveTodoListAction> call(Dispatcher dispatcher) {
return dispatcher.dispatch(new DoingFetchAction())
.flatMap(_action -> client.fetch())
.map(todoList -> {
this.todoList = todoList;
return new ReceiveTodoListAction(todoList);
Expand Down
2 changes: 1 addition & 1 deletion middlewares/droidux-thunk/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ publish {
userOrg = project_bintray_org
groupId = project_group
artifactId = 'droidux-thunk'
version = '0.1.0'
version = '0.2.0'
description = 'Thunk middleware for Droidux.'
website = project_url
}

0 comments on commit e0a1d0a

Please sign in to comment.