Code Duplication    Length = 12-12 lines in 2 locations

htdocs/class/smarty/Smarty_Compiler.class.php 2 locations

@@ 244-255 (lines=12) @@
241
        $rdq = preg_quote($this->right_delimiter, '~');
242
243
        // run template source through prefilter functions
244
        if (count($this->_plugins['prefilter']) > 0) {
245
            foreach ($this->_plugins['prefilter'] as $filter_name => $prefilter) {
246
                if ($prefilter === false) continue;
247
                if ($prefilter[3] || is_callable($prefilter[0])) {
248
                    $source_content = call_user_func_array($prefilter[0],
249
                                                            array($source_content, &$this));
250
                    $this->_plugins['prefilter'][$filter_name][3] = true;
251
                } else {
252
                    $this->_trigger_fatal_error("[plugin] prefilter '$filter_name' is not implemented");
253
                }
254
            }
255
        }
256
257
        /* fetch all special blocks */
258
        $search = "~{$ldq}\*(.*?)\*{$rdq}|{$ldq}\s*literal\s*{$rdq}(.*?){$ldq}\s*/literal\s*{$rdq}|{$ldq}\s*php\s*{$rdq}(.*?){$ldq}\s*/php\s*{$rdq}~s";
@@ 381-392 (lines=12) @@
378
        }
379
380
        // run compiled template through postfilter functions
381
        if (count($this->_plugins['postfilter']) > 0) {
382
            foreach ($this->_plugins['postfilter'] as $filter_name => $postfilter) {
383
                if ($postfilter === false) continue;
384
                if ($postfilter[3] || is_callable($postfilter[0])) {
385
                    $compiled_content = call_user_func_array($postfilter[0],
386
                                                              array($compiled_content, &$this));
387
                    $this->_plugins['postfilter'][$filter_name][3] = true;
388
                } else {
389
                    $this->_trigger_fatal_error("Smarty plugin error: postfilter '$filter_name' is not implemented");
390
                }
391
            }
392
        }
393
394
        // put header at the top of the compiled template
395
        $template_header = "<?php /* Smarty version ".$this->_version.", created on ".strftime("%Y-%m-%d %H:%M:%S")."\n";