Is there any way to delete old image/attachments when deleting or updating records??

I tried different ways to delete old image path but no solutions were working. In fact filament tricks as well has a third party function that too didn't work. Can anyone help to achieve this.
Was this page helpful?