Skip to content
This repository has been archived by the owner on Jun 8, 2018. It is now read-only.

If response is json: #6

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

If response is json: #6

wants to merge 1 commit into from

Conversation

likoo
Copy link

@likoo likoo commented May 16, 2011

scrape: function (data) {
try {
var json = eval("(" + data + ')')
}
catch(e) {
return false;
}
if (json.data && json.data.status == 'OK')
return json.data.content;
else
return false;
}

scrape: function (data) {
  try {
    var json = eval("(" + data + ')')
  }
  catch(e) {
    return false;
  }
  if (json.data && json.data.status == 'OK')
    return json.data.content;
  else
    return false;
}
@jney jney closed this Mar 26, 2013
@jney jney reopened this Mar 28, 2013
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants