@@ -6,25 +6,25 @@ |
||
6 | 6 | * @author Caio Almeida <[email protected]> |
7 | 7 | * @author Gustavo Lira <[email protected]> |
8 | 8 | */ |
9 | - class Writer implements Writable |
|
10 | - { |
|
11 | - /** |
|
12 | - * @var string |
|
13 | - */ |
|
14 | - const MODE = 'w'; |
|
9 | + class Writer implements Writable |
|
10 | + { |
|
11 | + /** |
|
12 | + * @var string |
|
13 | + */ |
|
14 | + const MODE = 'w'; |
|
15 | 15 | |
16 | - /** |
|
17 | - * @param string $path |
|
18 | - * @param mixed $data |
|
19 | - * @return void |
|
20 | - */ |
|
21 | - public function write($path, $data) |
|
22 | - { |
|
23 | - if (!$resource = @fopen($path, self::MODE)) { |
|
24 | - throw new CannotWriteException(); |
|
25 | - } |
|
16 | + /** |
|
17 | + * @param string $path |
|
18 | + * @param mixed $data |
|
19 | + * @return void |
|
20 | + */ |
|
21 | + public function write($path, $data) |
|
22 | + { |
|
23 | + if (!$resource = @fopen($path, self::MODE)) { |
|
24 | + throw new CannotWriteException(); |
|
25 | + } |
|
26 | 26 | |
27 | - fwrite($resource, $data); |
|
28 | - fclose($resource); |
|
29 | - } |
|
30 | - } |
|
27 | + fwrite($resource, $data); |
|
28 | + fclose($resource); |
|
29 | + } |
|
30 | + } |