Error -50 WD My Passport

I have a WD My Passport external harddrive. When I plug it into my Mac, suddenly I get contents from the drive in my Trash, but I am unable to delete them. It then tells me "The operation can’t be completed because an unexpected error occurred (error code -50).

Then I can’t eject the drive as it says files are in use (obviously the ones in the trash).

Please help me.

Welcome to the Community.

It’s possible for the hard drive to be corrupted. I’d recommend running a drive health test using your Mac’s Disk Utility followed by a Repair process.