Set mw.config wgFileExtensions only on Upload instead of site-wide

It is just used by mediawiki.special.upload

Change-Id: I433e29866fe184ba80c5dda35722e228e79f9307
Merge "Set mw.config wgFileExtensions only on Upload instead of site-wide"