mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Ensure port and username should not be mandatory when a service is provided. Fixes #4642
This commit is contained in:
@@ -723,9 +723,8 @@ class ServerNode(PGChildNodeView):
|
||||
"""Add a server node to the settings database"""
|
||||
required_args = [
|
||||
u'name',
|
||||
u'port',
|
||||
u'db',
|
||||
u'sslmode',
|
||||
u'username'
|
||||
]
|
||||
|
||||
data = request.form if request.form else json.loads(
|
||||
@@ -741,7 +740,8 @@ class ServerNode(PGChildNodeView):
|
||||
if 'service' in data and not data['service']:
|
||||
required_args.extend([
|
||||
u'host',
|
||||
u'db',
|
||||
u'port',
|
||||
u'username',
|
||||
u'role'
|
||||
])
|
||||
for arg in required_args:
|
||||
|
||||
Reference in New Issue
Block a user