浏览代码

Removing renderSection short-circuit, as it doesn't actually improve performance.

Justin Hileman 15 年之前
父节点
当前提交
ce019bec81
共有 1 个文件被更改,包括 0 次插入4 次删除
  1. 0 4
      Mustache.php

+ 0 - 4
Mustache.php

@@ -114,10 +114,6 @@ class Mustache {
 	 * @return string
 	 */
 	protected function renderSection($template, &$context) {
-		if (strpos($template, $this->otag . '#') === false && strpos($template, $this->otag . '^') === false) {
-			return $template;
-		}
-
 		$otag  = $this->prepareRegEx($this->otag);
 		$ctag  = $this->prepareRegEx($this->ctag);
 		$regex = '/' . $otag . '(\\^|\\#)(.+?)' . $ctag . '\\s*([\\s\\S]+?)' . $otag . '\\/\\2' . $ctag . '\\s*/m';