MediaWikiServices: Import NoSuchServiceException
authorSam Smith <git@samsmith.io>
Wed, 31 Aug 2016 10:46:02 +0000 (11:46 +0100)
committerSam Smith <git@samsmith.io>
Wed, 31 Aug 2016 10:59:23 +0000 (11:59 +0100)
NoSuchServiceException is in the MediaWiki\Services namespace. Since the
MediaWikiServices class is in the MediaWiki namespace, the

  catch ( NoSuchServiceException $e )

line added in Ifc587d61 will fail to catch any exception.

Co-Author: Paladox <thomasmulhall410@yahoo.com>
Bug: T143974
Change-Id: I903336c85c0bb9fb259f475f37959136e2ff7eca

includes/MediaWikiServices.php

index 037e96f..f621867 100644 (file)
@@ -16,6 +16,7 @@ use MediaWiki\Linker\LinkRenderer;
 use MediaWiki\Linker\LinkRendererFactory;
 use MediaWiki\Services\SalvageableService;
 use MediaWiki\Services\ServiceContainer;
+use MediaWiki\Services\NoSuchServiceException;
 use MWException;
 use ObjectCache;
 use SearchEngine;