Fix a bug where an include path could match multiple media paths.