In "add trusted domain" options use version without www.
This commit is contained in:
parent
f38feb05a8
commit
38a41123db
@ -468,6 +468,7 @@ class SyncplayClient(object):
|
|||||||
self.fileSwitchFoundFiles()
|
self.fileSwitchFoundFiles()
|
||||||
self.ui.showMessage("Trusted domains updated")
|
self.ui.showMessage("Trusted domains updated")
|
||||||
# TODO: Properly add message for setting trusted domains!
|
# TODO: Properly add message for setting trusted domains!
|
||||||
|
# TODO: Handle cases where users add www. to start of domain
|
||||||
|
|
||||||
def isUntrustedTrustableURI(self, URIToTest):
|
def isUntrustedTrustableURI(self, URIToTest):
|
||||||
if utils.isURL(URIToTest):
|
if utils.isURL(URIToTest):
|
||||||
|
|||||||
@ -252,7 +252,10 @@ def convertMultilineStringToList(multilineString):
|
|||||||
|
|
||||||
def getDomainFromURL(URL):
|
def getDomainFromURL(URL):
|
||||||
try:
|
try:
|
||||||
return URL.split("//")[-1].split("/")[0]
|
URL = URL.split("//")[-1].split("/")[0]
|
||||||
|
if URL.startswith("www."):
|
||||||
|
URL = URL[4:]
|
||||||
|
return URL
|
||||||
except:
|
except:
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user