I use Picasso to upload some images from online to the View list. The problem is that some of the images have been successfully uploaded, some just disappear.
Successful (brand image successfully displayed):

Failed (brand image is not displayed, failed):

ImageView disappears when it fails. Here is my code:
Picasso.with(mContext)
.load(UrlEncoder.encode(interiorDesign.getBrand_image_url()))
.config(Bitmap.Config.RGB_565)
.error(R.drawable.blank)
.fit()
.centerInside()
.into(holder.brand);
Here is my .xml file:
<LinearLayout
android:layout_width="match_parent"
android:layout_height="90dp"
android:paddingLeft="10dp"
android:paddingRight="10dp"
android:layout_alignParentLeft="true"
android:gravity="center_vertical"
android:orientation="horizontal">
<RelativeLayout
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:paddingRight="10dp">
...
</RelativeLayout>
<ImageView
android:layout_width="200dp"
android:layout_height="90dp"
android:paddingBottom="10dp"
android:id="@+id/partial_interior_design_brand" />
</LinearLayout>
I checked that it fails because it detects an error in the Picasso () error method.
Here is a link of the unsuccessful.
Here 's another bad link.
Here is a successful link.
. , fit() centerInside(), . .