@@ -15,7 +15,7 @@ discard block |
||
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | $db = file_get_contents(getenv("HOME").'/'.self::DIRECTORY.'/'.self::DB); |
| 18 | - $jsonDb = json_decode($db,true); |
|
| 18 | + $jsonDb = json_decode($db, true); |
|
| 19 | 19 | if (!is_array($jsonDb)) { |
| 20 | 20 | throw new \RuntimeException('$jsonDb must be an array.'); |
| 21 | 21 | } |
@@ -28,11 +28,11 @@ discard block |
||
| 28 | 28 | $this->generateDatabase(); |
| 29 | 29 | $jsonDb = $this->getProjects(); |
| 30 | 30 | |
| 31 | - if (isset($jsonDb[$keyProject])){ |
|
| 31 | + if (isset($jsonDb[$keyProject])) { |
|
| 32 | 32 | unset($jsonDb[$keyProject]); |
| 33 | 33 | try { |
| 34 | 34 | file_put_contents(getenv("HOME").'/'.self::DIRECTORY.'/'.self::DB, json_encode($jsonDb)); |
| 35 | - } catch (\Exception $e){ |
|
| 35 | + } catch (\Exception $e) { |
|
| 36 | 36 | return false; |
| 37 | 37 | } |
| 38 | 38 | return true; |
@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | |
| 50 | 50 | try { |
| 51 | 51 | file_put_contents(getenv("HOME").'/'.self::DIRECTORY.'/'.self::DB, json_encode($jsonDb)); |
| 52 | - } catch (\Exception $e){ |
|
| 52 | + } catch (\Exception $e) { |
|
| 53 | 53 | return false; |
| 54 | 54 | } |
| 55 | 55 | |