farhan678 / adwhirl

Automatically exported from code.google.com/p/adwhirl
0 stars 0 forks source link

AdmobGoogleAdsense adaptor crashes when keywords method is implemented in the delegate #240

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Implement keywords method from the Adwhirl delegate. AdmobGoogleAdsense adaptor 
crashes.

Issue is the in the following line of code. Delegate expects a string to be 
returned by adaptor is assuming a nsarray -

Original 

  if ((value = [self delegateValueForSelector:@selector(keywords)])) {
    request.keywords = [NSMutableArray arrayWithArray:(NSArray*)value];
  }

Fixed ---
  if ((value = [self delegateValueForSelector:@selector(keywords)])) {
    request.keywords = [NSMutableArray arrayWithArray:[(NSString*)value componentsSeparatedByString:@","]];
  }

Original issue reported on code.google.com by aagarwa...@gmail.com on 12 Jul 2011 at 11:03