Commit b04deb2b authored by okhin's avatar okhin
Browse files

#5 Fixing some issue. The repr importer now works.

parent 91d1f9aa
Pipeline #107 passed with stage
in 48 seconds
......@@ -36,7 +36,7 @@ class Importer(models.Model):
return 'url'
def representative(self, imported_data):
def representative(self, import_data):
This handle all the representatives data import. The imported_data have all the contacts in
the representative format (and in a list).
......@@ -143,7 +143,7 @@ class Importer(models.Model):
# If it's a file, let's parse it according to our format.
if self.kind() == 'file':
with open(self.file.path, u'rU') as f:
if self.data_format == 'CSV':
if self.category == 'updater':
# If we're a csv format, let's use DictReader on a file object
reader = DictReader(f)
for item in reader:
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment