2
0
mirror of https://github.com/xcat2/confluent.git synced 2024-11-25 11:01:09 +00:00

Fix incorrect variable name in nodediscover

The field name was incorrectly referencing the last field
rather than the current.
This commit is contained in:
Jarrod Johnson 2018-11-02 15:50:02 -04:00
parent 78e7381442
commit f5f9403eff

View File

@ -140,13 +140,13 @@ def import_csv(options, session):
for datum in record:
currfield = currfields.pop(0)
if currfield in unique_fields:
if datum in unique_data[field]:
if datum in unique_data[currfield]:
sys.stderr.write(
"Import contains duplicate values "
"({0} with value {1}\n".format(currfield, datum)
)
sys.exit(1)
unique_data[field].add(datum)
unique_data[currfield].add(datum)
nodedatum[currfield] = datum
if not datum_complete(nodedatum):
sys.exit(1)