@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | */ |
48 | 48 | public function remove(string $name): void |
49 | 49 | { |
50 | - if (! isset($this->params[$name])) { |
|
50 | + if (!isset($this->params[$name])) { |
|
51 | 51 | throw new InvalidArgumentException('Parameter not found for remove'); |
52 | 52 | } |
53 | 53 | unset($this->params[$name]); |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | |
56 | 56 | public function update(string $name, $value): void |
57 | 57 | { |
58 | - if (! isset($this->params[$name])) { |
|
58 | + if (!isset($this->params[$name])) { |
|
59 | 59 | throw new InvalidArgumentException('Parameter not found for update'); |
60 | 60 | } |
61 | 61 | $this->params[$name] = new Param($name, $value); |
@@ -25,7 +25,7 @@ discard block |
||
25 | 25 | { |
26 | 26 | $data = false; |
27 | 27 | |
28 | - if (! count($config)) { |
|
28 | + if (!count($config)) { |
|
29 | 29 | $this->initDefaultConfig(); |
30 | 30 | } |
31 | 31 | if ($filename && file_exists($filename)) { |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | */ |
48 | 48 | private function sectionLoad(array $data): void |
49 | 49 | { |
50 | - if (! count($data)) { |
|
50 | + if (!count($data)) { |
|
51 | 51 | throw new InvalidArgumentException('Data is not set'); |
52 | 52 | } |
53 | 53 | |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | public function getSection(string $name): Section |
67 | 67 | { |
68 | - if (! isset($this->sections[$name])) { |
|
68 | + if (!isset($this->sections[$name])) { |
|
69 | 69 | throw new InvalidArgumentException('Section not found'); |
70 | 70 | } |
71 | 71 | |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | */ |
78 | 78 | public function removeSection(string $name): void |
79 | 79 | { |
80 | - if (! isset($this->sections[$name])) { |
|
80 | + if (!isset($this->sections[$name])) { |
|
81 | 81 | throw new InvalidArgumentException('Section not found for remove'); |
82 | 82 | } |
83 | 83 | unset($this->sections[$name]); |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | |
94 | 94 | public function updateSection(string $name, array $section): void |
95 | 95 | { |
96 | - if (! isset($this->sections[$name])) { |
|
96 | + if (!isset($this->sections[$name])) { |
|
97 | 97 | throw new InvalidArgumentException('Section not found for update'); |
98 | 98 | } |
99 | 99 | $this->sections[$name] = new Section($name, $section); |
@@ -135,7 +135,7 @@ discard block |
||
135 | 135 | */ |
136 | 136 | public function save(string $filename = null): bool |
137 | 137 | { |
138 | - if (! $this->config['overwrite'] && file_exists($filename)) { |
|
138 | + if (!$this->config['overwrite'] && file_exists($filename)) { |
|
139 | 139 | throw new InvalidArgumentException('Overwrite file protection'); |
140 | 140 | } |
141 | 141 | if ($filename) { |
@@ -5,7 +5,6 @@ |
||
5 | 5 | namespace Compolomus\IniObject; |
6 | 6 | |
7 | 7 | use InvalidArgumentException; |
8 | -use SplFileObject; |
|
9 | 8 | |
10 | 9 | class IniObject |
11 | 10 | { |