fixed problem with OAuth login and reply_id

This commit is contained in:
Jeena Paradies 2010-05-10 09:00:11 +02:00
parent dd0991c316
commit dff8d4a1a6
3 changed files with 13 additions and 10 deletions

View file

@ -167,8 +167,10 @@
- (IBAction)sendTweet:(id)sender {
NSString *replyToId;
if ([[[sender object] objectAtIndex:1] respondsToSelector:@selector(stringValue:)]) {
if (![[[sender object] objectAtIndex:1] isEqualTo:@""]) {
replyToId = [[[sender object] objectAtIndex:1] stringValue];
}

13
OAuth.m
View file

@ -89,10 +89,11 @@
- (void)requestAccessTokenWithPIN:(id)sender {
[twitterPINPanel resignKeyWindow];
[twitterPINPanel close];
NSLog(@"%@", [twitterPINField stringValue]);
NSURL *url = [NSURL URLWithString:[NSString stringWithFormat:@"%@?oauth_verifier=%@", OAUTH_ACCESS_TOKEN_URL, [twitterPINField stringValue]]];
[twitterPINPanel resignKeyWindow];
[twitterPINPanel close];
OAMutableURLRequest *request = [[OAMutableURLRequest alloc] initWithURL:url
consumer:consumer
@ -125,13 +126,7 @@
}
}
- (void)apiTicket:(OAServiceTicket *)ticket didFinishWithData:(NSData *)data {
if (ticket.didSucceed) {
NSString *responseBody = [[NSString alloc] initWithData:data
encoding:NSUTF8StringEncoding];
NSLog(@"%@", responseBody);
}
}
- (void)accessTokenTicket:(OAServiceTicket *)ticket didFailWithError:(NSError *)error {
NSLog(@"ERROR a: %@", error);

View file

@ -19,6 +19,12 @@
<hr />
<h1>Twittia 2.1.2</h1>
<p>Added icon</p>
<p>Fixed problem where you press "a" and a new tweet window opens</p>
<hr />
<h1>Twittia 2.1.1</h1>
<p>Added possibility to change the hotkey in defaults.</p>
<p>Added a notice to the timeline window how many unread mentions there are.</p>