Snake case

main
Bob Mottram 2021-12-26 17:29:09 +00:00
parent 43b3a67b11
commit 8b853014c5
3 changed files with 6 additions and 6 deletions

View File

@ -24,7 +24,7 @@ from utils import isPGPEncrypted
from utils import containsPGPPublicKey
from utils import acct_dir
from utils import isfloat
from utils import getCurrencies
from utils import get_currencies
from utils import removeHtml
from petnames import getPetName
from session import downloadImage
@ -1221,7 +1221,7 @@ def limitRepeatedWords(text: str, maxRepeats: int) -> str:
def getPriceFromString(priceStr: str) -> (str, str):
"""Returns the item price and currency
"""
currencies = getCurrencies()
currencies = get_currencies()
for symbol, name in currencies.items():
if symbol in priceStr:
price = priceStr.replace(symbol, '')

View File

@ -3043,7 +3043,7 @@ def isGroupAccount(base_dir: str, nickname: str, domain: str) -> bool:
return False
def getCurrencies() -> {}:
def get_currencies() -> {}:
"""Returns a dictionary of currencies
"""
return {

View File

@ -15,7 +15,7 @@ from utils import getDomainFromActor
from utils import getMediaFormats
from utils import get_config_param
from utils import acct_dir
from utils import getCurrencies
from utils import get_currencies
from utils import get_category_types
from webapp_utils import getBannerFile
from webapp_utils import htmlHeaderWithExternalStyle
@ -482,7 +482,7 @@ def htmlNewPost(cssCache: {}, media_instance: bool, translate: {},
extraFields += '<br>'
extraFields += \
'<label class="labels">' + translate['Currency'] + '</label><br>\n'
currencies = getCurrencies()
currencies = get_currencies()
extraFields += ' <select id="themeDropdown" ' + \
'name="itemCurrency" class="theme">\n'
currencyList = []
@ -547,7 +547,7 @@ def htmlNewPost(cssCache: {}, media_instance: bool, translate: {},
extraFields += '<br>'
extraFields += \
'<label class="labels">' + translate['Currency'] + '</label><br>\n'
currencies = getCurrencies()
currencies = get_currencies()
extraFields += ' <select id="themeDropdown" ' + \
'name="itemCurrency" class="theme">\n'
currencyList = []