Always publish image alt text
Previous code would discard the image alt-text if the user finished writing the text before the image had finished uploading. This code ensures the text is set after the image has completed uploading.
This commit is contained in:
parent
168be9223d
commit
24d7ef7ccb
53 changed files with 209 additions and 288 deletions
|
|
@ -67,8 +67,10 @@ public final class ProgressRequestBody extends RequestBody {
|
|||
uploaded += read;
|
||||
sink.write(buffer, 0, read);
|
||||
}
|
||||
|
||||
uploadListener.onProgressUpdate((int)(100 * uploaded / contentLength));
|
||||
} finally {
|
||||
content.close();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue