From 85adbd138336826b7250640f369698e099fd4ae1 Mon Sep 17 00:00:00 2001 From: discopatrick Date: Thu, 20 Apr 2017 13:36:31 +0100 Subject: [PATCH] =?UTF-8?q?gives=20variable=20the=20better=20name=20of=20?= =?UTF-8?q?=E2=80=98ordinal=E2=80=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- beets/dbcore/query.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/beets/dbcore/query.py b/beets/dbcore/query.py index 0ed5f8935..13aca762d 100644 --- a/beets/dbcore/query.py +++ b/beets/dbcore/query.py @@ -553,7 +553,7 @@ class Period(object): """ if not string: return None - count = 0 + ordinal = 0 date = None for date_format in cls.date_formats: try: @@ -561,11 +561,11 @@ class Period(object): break except ValueError: # Parsing failed. - count += 1 + ordinal += 1 if date is None: raise InvalidQueryArgumentTypeError(string, 'a valid datetime string') - precision = cls.precisions[count] + precision = cls.precisions[ordinal] return cls(date, precision) def open_right_endpoint(self):