forked from shaba/openuds
Merge remote-tracking branch 'origin/v3.5'
This commit is contained in:
commit
a2e5e00aa6
@ -138,7 +138,7 @@ class Transports(ModelHandler):
|
||||
),
|
||||
'type': 'text',
|
||||
'order': 201,
|
||||
'tab': gui.ADVANCED_TAB,
|
||||
'tab': ugettext(gui.ADVANCED_TAB),
|
||||
},
|
||||
)
|
||||
|
||||
|
@ -319,8 +319,8 @@ class HTML5RDPTransport(transports.Transport):
|
||||
def initialize(self, values: 'Module.ValuesType'):
|
||||
if not values:
|
||||
return
|
||||
# Strip spaces
|
||||
self.guacamoleServer.value = self.guacamoleServer.value.strip()
|
||||
# Strip spaces and all trailing '/'
|
||||
self.guacamoleServer.value = self.guacamoleServer.value.strip().rstrip('/')
|
||||
if self.guacamoleServer.value[0:4] != 'http':
|
||||
raise transports.Transport.ValidationException(
|
||||
_('The server must be http or https')
|
||||
|
@ -179,7 +179,8 @@ class HTML5VNCTransport(transports.Transport):
|
||||
if not values:
|
||||
return
|
||||
# Strip spaces
|
||||
self.guacamoleServer.value = self.guacamoleServer.value.strip()
|
||||
# Remove trailing / (one or more) from url if it exists from "guacamoleServer" field
|
||||
self.guacamoleServer.value = self.guacamoleServer.value.strip().rstrip('/')
|
||||
if self.guacamoleServer.value[0:4] != 'http':
|
||||
raise transports.Transport.ValidationException(
|
||||
_('The server must be http or https')
|
||||
|
Loading…
Reference in New Issue
Block a user