Commit 81533d4 1 parent 6977025 commit 81533d4 Copy full SHA for 81533d4
File tree 1 file changed +9
-1
lines changed
src/main/java/com/rarchives/ripme/ripper/rippers
1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change 10
10
import java .net .URISyntaxException ;
11
11
import java .net .URL ;
12
12
import java .util .ArrayList ;
13
+ import java .util .HashMap ;
13
14
import java .util .List ;
15
+ import java .util .Map ;
14
16
import java .util .regex .Matcher ;
15
17
import java .util .regex .Pattern ;
16
18
17
19
import org .apache .commons .lang .StringUtils ;
20
+ import org .jsoup .Jsoup ;
18
21
import org .jsoup .nodes .Document ;
19
22
import org .jsoup .nodes .Element ;
20
23
import org .jsoup .select .Elements ;
@@ -128,7 +131,12 @@ public void run() {
128
131
*/
129
132
private void fetchImage () {
130
133
try {
131
- Document doc = Http .url (url ).get ();
134
+ Map <String , String > cookies = new HashMap <>();
135
+ cookies .put ("nsfw_inter" , "1" );
136
+ Document doc = Jsoup .connect (url .toString ())
137
+ .cookies (cookies )
138
+ .get ();
139
+
132
140
// Find image
133
141
Elements metaTags = doc .getElementsByTag ("meta" );
134
142
You can’t perform that action at this time.
0 commit comments