修改一处值传递为引用

This commit is contained in:
TOP糯米 2024-07-29 15:26:40 +08:00
parent e3f30a2735
commit 5ce37d1697
1 changed files with 2 additions and 2 deletions

View File

@ -133,10 +133,10 @@ class Engine
/** /**
* 检测是否含有include * 检测是否含有include
* @param $template * @param &$template
* @return bool * @return bool
*/ */
private function hasInclude($template) private function hasInclude(&$template)
{ {
$pattern = '/' . $this->left . 'include\s+file[\s\S]*?=[\s\S]*?[\'"](.*?)[\'"][\s\S]*?\/' . $this->right . '/is'; $pattern = '/' . $this->left . 'include\s+file[\s\S]*?=[\s\S]*?[\'"](.*?)[\'"][\s\S]*?\/' . $this->right . '/is';
preg_match($pattern, $template, $matches); preg_match($pattern, $template, $matches);