Xero-Java icon indicating copy to clipboard operation
Xero-Java copied to clipboard

StackOverflow error thrown on Invoices toString()

Open jawad-r3 opened this issue 4 years ago • 0 comments
trafficstars

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 "); }

jawad-r3 avatar Jun 16 '21 14:06 jawad-r3