From fc331f3c779252e5c0b201df7baf87aa0962cccb Mon Sep 17 00:00:00 2001 From: thecaliskan <13554944+thecaliskan@users.noreply.github.com> Date: Sun, 21 Mar 2021 14:21:55 +0300 Subject: [PATCH 1/3] Access Translator Json Paths --- src/Illuminate/Translation/FileLoader.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/Illuminate/Translation/FileLoader.php b/src/Illuminate/Translation/FileLoader.php index 17f6e59f0b0e..8875c8057565 100755 --- a/src/Illuminate/Translation/FileLoader.php +++ b/src/Illuminate/Translation/FileLoader.php @@ -184,4 +184,14 @@ public function namespaces() { return $this->hints; } + + /** + * Get an array of all the registered paths to JSON translation files. + * + * @return array + */ + public function getJsonPaths() + { + return $this->jsonPaths; + } } From 76e86bd19e5c7c87adbb768ac08c00f6c7a8dfa9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emre=20=C3=87al=C4=B1=C5=9Fkan?= Date: Sun, 21 Mar 2021 14:26:48 +0300 Subject: [PATCH 2/3] style ci fix --- src/Illuminate/Translation/FileLoader.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Illuminate/Translation/FileLoader.php b/src/Illuminate/Translation/FileLoader.php index 8875c8057565..b2285a6eceb6 100755 --- a/src/Illuminate/Translation/FileLoader.php +++ b/src/Illuminate/Translation/FileLoader.php @@ -184,7 +184,7 @@ public function namespaces() { return $this->hints; } - + /** * Get an array of all the registered paths to JSON translation files. * From 40e8d25a61d9401fc5fed41e4f4582c0d0a12173 Mon Sep 17 00:00:00 2001 From: Taylor Otwell Date: Sun, 21 Mar 2021 08:42:27 -0500 Subject: [PATCH 3/3] formatting --- src/Illuminate/Translation/FileLoader.php | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/Illuminate/Translation/FileLoader.php b/src/Illuminate/Translation/FileLoader.php index b2285a6eceb6..f359a8e5584d 100755 --- a/src/Illuminate/Translation/FileLoader.php +++ b/src/Illuminate/Translation/FileLoader.php @@ -165,24 +165,24 @@ public function addNamespace($namespace, $hint) } /** - * Add a new JSON path to the loader. + * Get an array of all the registered namespaces. * - * @param string $path - * @return void + * @return array */ - public function addJsonPath($path) + public function namespaces() { - $this->jsonPaths[] = $path; + return $this->hints; } /** - * Get an array of all the registered namespaces. + * Add a new JSON path to the loader. * - * @return array + * @param string $path + * @return void */ - public function namespaces() + public function addJsonPath($path) { - return $this->hints; + $this->jsonPaths[] = $path; } /** @@ -190,7 +190,7 @@ public function namespaces() * * @return array */ - public function getJsonPaths() + public function jsonPaths() { return $this->jsonPaths; }