Updated the script to accept the correct file format