title: RestKit 0.20.2 Routing and mapping
body: <p>I have the following JSON and routing mapping for it also follows. 
  Single Item JSON</p>
  
  <pre><code>{
  "quantity" : 0,
  "id" : 1,
  "version" : 0,
  "sku" : "sku1",
  "title" : "title1",
  }
  </code></pre>
  
  <p>and all Items JSON is as follows:-</p>
  
  <pre><code>[
      {
      "quantity" : 2,
      "id" : 1,
      "version" : 0,
      "sku" : "sku1",
      "title" : "title1",
      },
      {
      "quantity" : 4,
      "id" : 2,
      "version" : 0,
      "sku" : "sku2",
      "title" : "title2",
      }
  ]
  </code></pre>
  
  <p>Here are the mappings:-</p>
  
  <pre><code>RKEntityMapping *newItemMapping = [RKEntityMapping mappingForEntityForName:NSStringFromClass([Item class]) inManagedObjectStore:manager.managedObjectStore];
  newItemMapping.identificationAttributes = @[@"id"];
  [newItemMapping addAttributeMappingsFromDictionary:@{
          @"id" : @"id",
          @"version" : @"version",
          @"title" : @"title",
          @"sku" : @"sku"
  }];
  </code></pre>
  
  <p>Here is the routing info.</p>
  
  <pre><code>[[RKObjectManager sharedManager].router.routeSet addRoute:[RKRoute routeWithClass:[Item class] pathPattern:@"items/:id" method:RKRequestMethodGET]];
  [[RKObjectManager sharedManager].router.routeSet addRoute:[RKRoute routeWithClass:[Item class] pathPattern:@"items" method:RKRequestMethodPOST]];
  [[RKObjectManager sharedManager].router.routeSet addRoute:[RKRoute routeWithClass:[Item class] pathPattern:@"items/:id" method:RKRequestMethodPUT]];
  [[RKObjectManager sharedManager].router.routeSet addRoute:[RKRoute routeWithClass:[Item class] pathPattern:@"items/:id" method:RKRequestMethodDELETE]];
  </code></pre>
  
  <p>The GET request works fine and loads the object correctly using above mapping.</p>
  
  <pre><code>[[RKObjectManager sharedManager] getObject:sampleItemObject path:nil parameters:nil success:^(RKObjectRequestOperation *operation, RKMappingResult *mappingResult) {
      RKLogInfo(@"Load collection of Items: %@", mappingResult);
  }                                         failure:^(RKObjectRequestOperation *operation, NSError *error) {
      RKLogError(@"Operation failed with error: %@", error);
  }];
  </code></pre>
  
  <p>But the POST request fails with the message shown below:- </p>
  
  <pre><code>[[RKObjectManager sharedManager] postObject:newItem path:nil parameters:nil success:^(RKObjectRequestOperation *operation, RKMappingResult *mappingResult) {
      NSLog(@"%@", mappingResult.array);
  }                                             failure:^(RKObjectRequestOperation *operation, NSError *error) {
      NSLog(@"Failure saving post: %@", error.localizedDescription);
  }];
  </code></pre>
  
  <p>Error message:-</p>
  
  <p>Failure saving post: Expected content type {(
      "application/x-www-form-urlencoded",
      "application/json"
  )}, got text/html</p>
  
  <p>Please assist in fixing whatever is going wrong? </p>
  
  <p>Thanks,
  Foki</p>