Skip to content

Commit

Permalink
Small cleanup based on python-babel#45
Browse files Browse the repository at this point in the history
  • Loading branch information
EnTeQuAk committed May 7, 2019
1 parent c60a307 commit dbc1137
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions django_babel/extract.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# -*- coding: utf-8 -*-
from django.template.base import Lexer
try:
from django.template.base import Lexer, TOKEN_TEXT, TOKEN_VAR, TOKEN_BLOCK
except ImportError:
# Django 2.1+
from django.template.base import Lexer, TokenType

from django.template.base import TokenType
except ImportError: # django < 2.1
from django.template.base import TOKEN_TEXT, TOKEN_VAR, TOKEN_BLOCK
else:
TOKEN_TEXT = TokenType.TEXT
TOKEN_VAR = TokenType.VAR
TOKEN_BLOCK = TokenType.BLOCK
Expand Down

0 comments on commit dbc1137

Please sign in to comment.