public static function toJson($features)
	{
		if (is_null($features) || count($features) == 0) {
			return null;
		}

		return Collection::make($features)->filter(function ($item) {
			return trim($item) != '';
		})->toJson();
	}
public static function toJson($features)
	{
		if (is_null($features) || count($features) == 0) {
			return null;
		}

		return Collection::make($features)->filter(function ($item) {
			return trim($item) != '';
		})->toJson();
	}
public static function toJson ( $ features ) { if ( is_null ( $ features ) || count ( $ features ) == 0 ) { return null ; } return Collection :: make ( $ features ) -> filter ( function ( $ item ) { return trim ( $ item ) != '' ; } ) -> toJson ( ) ; }
Parses the given features to Json.

@param  array|Collection $features

@return null|string
Parses the given features to Json .