aboutsummaryrefslogtreecommitdiffhomepage
path: root/application/FileUtils.php
diff options
context:
space:
mode:
Diffstat (limited to 'application/FileUtils.php')
-rw-r--r--application/FileUtils.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/application/FileUtils.php b/application/FileUtils.php
index b89ea12b..30560bfc 100644
--- a/application/FileUtils.php
+++ b/application/FileUtils.php
@@ -1,6 +1,8 @@
1<?php 1<?php
2 2
3require_once 'exceptions/IOException.php'; 3namespace Shaarli;
4
5use Shaarli\Exceptions\IOException;
4 6
5/** 7/**
6 * Class FileUtils 8 * Class FileUtils
@@ -44,7 +46,7 @@ class FileUtils
44 46
45 return file_put_contents( 47 return file_put_contents(
46 $file, 48 $file,
47 self::$phpPrefix.base64_encode(gzdeflate(serialize($content))).self::$phpSuffix 49 self::$phpPrefix . base64_encode(gzdeflate(serialize($content))) . self::$phpSuffix
48 ); 50 );
49 } 51 }
50 52
@@ -62,7 +64,7 @@ class FileUtils
62 { 64 {
63 // Note that gzinflate is faster than gzuncompress. 65 // Note that gzinflate is faster than gzuncompress.
64 // See: http://www.php.net/manual/en/function.gzdeflate.php#96439 66 // See: http://www.php.net/manual/en/function.gzdeflate.php#96439
65 if (! is_readable($file)) { 67 if (!is_readable($file)) {
66 return $default; 68 return $default;
67 } 69 }
68 70