Fixed EXTENSIONS in constants, made embed determine file extension dynamically thanks to new function in file_utils