8000 OAuth: force_login, screen_name support by miteshashar · Pull Request #14 · jublo/codebird-php · GitHub
[go: up one dir, main page]

Skip to content

OAuth: force_login, screen_name support #14

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Apr 12, 2013
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Adhering it to PEAR standards, as suggested. Updated issue #14
  • Loading branch information
miteshashar committed Apr 9, 2013
commit b6481a633771fde00a9c0c4ba73ccee5ce768fce
12 changes: 6 additions & 6 deletions src/codebird.php
Original file line number Diff line number Diff line change
Expand Up @@ -280,14 +280,14 @@ public function __call($fn, $params)
*
* @return string The OAuth authenticate URL
*/
public function oauth_authenticate( $force_login = NULL, $screen_name = NULL )
public function oauth_authenticate($force_login = NULL, $screen_name = NULL)
{
if ($this->_oauth_token == null) {
throw new Exception('To get the authenticate URL, the OAuth token must be set.');
}
$url = self::$_endpoint_oauth . 'oauth/authenticate?oauth_token=' . $this->_url($this->_oauth_token);
if( $force_login ) $url .= "&force_login=1";
if( $screen_name ) $url .= "&screen_name=" . $screen_name;
if($force_login) $url .= "&force_login=1";
if($screen_name) $url .= "&screen_name=" . $screen_name;
return $url;
}

Expand All @@ -296,14 +296,14 @@ public function oauth_authenticate( $force_login = NULL, $screen_name = NULL )
*
* @return string The OAuth authorize URL
*/
public function oauth_authorize( $force_login = NULL, $screen_name = NULL )
public function oauth_authorize($force_login = NULL, $screen_name = NULL)
{
if ($this->_oauth_token == null) {
throw new Exception('To get the authorize URL, the OAuth token must be set.');
}
$url = self::$_endpoint_oauth . 'oauth/authorize?oauth_token=' . $this->_url($this->_oauth_token);
if( $force_login ) $url .= "&force_login=1";
if( $screen_name ) $url .= "&screen_name=" . $screen_name;
if($force_login) $url .= "&force_login=1";
if($screen_name) $url .= "&screen_name=" . $screen_name;
return $url;
}

Expand Down
0