StackOverflow error thrown on Invoices toString()
jawad-r3 opened this issue · 0 comments
jawad-r3 commented
Method threw 'java.lang.StackOverflowError' exception. Cannot evaluate com.xero.models.accounting.Invoices.toString()
@OverRide
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Invoices {\n");
sb.append(" invoices: ").append(toIndentedString(invoices)).append("\n");
sb.append("}");
return sb.toString();
}
/**
- Convert the given object to string with each line indented by 4 spaces (except the first line).
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}