Bug Fix: thumb is null

Bug Fix: Floating Button in upload Land
pull/1/head
Schoumi 7 years ago
parent 74d51dcaa7
commit 15564d1b49
  1. 3
      app/src/main/java/fr/mobdev/goblim/NetworkManager.java
  2. 9
      app/src/main/res/layout-land/upload.xml

@ -216,7 +216,8 @@ public class NetworkManager {
String token = msg.getString("token");
String thumb = msg.getString("thumb");
//get thumbnail and transform it to useful data
thumb = thumb.substring(thumb.indexOf(","));
if(thumb != null && thumb.contains(","))
thumb = thumb.substring(thumb.indexOf(","));
byte[] thumbData = Base64.decode(thumb, Base64.DEFAULT);
System.out.println("Data is not null? " + thumbData.length);
imgOutput = new Img(0, siteUrl, hashOutput, realHashOutput, Calendar.getInstance(), nbDays, thumbData,token);

@ -110,13 +110,4 @@
</RelativeLayout>
<android.support.design.widget.FloatingActionButton
android:id="@+id/new_image_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="16dp"
android:src="@android:drawable/stat_sys_upload_done"
/>
</android.support.design.widget.CoordinatorLayout>

Loading…
Cancel
Save