mirror of
https://github.com/syncthing/syncthing-android.git
synced 2024-12-24 11:51:30 +00:00
Don't retry if the task was cancelled
This commit is contained in:
parent
a447807ff6
commit
97bbeadc6a
1 changed files with 3 additions and 0 deletions
|
@ -68,6 +68,9 @@ public class GetTask extends AsyncTask<String, Void, String> {
|
||||||
HttpGet get = new HttpGet(fullUri);
|
HttpGet get = new HttpGet(fullUri);
|
||||||
get.addHeader(new BasicHeader(RestApi.HEADER_API_KEY, params[2]));
|
get.addHeader(new BasicHeader(RestApi.HEADER_API_KEY, params[2]));
|
||||||
|
|
||||||
|
if (isCancelled())
|
||||||
|
return null;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
Log.w(TAG, "Calling Rest API at " + fullUri);
|
Log.w(TAG, "Calling Rest API at " + fullUri);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue