Permalink
Browse files

render Hosts to comma separated list

  • Loading branch information...
1 parent c5d2e3e commit b0b3a43a7bc3c9938d36845417b1564499c937a0 @gpitfield committed Mar 24, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 django_mongodb_engine/base.py
@@ -132,8 +132,8 @@ def pop(name, default=None):
try:
if 'replicaSet' in options:
- port = port if port else 27017
- host_or_uri = ['%s:%s'%(h, port) for h in host]
+ port = port or 27017
+ host_or_uri = ','.join(['%s:%s'%(h, port) for h in host])
self.connection = ReplicaSetConnection(host_or_uri, **options)
else:
self.connection = Connection(host=host, port=port, **options)

0 comments on commit b0b3a43

Please sign in to comment.