bookreader
bookreader copied to clipboard
Handle invalid JSON in search result responses
The search endpoint can sometimes error and return invalid JSON. The search plugin should be resilient to this. Note that it is making a JSONP request, so invalid JSON in this case would result in invalid JS, meaning jquery's callback won't be called, so it might not be possible to handle this, but it might be the case that the onerror event on the <script> is forwarded by jQuery? Some investigation needed.