From 2b76cbeb667472e403042c42dd956eb89603ab70 Mon Sep 17 00:00:00 2001 From: Justin Hileman Date: Sun, 2 Jul 2017 22:55:12 -0700 Subject: [PATCH] Remove unused internal compiler arg. We stopped passing it in 11ad87ae but missed the cleanup. --- src/Mustache/Compiler.php | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/Mustache/Compiler.php b/src/Mustache/Compiler.php index 64c58d2..944d705 100644 --- a/src/Mustache/Compiler.php +++ b/src/Mustache/Compiler.php @@ -365,11 +365,10 @@ class Mustache_Compiler * @param string $otag Current Mustache opening tag * @param string $ctag Current Mustache closing tag * @param int $level - * @param bool $arg (default: false) * * @return string Generated section PHP source code */ - private function section($nodes, $id, $filters, $start, $end, $otag, $ctag, $level, $arg = false) + private function section($nodes, $id, $filters, $start, $end, $otag, $ctag, $level) { $source = var_export(substr($this->source, $start, $end - $start), true); $callable = $this->getCallable(); @@ -389,15 +388,11 @@ class Mustache_Compiler $this->sections[$key] = sprintf($this->prepare(self::SECTION), $key, $callable, $source, $helper, $delims, $this->walk($nodes, 2)); } - if ($arg === true) { - return $key; - } else { - $method = $this->getFindMethod($id); - $id = var_export($id, true); - $filters = $this->getFilters($filters, $level); + $method = $this->getFindMethod($id); + $id = var_export($id, true); + $filters = $this->getFilters($filters, $level); - return sprintf($this->prepare(self::SECTION_CALL, $level), $id, $method, $id, $filters, $key); - } + return sprintf($this->prepare(self::SECTION_CALL, $level), $id, $method, $id, $filters, $key); } const INVERTED_SECTION = '