No Setter/field For Cardimage Found On Class
I have checked all the answers on similar problems but nothing helped me. Please help me out. This is an e-commerce android app. I am using firebase to fetch the data in cards. I h
Solution 1:
It seems like you are obfuscating your code hence you models.GenericProductModel
became d.a
.
To fix this issue you might add a rule to your proguard file to keep your class after obfuscation.
# To keep the specific class and all its properties and members.
-keep classcom.beingdev.magicprint.models.GenericProductModel{ *; }
# or to keep all classes under com.beingdev.magicprint
-keep classcom.beingdev.magicprint.** { *; }
Or, accordingly to the Firebase's documentation you can annotate your class fields with PropertyName() annotation to rename a field when it is serialized, e.g.:
publicclassGenericProductModelimplementsSerializable {
@PropertyName("cardid")publicint cardId;
//...
}
Post a Comment for "No Setter/field For Cardimage Found On Class"