mirror of
https://github.com/apache/superset.git
synced 2024-09-17 11:09:47 -04:00
Allowing Leading and Trailing spaces in connection (#3433)
This commit is contained in:
parent
dee47864c4
commit
0280bc52e0
@ -596,7 +596,7 @@ class Database(Model, AuditMixinNullable):
|
||||
return url_copy
|
||||
|
||||
def set_sqlalchemy_uri(self, uri):
|
||||
conn = sqla.engine.url.make_url(uri)
|
||||
conn = sqla.engine.url.make_url(uri.strip())
|
||||
if conn.password != PASSWORD_MASK and not self.custom_password_store:
|
||||
# do not over-write the password with the password mask
|
||||
self.password = conn.password
|
||||
|
@ -18,7 +18,7 @@
|
||||
var data = {};
|
||||
try{
|
||||
data = JSON.stringify({
|
||||
uri: $("#sqlalchemy_uri").val(),
|
||||
uri: $.trim($("#sqlalchemy_uri").val()),
|
||||
name: $('#database_name').val(),
|
||||
impersonate_user: $('#impersonate_user').is(':checked'),
|
||||
extras: JSON.parse($("#extra").val()),
|
||||
|
Loading…
Reference in New Issue
Block a user