Fix basename to lowercase