Hylozoic / hylo-evo

Hylo UI
Apache License 2.0
36 stars 10 forks source link

Fix bug preventing image deletion on post #1618

Closed KevinTriplett closed 3 months ago

KevinTriplett commented 3 months ago

fixes #1616

Discovered that the 'X' delete icon was wrapped in the draggable image element. This prevented the click event from firing to delete the image.

After fixing the click event bug, I still could not delete a single image (it would delete all images) so I discovered that the reject method wasn't working properly with all the hash keys being passed in, so I isolated the url key and that fixed the problem. I didn't create any tests (other than updating the snapshot) but hand tested it with multiple images, sorting, and file attachments and it worked as expected.

codecov[bot] commented 3 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 47.51%. Comparing base (ba370ad) to head (420bb04).

:exclamation: Current head 420bb04 differs from pull request most recent head 535ffdd. Consider uploading reports for the commit 535ffdd to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## dev #1618 +/- ## ========================================== - Coverage 47.53% 47.51% -0.02% ========================================== Files 569 569 Lines 13443 13443 Branches 3866 3866 ========================================== - Hits 6390 6388 -2 - Misses 7053 7055 +2 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.