From 6d409c1308988c47903c7eeb1da2c6011334861b Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Tue, 24 May 2011 19:52:27 +0000 Subject: [PATCH] Follow-up r88740: forgot to commit this guy --- includes/parser/Parser.php | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php index b0f8235006..47151ab076 100644 --- a/includes/parser/Parser.php +++ b/includes/parser/Parser.php @@ -4529,6 +4529,22 @@ class Parser { $this->mStripList = $this->mDefaultStripList; } + /** + * Remove a specific tag hook. Should not be called on $wgParser. + * + * @param string $tag + * @return void + */ + function clearTagHook( $tag ) { + if ( isset( $this->mTagHooks[$tag] ) ) { + unset( $this->mTagHooks[$tag] ); + $key = array_search( $tag, $this->mStripList ); + if ( $key !== false ) { + unset( $this->mStripList[$key] ); + } + } + } + /** * Create a function, e.g. {{sum:1|2|3}} * The callback function should have the form: -- 2.20.1