FronterAS/elasticsearch-wrapper — pull request #12 by michaelenger (2014-05-20 13:08:31+00:00)
Title: Fix malformed results crashing the app

If `adaptResult` received an object which didn't have a `fields` or `_source` property, which could be the result of attempting to retrieve a document which doesn't exist, it would throw an error on line #29 which could crash the app.

This way it just sends the malformed through, letting whomever requested the document deal with it.