[wp-trac] [WordPress Trac] #16980: Empty Values are converted to null by class-ixr.php
WordPress Trac
wp-trac at lists.automattic.com
Sun Mar 27 15:54:39 UTC 2011
#16980: Empty Values are converted to null by class-ixr.php
--------------------------+------------------------------
Reporter: nprasath002 | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: XML-RPC | Version: 3.1
Severity: major | Resolution:
Keywords: needs-patch |
--------------------------+------------------------------
Old description:
> I tried to fix the following bug #10599
> Found out when you send and empty value via xmlrpc it converts it to null
> value.
>
> Say you send and array of arguments for mw_editpost, set
>
> {{{
> $content_struct[mt_keywords] = '';
> }}}
>
> IXR client passes a null value instead of an empty value.
>
> In mw_post method consider this statement
>
> {{{
> $tags_input = isset( $content_structmt_keywords? ) ?
> $content_struct[mt_keywords] : null;
> }}}
>
> Even if you send an empty value this statement fails because
>
> {{{
> $content_struct[mt_keywords]
> }}}
>
> is set to null by IXR client.
New description:
I tried to fix the following bug #10599
Found out when you send and empty value via xmlrpc it converts it to null
value.
Say you send and array of arguments for mw_editpost, set
{{{
$content_struct[mt_keywords] = '';
}}}
IXR client passes a null value instead of an empty value.
In mw_post method consider this statement
{{{
$tags_input = isset( $content_struct[mt_keywords] ) ?
$content_struct[mt_keywords] : null;
}}}
Even if you send an empty value this statement fails because
{{{
$content_struct[mt_keywords]
}}}
is set to null by IXR client.
--
Comment (by aaroncampbell):
Updated the code in description.
nprasath002: I'm not sure exactly how the permissions are set up, but I do
know that not everyone can change a ticket description.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/16980#comment:4>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list