Manual:$wgFileRedirects

Details
If enabled, MediaWiki checks redirects in Image: namespace.