removed test case for private account

This commit is contained in:
cyian-1756 2017-11-08 00:19:55 -05:00
parent 86f7c62213
commit dfab4f6f34

View File

@ -76,8 +76,6 @@ public class InstagramRipper extends AbstractJSONRipper {
try { try {
Document firstPage = Http.url(url).get(); Document firstPage = Http.url(url).get();
for (Element script : firstPage.select("script[type=text/javascript]")) { for (Element script : firstPage.select("script[type=text/javascript]")) {
logger.info("Found script");
if (script.data().contains("window._sharedData = ")) { if (script.data().contains("window._sharedData = ")) {
jsonText = script.data().replaceAll("window._sharedData = ", ""); jsonText = script.data().replaceAll("window._sharedData = ", "");
jsonText = jsonText.replaceAll("};", "}"); jsonText = jsonText.replaceAll("};", "}");
@ -160,7 +158,7 @@ public class InstagramRipper extends AbstractJSONRipper {
break; break;
} }
} }
if (!nextPageID.equals("")) { if (!nextPageID.equals("") && !isThisATest()) {
try { try {
// Sleep for a while to avoid a ban // Sleep for a while to avoid a ban
sleep(2500); sleep(2500);