Zend Framework

directMessageMessages and directMessageSent do not use rest params

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Critical Critical
  • Resolution: Fixed
  • Affects Version/s: 1.7.3
  • Fix Version/s: 1.7.5
  • Component/s: Zend_Service_Twitter
  • Labels:
    None

Description

/**

  • Retrieve direct messages for the current user
    *
  • $params may include one or more of the following keys
  • - since: return results only after the date specified
  • - since_id: return statuses only greater than the one specified
  • - page: return page X of results
    *
  • @param array $params
  • @return Zend_Rest_Client_Result
    */
    public function directMessageMessages(array $params = array())
    {
    $this->_init();
    $path = '/direct_messages.xml';
    $_params = array();
    foreach ($params as $key => $value)
    Unknown macro: { switch (strtolower($key)) { case 'since': $this->_setDate($value); break; case 'since_id': $this->since_id = (int) $value; break; case 'page': $this->page = (int) $value; break; default: break; } }

    $response = $this->restGet($path,$_params);
    return new Zend_Rest_Client_Result($response->getBody());
    }

/**

  • Retrieve list of direct messages sent by current user
    *
  • $params may include one or more of the following keys
  • - since: return results only after the date specified
  • - since_id: return statuses only greater than the one specified
  • - page: return page X of results
    *
  • @param array $params
  • @return Zend_Rest_Client_Result
    */
    public function directMessageSent(array $params = array())
    {
    $this->_init();
    $path = '/direct_messages/sent.xml';
    foreach ($params as $key => $value)
    Unknown macro: { switch (strtolower($key)) { case 'since': $this->_setDate($value); break; case 'since_id': $this->since_id = (int) $value; break; case 'page': $this->page = (int) $value; break; default: break; } }

    $response = $this->restGet($path);
    return new Zend_Rest_Client_Result($response->getBody());
    }

Activity

Hide
akira added a comment -

a piece of the amended code

Show
akira added a comment - a piece of the amended code
Hide
Jon Whitcraft added a comment -

If you post a patch file this can get fixed faster. I will look at once a proper patch file is submitted.

Show
Jon Whitcraft added a comment - If you post a patch file this can get fixed faster. I will look at once a proper patch file is submitted.
Hide
Satoru Yoshida added a comment -

Solved in SVN r13857

Show
Satoru Yoshida added a comment - Solved in SVN r13857
Hide
Satoru Yoshida added a comment -

I think statusFriendsTimeline() and favoriteFavorites() have also same problem, and I fixed.

I changed as following.

$this->page to $_params['page']

$this->since_id to $_params['since_id']

and adds second parameter to restGet() if needed.

Show
Satoru Yoshida added a comment - I think statusFriendsTimeline() and favoriteFavorites() have also same problem, and I fixed. I changed as following. $this->page to $_params['page'] $this->since_id to $_params['since_id'] and adds second parameter to restGet() if needed.
Hide
Satoru Yoshida added a comment -

Sorry, not in 1.7.4. please wait.

Show
Satoru Yoshida added a comment - Sorry, not in 1.7.4. please wait.
Hide
Jon Whitcraft added a comment -

Reopening insue since it was not fixed in the trunk.

Show
Jon Whitcraft added a comment - Reopening insue since it was not fixed in the trunk.
Hide
Jon Whitcraft added a comment -

When you posted this to trunk did you also merge it into the 1.7 branch?

Show
Jon Whitcraft added a comment - When you posted this to trunk did you also merge it into the 1.7 branch?
Hide
Jon Whitcraft added a comment -

This was merged into the 1.7 release branch with r13994

Show
Jon Whitcraft added a comment - This was merged into the 1.7 release branch with r13994

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved:

Time Tracking

Estimated:
Not Specified
Original Estimate - Not Specified
Remaining:
0m
Remaining Estimate - 0 minutes
Logged:
40m
Time Spent - 40 minutes