From d1d9c715c9aa9167cb04ecef1bbb1595221bbd49 Mon Sep 17 00:00:00 2001 From: Jordi Boggiano Date: Thu, 16 Feb 2012 20:37:05 +0100 Subject: [PATCH] Add newline at the end of formatted jsons --- src/Composer/Json/JsonFile.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Composer/Json/JsonFile.php b/src/Composer/Json/JsonFile.php index 2af32d32f..307139a6f 100644 --- a/src/Composer/Json/JsonFile.php +++ b/src/Composer/Json/JsonFile.php @@ -104,7 +104,7 @@ class JsonFile ); } } - file_put_contents($this->path, static::encode($hash, $options)); + file_put_contents($this->path, static::encode($hash, $options). ($options & JSON_PRETTY_PRINT ? "\n" : '')); } /**