Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

StackOverflow error thrown on Invoices toString() #289

Open
jawad-r3 opened this issue Jun 16, 2021 · 0 comments
Open

StackOverflow error thrown on Invoices toString() #289

jawad-r3 opened this issue Jun 16, 2021 · 0 comments

Comments

@jawad-r3
Copy link

jawad-r3 commented Jun 16, 2021

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 ");
    }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant