mirror of
https://github.com/samuelclay/NewsBlur.git
synced 2025-09-18 21:50:56 +00:00
fixed a crash when sharing a story from the social feed that wasn't
shared by a friend (and set the source user to the non-friend who shared it, if possible)
This commit is contained in:
parent
9a52f7015a
commit
7e808bd7d8
1 changed files with 4 additions and 3 deletions
|
@ -338,9 +338,10 @@
|
|||
}
|
||||
|
||||
if (appDelegate.isSocialRiverView) {
|
||||
if ([appDelegate.activeStory objectForKey:@"friend_user_ids"] != nil) {
|
||||
NSString *sourceUserIdStr = [NSString stringWithFormat:@"%@", [[appDelegate.activeStory objectForKey:@"friend_user_ids"] objectAtIndex:0]];
|
||||
[request setPostValue:sourceUserIdStr forKey:@"source_user_id"];
|
||||
if ([[appDelegate.activeStory objectForKey:@"friend_user_ids"] count] > 0) {
|
||||
[request setPostValue:[NSString stringWithFormat:@"%@", [appDelegate.activeStory objectForKey:@"friend_user_ids"][0]] forKey:@"source_user_id"];
|
||||
} else if ([[appDelegate.activeStory objectForKey:@"public_user_ids"] count] > 0) {
|
||||
[request setPostValue:[NSString stringWithFormat:@"%@", [appDelegate.activeStory objectForKey:@"public_user_ids"][0]] forKey:@"source_user_id"];
|
||||
}
|
||||
} else {
|
||||
if ([appDelegate.activeStory objectForKey:@"social_user_id"] != nil) {
|
||||
|
|
Loading…
Add table
Reference in a new issue