diff --git a/drf_tools/serializers.py b/drf_tools/serializers.py index 68c875d..88cdd36 100644 --- a/drf_tools/serializers.py +++ b/drf_tools/serializers.py @@ -76,7 +76,8 @@ def deserialize(file_bytes): @staticmethod def __validate_cell(cell): cell = str(cell) if cell is not None else '' - if "\t" in cell or "\n" in cell: + if "\t" in cell or "\n" in cell or '"' in cell: + cell = cell.replace('"', '""') cell = '"{}"'.format(cell) return cell diff --git a/setup.py b/setup.py index c00e399..444b718 100644 --- a/setup.py +++ b/setup.py @@ -3,7 +3,7 @@ setup( name='drf-tools', - version="0.9.11", + version="0.9.12", url='https://github.com/seebass/drf-tools', license='MIT', description='Multiple extensions and test utilities for Django REST Framework 3',