From 9aeb76d588b81464beddfeb09b902128e9b9aa78 Mon Sep 17 00:00:00 2001 From: Vincent Vanwaelscappel Date: Mon, 8 Jul 2019 14:34:32 +0200 Subject: [PATCH] #2868 --- src/Translate.php | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/Translate.php b/src/Translate.php index 414c163..5e4f691 100644 --- a/src/Translate.php +++ b/src/Translate.php @@ -48,13 +48,9 @@ class Translate protected function _parseFile(SplFileInfo $file) { - $e = explode('.', $file); - $ext = $file->getExtension(); - - if (!in_array($ext, $this->_extensions)) { + if (!in_array($file->getExtension(), $this->_extensions)) { return; } - $this->_toTranslate = array_merge($this->_toTranslate, self::extractTextsToTranslate($file)); } @@ -87,7 +83,6 @@ class Translate return count($this->_toTranslate) > 0; } - /** * * @return array @@ -99,8 +94,7 @@ class Translate public static function saveTranslations($data, $path) { - $phpCode = '