Skip to content

Commit

Permalink
Merge pull request #21 from Brobin/django_19
Browse files Browse the repository at this point in the history
Django 1.9
  • Loading branch information
Brobin committed Feb 5, 2016
2 parents 6a64f98 + 4be1ca1 commit 0a0d3aa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
language: python
python:
- "2.7"
- "3.2"
- "3.3"
- "3.4"
- "3.5"
env:
- DJANGO=1.7 DRF=3.1
- DJANGO=1.7 DRF=3.2
- DJANGO=1.8 DRF=3.1
- DJANGO=1.8 DRF=3.2
- DJANGO=1.9 DRF=3.2
- DJANGO=1.9 DRF=3.3
matrix:
exclude:
- python: "3.5"
Expand All @@ -24,4 +24,4 @@ install:
before_script:
- "pep8 drf_generators --exclude=templates && cd tests"
script:
- python manage.py test
- python manage.py test
4 changes: 2 additions & 2 deletions drf_generators/management/commands/generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@ def handle_app_config(self, app_config, **options):
views = options['views'] if 'views' in options else False
urls = options['urls'] if 'urls' in options else False

elif django.VERSION[1] == 8:
elif django.VERSION[1] >= 8:
force = options['force']
format = options['format']
depth = options['depth']
serializers = options['serializers']
views = options['views']
urls = options['urls']
else:
raise CommandError('You must be using Django 1.7 or 1.8')
raise CommandError('You must be using Django 1.7, 1.8 or 1.9')

if format == 'viewset':
generator = ViewSetGenerator(app_config, force)
Expand Down

0 comments on commit 0a0d3aa

Please sign in to comment.