mirror of
https://github.com/moraroy/NonSteamLaunchers-On-Steam-Deck.git
synced 2024-12-21 15:21:52 +01:00
more fixes
~more fixes towards urls
This commit is contained in:
parent
3c4ebaac62
commit
470a741987
@ -2961,6 +2961,7 @@ print(sys.path) # Add this line to print the value of sys.path
|
||||
import vdf # Updated import
|
||||
import binascii
|
||||
import re
|
||||
from urllib.parse import quote
|
||||
|
||||
|
||||
# Print the path to the file where the vdf module was loaded from
|
||||
@ -3111,6 +3112,9 @@ for custom_website in custom_websites:
|
||||
# Remove any leading or trailing spaces from the custom website URL
|
||||
custom_website = custom_website.strip()
|
||||
|
||||
# Encode the URL to replace special characters with their percent-encoded equivalents
|
||||
custom_website = quote(custom_website, safe=':/')
|
||||
|
||||
# Remove the 'http://' or 'https://' prefix and the 'www.' prefix, if present
|
||||
clean_website = custom_website.replace('http://', '').replace('https://', '').replace('www.', '')
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user