Permalink
Browse files

Merged changes.

Signed-off-by: Alexander Repty <arepty@wernstrom.(none)>
  • Loading branch information...
2 parents 4f9f583 + 58b1eb1 commit df29a75c3d208655c04120170e182bc7d4607574 Alexander Repty committed Apr 5, 2010
Showing with 14 additions and 7 deletions.
  1. +1 −1 AppController.m
  2. +13 −6 MGTwitterStatusesParser.m
View
@@ -38,7 +38,7 @@ - (void)applicationDidFinishLaunching:(NSNotification *)aNotification
#define TESTING_ID 1131604824
#define TESTING_PRIMARY_USER @"gnitset"
- #define TESTING_SECONDARY_USER @"justin"
+ #define TESTING_SECONDARY_USER @"chockenberry"
#define TESTING_MESSAGE_ID 52182684
// Status methods:
View
@@ -32,11 +32,16 @@ - (void)parser:(NSXMLParser *)theParser didStartElement:(NSString *)elementName
NSMutableDictionary *newNode = [NSMutableDictionary dictionaryWithCapacity:0];
[currentNode setObject:newNode forKey:elementName];
currentNode = newNode;
+ } else if ([elementName isEqualToString:@"place"]) {
+ // Add a 'place' dictionary to current node.
+ NSMutableDictionary *newNode = [NSMutableDictionary dictionaryWithCapacity:0];
+ [currentNode setObject:newNode forKey:elementName];
+ currentNode = newNode;
} else if ([elementName isEqualToString:@"retweeted_status"]) {
- // Add a 'retweet_status' dictionary to current node.
- NSMutableDictionary *newNode = [NSMutableDictionary dictionaryWithCapacity:0];
- [currentNode setObject:newNode forKey:elementName];
- currentNode = newNode;
+ // Add a 'retweet_status' dictionary to current node.
+ NSMutableDictionary *newNode = [NSMutableDictionary dictionaryWithCapacity:0];
+ [currentNode setObject:newNode forKey:elementName];
+ currentNode = newNode;
} else if (currentNode) {
// Create relevant name-value pair.
[currentNode setObject:[NSMutableString string] forKey:elementName];
@@ -61,11 +66,13 @@ - (void)parser:(NSXMLParser *)theParser didEndElement:(NSString *)elementName
if ([elementName isEqualToString:@"user"]) {
currentNode = [parsedObjects lastObject];
+ } else if ([elementName isEqualToString:@"place"]) {
+ currentNode = [parsedObjects lastObject];
+ } else if ([elementName isEqualToString:@"retweeted_status"]) {
+ currentNode = [parsedObjects lastObject];
} else if ([elementName isEqualToString:@"status"]) {
[self addSource];
currentNode = nil;
- } else if ([elementName isEqualToString:@"retweeted_status"]){
- currentNode = [parsedObjects lastObject];
}
}

0 comments on commit df29a75

Please sign in to comment.