We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c3cb420 commit ac7ef51Copy full SHA for ac7ef51
pickit/src/main/java/com/hbisoft/pickit/DownloadAsyncTask.java
@@ -90,7 +90,12 @@ protected String doInBackground(Uri... params) {
90
if (!isCancelled()) {
91
total += count;
92
if (size != -1) {
93
- publishProgress((int) ((total * 100) / size));
+ try {
94
+ publishProgress((int) ((total * 100) / size));
95
+ }catch(Exception e){
96
+ Log.i("PickiT -", "File size is less than 1");
97
+ publishProgress(0);
98
+ }
99
}
100
fos.write(data, 0, count);
101
0 commit comments