Merge "Use the WebRequest::getCheck() shortcut where possible"
[lhc/web/wiklou.git] / includes / filebackend / FileBackendGroup.php
index 503acdc..a091608 100644 (file)
@@ -179,6 +179,7 @@ class FileBackendGroup {
                $config = $this->backends[$name]['config'];
                $config['class'] = $class;
                $config += [ // set defaults
+                       // @FIXME: this does not include the domain for b/c but it ideally should
                        'wikiId' => wfWikiID(), // e.g. "my_wiki-en_"
                        'mimeCallback' => [ $this, 'guessMimeInternal' ],
                        'obResetFunc' => 'wfResetOutputBuffers',
@@ -188,7 +189,9 @@ class FileBackendGroup {
                        'wanCache' => MediaWikiServices::getInstance()->getMainWANObjectCache(),
                        'srvCache' => ObjectCache::getLocalServerInstance( 'hash' ),
                        'logger' => LoggerFactory::getInstance( 'FileOperation' ),
-                       'profiler' => Profiler::instance()
+                       'profiler' => function ( $section ) {
+                               return Profiler::instance()->scopedProfileIn( $section );
+                       }
                ];
                $config['lockManager'] =
                        LockManagerGroup::singleton( $config['wikiId'] )->get( $config['lockManager'] );