Skip to content

Commit

Permalink
Fix for issue #1, according to https://code.google.com/p/android/issu…
Browse files Browse the repository at this point in the history
  • Loading branch information
patloew committed May 23, 2016
1 parent 0723fe1 commit 7e69479
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.google.android.gms.wearable.DataEvent;
import com.google.android.gms.wearable.DataMap;
import com.google.android.gms.wearable.DataMapItem;

import rx.Observable;
import rx.functions.Func1;
Expand Down Expand Up @@ -88,7 +89,7 @@ public Boolean call(DataEvent dataEvent) {
return observable.map(new Func1<DataEvent, DataMap>() {
@Override
public DataMap call(DataEvent dataEvent) {
return DataMap.fromByteArray(dataEvent.getDataItem().getData());
return DataMapItem.fromDataItem(dataEvent.getDataItem()).getDataMap();
}
});
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import com.google.android.gms.wearable.DataItem;
import com.google.android.gms.wearable.DataMap;
import com.google.android.gms.wearable.DataMapItem;

import rx.Observable;
import rx.functions.Func1;
Expand Down Expand Up @@ -65,7 +66,7 @@ public Boolean call(DataItem dataItem) {
return observable.map(new Func1<DataItem, DataMap>() {
@Override
public DataMap call(DataItem dataItem) {
return DataMap.fromByteArray(dataItem.getData());
return DataMapItem.fromDataItem(dataItem).getDataMap();
}
});
}
Expand Down

0 comments on commit 7e69479

Please sign in to comment.