Skip to content

Commit d8fc01c

Browse files
[pre-commit.ci] pre-commit autoupdate
* [pre-commit.ci] pre-commit autoupdate updates: - [github.com/pre-commit/pre-commit-hooks: v2.5.0 → v4.0.1](pre-commit/pre-commit-hooks@v2.5.0...v4.0.1) - [github.com/psf/black: 19.10b0 → 21.10b0](psf/black@19.10b0...21.10b0) - [github.com/asottile/seed-isort-config: v2.1.0 → v2.2.0](asottile-archive/seed-isort-config@v2.1.0...v2.2.0) - https://github.com/pre-commit/mirrors-isorthttps://github.com/PyCQA/isort - [github.com/PyCQA/isort: v4.3.21 → 5.10.0](PyCQA/isort@v4.3.21...5.10.0) - https://gitlab.com/pycqa/flake8https://github.com/PyCQA/flake8 - [github.com/PyCQA/flake8: 3.7.9 → 4.0.1](PyCQA/flake8@3.7.9...4.0.1) * [pre-commit.ci] auto fixes from pre-commit.com hooks
1 parent 8082a9b commit d8fc01c

File tree

4 files changed

+16
-11
lines changed

4 files changed

+16
-11
lines changed

.pre-commit-config.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
exclude: '^tinymce/(static/tinymce|media/tiny_mce|static/.*min.js$)'
44
repos:
55
- repo: https://github.com/pre-commit/pre-commit-hooks
6-
rev: v2.5.0
6+
rev: v4.0.1
77
hooks:
88
- id: check-added-large-files
99
- id: check-ast
@@ -14,24 +14,24 @@ repos:
1414
- id: trailing-whitespace
1515

1616
- repo: https://github.com/psf/black
17-
rev: 19.10b0
17+
rev: 21.10b0
1818
hooks:
1919
- id: black
2020
args: [--exclude=static]
2121

2222
- repo: https://github.com/asottile/seed-isort-config
23-
rev: v2.1.0
23+
rev: v2.2.0
2424
hooks:
2525
- id: seed-isort-config
26-
- repo: https://github.com/pre-commit/mirrors-isort
27-
rev: v4.3.21
26+
- repo: https://github.com/PyCQA/isort
27+
rev: 5.10.0
2828
hooks:
2929
- id: isort
3030
additional_dependencies:
3131
- toml
3232

33-
- repo: https://gitlab.com/pycqa/flake8
34-
rev: 3.7.9
33+
- repo: https://github.com/PyCQA/flake8
34+
rev: 4.0.1
3535
hooks:
3636
- id: flake8
3737
args: [--max-line-length=110]

tests/test_views.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,8 @@ def test_spell_check_unknown_lang(self, enchant_mock):
102102

103103
def test_flatpages_link_list(self):
104104
FlatPage.objects.create(
105-
url="/test/url", title="Test Title",
105+
url="/test/url",
106+
title="Test Title",
106107
)
107108
response = self.client.get("/tinymce/flatpages_link_list/")
108109
result_ok = b'var tinyMCELinkList = [["Test Title", "/test/url"]];'
@@ -137,5 +138,6 @@ def test_filebrowser(self, reverse_mock):
137138
response_ok = response_ok.replace("{{ fb_url }}", "http://testserver/filebrowser")
138139
self.assertEqual(200, response.status_code)
139140
self.assertEqual(
140-
compress_whitespace(response_ok), compress_whitespace(response.content.decode()),
141+
compress_whitespace(response_ok),
142+
compress_whitespace(response.content.decode()),
141143
)

tinymce/compressor.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@ def gzip_compressor(request):
145145
if not response.has_header("Last-Modified"):
146146
response["Last-Modified"] = http_date()
147147
cache.set(
148-
cacheKey, {"Last-Modified": response["Last-Modified"], "ETag": response.get("ETag", "")},
148+
cacheKey,
149+
{"Last-Modified": response["Last-Modified"], "ETag": response.get("ETag", "")},
149150
)
150151
return response

tinymce/settings.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@
3131
)
3232

3333
JS_URL = getattr(
34-
settings, "TINYMCE_JS_URL", os.path.join(settings.STATIC_URL, "tinymce/tinymce.min.js"),
34+
settings,
35+
"TINYMCE_JS_URL",
36+
os.path.join(settings.STATIC_URL, "tinymce/tinymce.min.js"),
3537
)
3638
try:
3739
from django.contrib.staticfiles import finders

0 commit comments

Comments
 (0)