thomasgalliker/ObjectDumper

Option of excluding lineBreakChar for final property of object

Benelio opened this issue · 3 comments

When logging on a single line, the lineBreakChar can currently be set to ',' (for example) to comma separate the properties of the object. However, the final property will then still print the lineBreakChar at the end, which looks incorrect.

e.g.

property1 = "a" , property2 = "b" , property3 = "c" ,

It would be a nice feature to have an option of excluding this linebreakChar for the final property. Which I suppose people might still want even if using newline as the character.

Ok, I see. It looks like we’re line-breaking at the end of each property, regardless of which lineBreakChar is configured.

I gonna look into this as soon as I have some spare time. (Is it critical? I guess its just a code style issue for you?)

I tried to reproduce this issue but I can't. Can you write a unit test which reproduces the error case? You can also just post the repro code here, @Benelio

@Benelio is this still an issue?