Umherirrender has submitted this change and it was merged.
Change subject: Remove obvious function-level profiling
......................................................................
Remove obvious function-level profiling
Change-Id: I165f599a9c32e340ac102756ca684b3b81c4c7fe
---
M TimedTextPage.php
M WebVideoTranscode/WebVideoTranscode.php
M handlers/OggHandler/OggHandler.php
3 files changed, 1 insertion(+), 16 deletions(-)
Approvals:
Umherirrender: Verified; Looks good to me, approved
diff --git a/TimedTextPage.php b/TimedTextPage.php
index c8079db..a65f7a6 100644
--- a/TimedTextPage.php
+++ b/TimedTextPage.php
@@ -12,7 +12,6 @@
static private $videoWidth = 400;
public function view() {
- wfProfileIn( __METHOD__ );
$request = $this->getContext()->getRequest();
$out = $this->getContext()->getOutput();
$user = $this->getContext()->getUser();
@@ -21,11 +20,9 @@
if ( $this->getTitle()->getNamespace() != NS_TIMEDTEXT ||
isset( $diff ) ) {
parent::view();
- wfProfileOut( __METHOD__ );
return;
}
$this->renderOutput( $out );
- wfProfileOut( __METHOD__ );
}
/**
@@ -33,7 +30,6 @@
* @param $out OutputPage
*/
public function renderOutput( $out ){
- wfProfileIn( __METHOD__ );
// parse page title:
$titleParts = explode( '.', $this->getTitle()->getDBkey() );
$srt = array_pop( $titleParts );
@@ -48,7 +44,6 @@
if ( !$this->showDeletedRevisionHeader() ) {
wfDebug( __METHOD__ . ": cannot view deleted
revision\n" );
- wfProfileOut( __METHOD__ );
return;
}
}
@@ -64,7 +59,6 @@
} else {
$this->doLinkToRemote( $file );
}
- wfProfileOut( __METHOD__ );
return;
}
@@ -77,13 +71,11 @@
$basefile = wfFindFile( $videoTitle );
if ( !$basefile ) {
$out->addHTML( wfMessage(
'timedmedia-subtitle-no-video' )->escaped() );
- wfProfileOut( __METHOD__ );
return;
}
if( !$basefile->isLocal() ){
$this->doLinkToRemote( $basefile );
- wfProfileOut( __METHOD__ );
return;
}
@@ -113,7 +105,6 @@
)
)
);
- wfProfileOut( __METHOD__ );
}
/**
diff --git a/WebVideoTranscode/WebVideoTranscode.php
b/WebVideoTranscode/WebVideoTranscode.php
index d3b8232..adf3c03 100644
--- a/WebVideoTranscode/WebVideoTranscode.php
+++ b/WebVideoTranscode/WebVideoTranscode.php
@@ -611,7 +611,6 @@
global $wgTranscodeBackgroundTimeLimit;
$fileName = $file->getName();
if( ! isset( self::$transcodeState[$fileName] ) ){
- wfProfileIn( __METHOD__ );
if ( $db === false ) {
$db = $file->repo->getSlaveDB();
}
@@ -656,7 +655,6 @@
array( 'LIMIT' => count( $overTimeout )
)
);
}
- wfProfileOut( __METHOD__ );
}
return self::$transcodeState[ $fileName ];
}
@@ -868,8 +866,6 @@
public static function updateJobQueue( &$file, $transcodeKey ){
global $wgMemc;
- wfProfileIn( __METHOD__ );
-
$fileName = $file->getTitle()->getDbKey();
$db = $file->repo->getMasterDB();
@@ -944,7 +940,6 @@
);
}
}
- wfProfileOut( __METHOD__ );
}
/**
diff --git a/handlers/OggHandler/OggHandler.php
b/handlers/OggHandler/OggHandler.php
index f61552f..31d4f3d 100644
--- a/handlers/OggHandler/OggHandler.php
+++ b/handlers/OggHandler/OggHandler.php
@@ -77,7 +77,6 @@
if ( !$metadata || isset( $metadata['error'] ) || !isset(
$metadata['streams'] ) ) {
return array();
}
- wfProfileIn( __METHOD__ );
// See http://www.xiph.org/vorbis/doc/v-comment.html
// http://age.hobba.nl/audio/mirroredpages/ogg-tagging.html
@@ -138,7 +137,7 @@
$type = array_unique( $type );
$type = array_values( $type );
}
- wfProfileOut( __METHOD__ );
+
return $props;
}
--
To view, visit https://gerrit.wikimedia.org/r/189995
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I165f599a9c32e340ac102756ca684b3b81c4c7fe
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/TimedMediaHandler
Gerrit-Branch: master
Gerrit-Owner: Chad <[email protected]>
Gerrit-Reviewer: Umherirrender <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits