Page 2 of 2

Re: AccountsThread.Execute

Posted: Tue Jun 02, 2020 5:22 pm
by Kent Briggs
loquacious wrote:2020-05-30 22:57:01|AccountsThread.Execute error: parameter list count mismatch (36/37)
I'm looking at my code again. The "36" is the number of expected fields in the accounts database but the updating queue received a request with 37 fields in it. My guess is that your AccountsEdit call had a carriage return/line feed in one of the fields like Custom or Notes. Is that possible?

Re: AccountsThread.Execute

Posted: Tue Jun 02, 2020 5:32 pm
by Kent Briggs
Kent Briggs wrote:My guess is that your AccountsEdit call had a carriage return/line feed in one of the fields like Custom or Note
In fact I can reproduce it myself like this:

Code: Select all

http://127.0.0.1:8087/api?Command=AccountsEdit&Password=x&Player=pm1&Note=test1%0D%0Atest2
%0D and %0A are URL-encoded carriage return and line feed characters and that triggered the same 36/37 error you saw. So don't do that!

Re: AccountsThread.Execute

Posted: Wed Jun 03, 2020 2:05 pm
by loquacious
Kent Briggs wrote:
loquacious wrote:2020-05-30 22:57:01|AccountsThread.Execute error: parameter list count mismatch (36/37)
I'm looking at my code again. The "36" is the number of expected fields in the accounts database but the updating queue received a request with 37 fields in it. My guess is that your AccountsEdit call had a carriage return/line feed in one of the fields like Custom or Notes. Is that possible?
It absolutely could be possible. I use a multi-line text box for the Notes on my site. I'll look at this as well.