1 | 1 |
deleted file mode 100644 |
... | ... |
@@ -1,38 +0,0 @@ |
1 |
-<?php |
|
2 |
- |
|
3 |
-namespace Illuminate\View\Concerns; |
|
4 |
- |
|
5 |
-trait ManagesTranslations |
|
6 |
-{ |
|
7 |
- /** |
|
8 |
- * The translation replacements for the translation being rendered. |
|
9 |
- * |
|
10 |
- * @var array |
|
11 |
- */ |
|
12 |
- protected $translationReplacements = []; |
|
13 |
- |
|
14 |
- /** |
|
15 |
- * Start a translation block. |
|
16 |
- * |
|
17 |
- * @param array $replacements |
|
18 |
- * @return void |
|
19 |
- */ |
|
20 |
- public function startTranslation($replacements = []) |
|
21 |
- { |
|
22 |
- ob_start(); |
|
23 |
- |
|
24 |
- $this->translationReplacements = $replacements; |
|
25 |
- } |
|
26 |
- |
|
27 |
- /** |
|
28 |
- * Render the current translation. |
|
29 |
- * |
|
30 |
- * @return string |
|
31 |
- */ |
|
32 |
- public function renderTranslation() |
|
33 |
- { |
|
34 |
- return $this->container->make('translator')->getFromJson( |
|
35 |
- trim(ob_get_clean()), $this->translationReplacements |
|
36 |
- ); |
|
37 |
- } |
|
38 |
-} |
1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,38 @@ |
1 |
+<?php |
|
2 |
+ |
|
3 |
+namespace Illuminate\View\Concerns; |
|
4 |
+ |
|
5 |
+trait ManagesTranslations |
|
6 |
+{ |
|
7 |
+ /** |
|
8 |
+ * The translation replacements for the translation being rendered. |
|
9 |
+ * |
|
10 |
+ * @var array |
|
11 |
+ */ |
|
12 |
+ protected $translationReplacements = []; |
|
13 |
+ |
|
14 |
+ /** |
|
15 |
+ * Start a translation block. |
|
16 |
+ * |
|
17 |
+ * @param array $replacements |
|
18 |
+ * @return void |
|
19 |
+ */ |
|
20 |
+ public function startTranslation($replacements = []) |
|
21 |
+ { |
|
22 |
+ ob_start(); |
|
23 |
+ |
|
24 |
+ $this->translationReplacements = $replacements; |
|
25 |
+ } |
|
26 |
+ |
|
27 |
+ /** |
|
28 |
+ * Render the current translation. |
|
29 |
+ * |
|
30 |
+ * @return string |
|
31 |
+ */ |
|
32 |
+ public function renderTranslation() |
|
33 |
+ { |
|
34 |
+ return $this->container->make('translator')->getFromJson( |
|
35 |
+ trim(ob_get_clean()), $this->translationReplacements |
|
36 |
+ ); |
|
37 |
+ } |
|
38 |
+} |