Found out that the feature with attachments was broken, probably due to the fact that the logic of working with adapters has changed a bit:
When user select from the prefetences, always rename the file / set a unique hash / metadata, then the feature was not applied when the file was attached to the post. I removed the extra call to setAdapter and moved the code that checks if the element is selected to another place, it worked
The application crashed when an attempt was made to reencode a file. Fixed
Found out that the feature with attachments was broken, probably due to the fact that the logic of working with adapters has changed a bit: