Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[processing] fixed handling of None param values in ogr2ogrtopostgis.py
  • Loading branch information
volaya committed Oct 17, 2016
1 parent 589a217 commit a63805a
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions python/plugins/processing/algs/gdal/ogr2ogrtopostgis.py
Expand Up @@ -154,17 +154,17 @@ def defineCharacteristics(self):
self.tr('Additional creation options'), '', optional=True))

def getConnectionString(self):
host = unicode(self.getParameterValue(self.HOST))
port = unicode(self.getParameterValue(self.PORT))
user = unicode(self.getParameterValue(self.USER))
dbname = unicode(self.getParameterValue(self.DBNAME))
password = unicode(self.getParameterValue(self.PASSWORD))
schema = unicode(self.getParameterValue(self.SCHEMA))
host = self.getParameterValue(self.HOST)
port = self.getParameterValue(self.PORT)
user = self.getParameterValue(self.USER)
dbname = self.getParameterValue(self.DBNAME)
password = self.getParameterValue(self.PASSWORD)
schema = self.getParameterValue(self.SCHEMA)
arguments = []
if host:
arguments.append('host=' + host)
if port:
arguments.append('port=' + port)
arguments.append('port=' + str(port))
if dbname:
arguments.append('dbname=' + dbname)
if password:
Expand Down

0 comments on commit a63805a

Please sign in to comment.