From f4072164a40a45e087198089d3748406c96cf8a7 Mon Sep 17 00:00:00 2001 From: Deryck Hodge Date: Thu, 6 Apr 2017 12:03:11 -0500 Subject: [PATCH] Fall back to enum34 in serialzer. --- sqlalchemy_jsonapi/serializer.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sqlalchemy_jsonapi/serializer.py b/sqlalchemy_jsonapi/serializer.py index 9fb694f..fd33e64 100644 --- a/sqlalchemy_jsonapi/serializer.py +++ b/sqlalchemy_jsonapi/serializer.py @@ -4,7 +4,11 @@ Colton J. Provias MIT License """ -from enum import Enum + +try: + from enum import Enum +except ImportError: + from enum34 import Enum from inflection import dasherize, tableize, underscore from sqlalchemy.exc import IntegrityError