This commit addresses an issue where files with a .wav extension but containing non-WAV data (such as FLAC) caused errors due to incorrect format assumptions. The updated logic now verifies the WAV header before processing and conditionally overwrites or converts the file based on its actual content and header validity.
This commit addresses an issue where files with a .wav extension but containing non-WAV data (such as FLAC) caused errors due to incorrect format assumptions. The updated logic now verifies the WAV header before processing and conditionally overwrites or converts the file based on its actual content and header validity.