diff --git a/blog.py b/blog.py
index 9b8870fc3..6e2d151c4 100644
--- a/blog.py
+++ b/blog.py
@@ -25,7 +25,7 @@ from utils import is_account_dir
from utils import remove_html
from utils import get_config_param
from utils import get_full_domain
-from utils import getMediaFormats
+from utils import get_media_formats
from utils import getNicknameFromActor
from utils import getDomainFromActor
from utils import locate_post
@@ -814,7 +814,7 @@ def htmlEditBlog(media_instance: bool, translate: {},
editBlogImageSection += \
' '
+ ' accept="' + get_media_formats() + '">'
editBlogImageSection += ' '
placeholderMessage = translate['Write something'] + '...'
diff --git a/utils.py b/utils.py
index acea66eeb..48196bd80 100644
--- a/utils.py
+++ b/utils.py
@@ -426,7 +426,7 @@ def isImageFile(filename: str) -> bool:
return False
-def getMediaFormats() -> str:
+def get_media_formats() -> str:
"""Returns a string of permissable media formats
used when selecting an attachment for a new post
"""
@@ -459,15 +459,15 @@ def remove_html(content: str) -> str:
elif not removing:
result += ch
- plainText = result.replace(' ', ' ')
+ plain_text = result.replace(' ', ' ')
# insert spaces after full stops
- strLen = len(plainText)
+ strLen = len(plain_text)
result = ''
for i in range(strLen):
- result += plainText[i]
- if plainText[i] == '.' and i < strLen - 1:
- if plainText[i + 1] >= 'A' and plainText[i + 1] <= 'Z':
+ result += plain_text[i]
+ if plain_text[i] == '.' and i < strLen - 1:
+ if plain_text[i + 1] >= 'A' and plain_text[i + 1] <= 'Z':
result += ' '
result = result.replace(' ', ' ').strip()
diff --git a/webapp_create_post.py b/webapp_create_post.py
index ed6a86f13..3d7861f27 100644
--- a/webapp_create_post.py
+++ b/webapp_create_post.py
@@ -12,7 +12,7 @@ from utils import get_new_post_endpoints
from utils import isPublicPostFromUrl
from utils import getNicknameFromActor
from utils import getDomainFromActor
-from utils import getMediaFormats
+from utils import get_media_formats
from utils import get_config_param
from utils import acct_dir
from utils import get_currencies
@@ -361,7 +361,7 @@ def htmlNewPost(cssCache: {}, media_instance: bool, translate: {},
newPostImageSection += \
'