Skip to content

Commit

Permalink
Allow tweet to be an array of params
Browse files Browse the repository at this point in the history
  • Loading branch information
textagroup committed Feb 19, 2015
1 parent e5d7ad1 commit 078f447
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion code/SSTwitter.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,12 @@ public function getTweets($count = 1, $retweet = false, $screenName = null) {
* @param string $tweet The tweet to send
*/
public function sendTweet($tweet) {
$params['status'] = $tweet;
if (is_array($tweet)) {
$params = $tweet;
} else {
$params['status'] = $tweet;
}
$reply = $this->cb->statuses_update($params);
return $reply;
}
}

0 comments on commit 078f447

Please sign in to comment.