Andrew Ducker (andrewducker) wrote in lj_dev,
Andrew Ducker
andrewducker
lj_dev

  • Music:

XML-RPC problem with getfriends when a purely numeric friends name exists

Edited to cut the code so it doesn't break people's friends pages

<value><struct><member><name>bgcolor</name><value><string>#ffffff</string></value></member><member><name>fgcolor</name><value><string>#000000</string></value></member><member><name>fullname</name><value><int>0000000000007</int></value></member><member><name>username</name><value><int>0000000000007</int></value></member></struct></value>

isn't valid - because I'm getting back an "int" for the value of the username and fullname. I know that in this unusual case the username _is_ an int, but it's breaking code in the XMLRPC framework I'm using, because it's trying to parse it into a string.

<value><struct><member><name>bgcolor</name><value><string>#ffffff</string></value></member><member><name>fgcolor</name><value><string>#000000</string></value></member><member><name>fullname</name><value><string>0olong</string></value></member><member><name>username</name><value><string>0olong</string></value></member></struct></value>

is what the structure should be (although obviously that's a different user)

Is this something that can be fixed?
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 17 comments