diff options
author | Thomas Lange <code@nerdmind.de> | 2018-01-28 02:52:32 +0100 |
---|---|---|
committer | Thomas Lange <code@nerdmind.de> | 2018-01-28 02:52:32 +0100 |
commit | f48b94d0aaf8f7057b9f37152ae028b49c710f31 (patch) | |
tree | 224833ad9166ce656a18ab7735d6e7810624d4c0 /include | |
parent | fbe375107d96be9488b7072c8687a1acc3ba2fa6 (diff) | |
download | bigpipe-f48b94d0aaf8f7057b9f37152ae028b49c710f31.tar.gz bigpipe-f48b94d0aaf8f7057b9f37152ae028b49c710f31.tar.xz bigpipe-f48b94d0aaf8f7057b9f37152ae028b49c710f31.zip |
Replace function call "removeLineBreaksAndTabs" with "str_replace"
This commit replaces the function call of "removeLineBreaksAndTabs" from "Pagelet::flush()" with the direct call of the "str_replace" function. Therefore, you don't need to include the external function "removeLineBreaksAndTabs" (which was located outside the BigPipe namespace) into your project anymore.
Diffstat (limited to 'include')
-rw-r--r-- | include/classes/BigPipe/Pagelet.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/classes/BigPipe/Pagelet.php b/include/classes/BigPipe/Pagelet.php index 9e145fd..07b7d87 100644 --- a/include/classes/BigPipe/Pagelet.php +++ b/include/classes/BigPipe/Pagelet.php @@ -151,7 +151,7 @@ class Pagelet extends Item { #=============================================================================== public function flush() { if(BigPipe::enabled()) { - $pageletHTML = removeLineBreaksAndTabs($this->getHTML()); + $pageletHTML = str_replace(["\r", "\n", "\t"], '', $this->getHTML()); $pageletHTML = str_replace('--', '--', $pageletHTML); $pageletJSON = json_encode($this->getStructure()); |