mirror of
https://github.com/revanced/revanced-integrations.git
synced 2024-12-01 00:02:55 +01:00
fix requests not sending sometimes
This commit is contained in:
parent
e188b88ad9
commit
a030e6e280
@ -184,6 +184,7 @@ public class Requester {
|
|||||||
String url = SPONSORBLOCK_API_URL + route.compile(params).getCompiledRoute();
|
String url = SPONSORBLOCK_API_URL + route.compile(params).getCompiledRoute();
|
||||||
HttpURLConnection connection = (HttpURLConnection) new URL(url).openConnection();
|
HttpURLConnection connection = (HttpURLConnection) new URL(url).openConnection();
|
||||||
connection.setRequestMethod(route.getMethod().name());
|
connection.setRequestMethod(route.getMethod().name());
|
||||||
|
connection.getInputStream().close(); // this is required so it properly establishes the connection when not reading the InputStream in any of the routes
|
||||||
return connection;
|
return connection;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user