add request timeout publicip

This commit is contained in:
LBlend committed 2022-11-17 18:23:00 +01:00
1 parent 8a143260ee
commit 911b695924
1 file changed
+1 -1
+1 -1
View File
@@ -96,7 +96,7 @@ class DevTools(commands.Cog):
@commands.command()
async def publicip(self, ctx: commands.Context):
"""Sends WAN IP-address. inb4 I leak my IP-address"""
data = requests.get('https://wtfismyip.com/json').json()
data = requests.get('https://wtfismyip.com/json', timeout=10).json()
ip = data['YourFuckingIPAddress']
location = data['YourFuckingLocation']
isp = data['YourFuckingISP']