Fixing newlines

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jhodgdon’s picture

In some of your other patches, you also corrected missing . at ends of @param or @return lines. This patch has some missing. Want to fix them too?

Also, if you are doing that:

+ *
  * @return
  *   Object.

Needs expansion - what type of object?

aspilicious’s picture

Title: Fix newlines in xmlcpr.inc » Fix doc errors in xmlcpr.inc and fill in the missing doc headers
Status: Needs review » Needs work
/**
 * Construct an object representing an XML-RPC message.
 *
 * @param $message
 *   String containing XML as defined at http://www.xmlrpc.com/spec
 *
 * @return
 *   Object
 */
function xmlrpc_message($message) {
  $xmlrpc_message = new stdClass();
  $xmlrpc_message->array_structs = array();   // The stack used to keep track of the current array/struct
  $xmlrpc_message->array_structs_types = array(); // The stack used to keep track of if things are structs or array
  $xmlrpc_message->current_struct_name = array();  // A stack as well
  $xmlrpc_message->message = $message;
  return $xmlrpc_message;
}

and

/**
 * Store a copy of the $xmlrpc_message object temporarily.
 *
 * @param $value.
 *   Object
 *
 * @return
 *   The most recently stored $xmlrpc_message.
 */
function xmlrpc_message_set($value = NULL) {
  static $xmlrpc_message;
  if ($value) {
    $xmlrpc_message = $value;
  }
  return $xmlrpc_message;
}

Are the code parts for the incomplete headers.

There are even some undocumented functions in that class...
So I'll leave this patch needs work for now and I'm changing the title.

Would be nice if the coder of that part could fix this.

jhodgdon’s picture

Assigned: aspilicious » jhodgdon

OK, I'll take it on.

jhodgdon’s picture

Assigned: jhodgdon » Unassigned
Priority: Minor » Normal
FileSize
9.46 KB

Here's a first go at the more comprehensive patch. No longer "minor".

jhodgdon’s picture

Status: Needs work » Needs review
aspilicious’s picture

Status: Needs review » Reviewed & tested by the community

Read through the docs with dreditor.
This is ready to go.

Jhodgdon++

aspilicious’s picture

Status: Reviewed & tested by the community » Needs review

Whoops, reading it again.

 Each response is the return value of the method, just as if it
+ *   has been a local function call, on success, or FALSE on failure

Must there be a "TRUE" before on success?

jhodgdon’s picture

No, it returns the response on success, and FALSE on failure.

aspilicious’s picture

Status: Needs review » Reviewed & tested by the community

Ok, RTBC after all

Dries’s picture

Can we combine all newline patches into one patch, please?

Dries’s picture

Status: Reviewed & tested by the community » Fixed

Committed to CVS HEAD. Thanks.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.