Skip to content

Commit a71450e

Browse files
committed
More fixes
1 parent 031eaa4 commit a71450e

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

.pre-commit-config.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ repos:
1212
rev: v2.37.3
1313
hooks:
1414
- id: pyupgrade
15-
args: ["--py38-plus"]
15+
args: ["--py39-plus"]
1616

1717
- repo: https://github.com/adamchainz/django-upgrade
1818
rev: '1.7.0'

aldryn_config.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def to_settings(self, data, settings):
2424
settings.setdefault('MEDIA_HEADERS', []).insert(0, (
2525
r'filer_public(?:_thumbnails)?/.*',
2626
{
27-
'Cache-Control': 'public, max-age={}'.format(86400 * 365),
27+
'Cache-Control': f'public, max-age={86400 * 365}',
2828
},
2929
))
3030

@@ -34,12 +34,12 @@ def to_settings(self, data, settings):
3434
settings['THUMBNAIL_CACHE_DIMENSIONS'] = True
3535

3636
# Swap scale and crop for django-filer version
37-
settings['THUMBNAIL_PROCESSORS'] = tuple([
37+
settings['THUMBNAIL_PROCESSORS'] = tuple(
3838
processor
3939
if processor != 'easy_thumbnails.processors.scale_and_crop'
4040
else 'filer.thumbnail_processors.scale_and_crop_with_subject_location'
4141
for processor in EasyThumbnailSettings.THUMBNAIL_PROCESSORS
42-
])
42+
)
4343

4444
# easy_thumbnails uses django's default storage backend (local file
4545
# system storage) by default, even if the DEFAULT_FILE_STORAGE setting

docs/conf.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757

5858
# General information about the project.
5959
project = 'django-filer'
60-
copyright = '%s, Stefan Foulis' % (datetime.date.today().year,)
60+
copyright = f'{datetime.date.today().year}, Stefan Foulis'
6161

6262
# The version info for the project you're documenting, acts as replacement for
6363
# |version| and |release|, also used in various other places throughout the

0 commit comments

Comments
 (0)