Skip to content

Commit

Permalink
Removed random bug
Browse files Browse the repository at this point in the history
  • Loading branch information
jrejaud committed Apr 8, 2016
1 parent 6923017 commit 7c1c7af
Showing 1 changed file with 7 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -169,13 +169,14 @@ private void showErrorAndCloseApp(String message, boolean closeApp) {
}
}

public void disconnect() {
public void disconnect() {
if (googleApiClient!=null) {
googleApiClient.disconnect();
}
Wearable.MessageApi.removeListener(googleApiClient, this);
Wearable.DataApi.removeListener(googleApiClient, this);
}
Wearable.MessageApi.removeListener(googleApiClient, this);
Wearable.DataApi.removeListener(googleApiClient, this);
}
}


//********************************************************************
//Send Message
Expand Down Expand Up @@ -342,4 +343,4 @@ public void setKeyDataType(String key, Type type) {
public interface onErrorListener {
void onError(Throwable throwable);
}
}
}

0 comments on commit 7c1c7af

Please sign in to comment.