remove nulls from objects before stringifying