Fix a bug related to file priorities