-
-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #267 from Laravel-Lang/14.x
Store numeric keys as string
- Loading branch information
Showing
2 changed files
with
11 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,9 @@ | |
* file that was distributed with this source code. | ||
* | ||
* @author Andrey Helldar <[email protected]> | ||
* | ||
* @copyright 2022 Andrey Helldar | ||
* | ||
* @license MIT | ||
* | ||
* @see https://github.com/Laravel-Lang/publisher | ||
|
@@ -30,10 +32,15 @@ abstract class Base implements Filesystem | |
use Has; | ||
|
||
public function __construct( | ||
protected Pretty $pretty = new Pretty(), | ||
protected Pretty $pretty = new Pretty(), | ||
protected Formatter $formatter = new Formatter(), | ||
protected Config $config = new Config() | ||
protected Config $config = new Config() | ||
) { | ||
$this->formatter->setKeyAsString(); | ||
|
||
if ($this->config->hasAlign()) { | ||
$this->formatter->setEqualsAlign(); | ||
} | ||
} | ||
|
||
public function load(string $path): array | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,9 @@ | |
* file that was distributed with this source code. | ||
* | ||
* @author Andrey Helldar <[email protected]> | ||
* | ||
* @copyright 2022 Andrey Helldar | ||
* | ||
* @license MIT | ||
* | ||
* @see https://github.com/Laravel-Lang/publisher | ||
|
@@ -54,10 +56,6 @@ public function store(string $path, $content): string | |
|
||
protected function format(array $items): string | ||
{ | ||
if ($this->config->hasAlign()) { | ||
$this->formatter->setEqualsAlign(); | ||
} | ||
|
||
return $this->formatter->raw($items); | ||
} | ||
|
||
|