]> git.immae.eu Git - github/shaarli/Shaarli.git/blobdiff - application/updater/UpdaterUtils.php
Merge tag 'v0.12.1' into latest
[github/shaarli/Shaarli.git] / application / updater / UpdaterUtils.php
index 828a49fc02ae5909e6ab4c5c3502421af581ec81..206f826eda34b5719a5605c0c4b8106206b519b1 100644 (file)
@@ -11,7 +11,7 @@ class UpdaterUtils
      *
      * @return array Already done update methods.
      */
-    public static function read_updates_file($updatesFilepath)
+    public static function readUpdatesFile($updatesFilepath)
     {
         if (! empty($updatesFilepath) && is_file($updatesFilepath)) {
             $content = file_get_contents($updatesFilepath);
@@ -19,7 +19,7 @@ class UpdaterUtils
                 return explode(';', $content);
             }
         }
-        return array();
+        return [];
     }
 
     /**
@@ -30,7 +30,7 @@ class UpdaterUtils
      *
      * @throws \Exception Couldn't write version number.
      */
-    public static function write_updates_file($updatesFilepath, $updates)
+    public static function writeUpdatesFile($updatesFilepath, $updates)
     {
         if (empty($updatesFilepath)) {
             throw new \Exception('Updates file path is not set, can\'t write updates.');
@@ -38,7 +38,7 @@ class UpdaterUtils
 
         $res = file_put_contents($updatesFilepath, implode(';', $updates));
         if ($res === false) {
-            throw new \Exception('Unable to write updates in '. $updatesFilepath . '.');
+            throw new \Exception('Unable to write updates in ' . $updatesFilepath . '.');
         }
     }
 }