mirror of
https://github.com/searxng/searxng
synced 2024-01-01 19:24:07 +01:00
fix: storage unit value
This commit is contained in:
parent
d669da81fb
commit
0a346b7175
1 changed files with 8 additions and 6 deletions
|
@ -39,12 +39,14 @@ _ECMA_UNESCAPE4_RE = re.compile(r'%u([0-9a-fA-F]{4})', re.UNICODE)
|
||||||
_ECMA_UNESCAPE2_RE = re.compile(r'%([0-9a-fA-F]{2})', re.UNICODE)
|
_ECMA_UNESCAPE2_RE = re.compile(r'%([0-9a-fA-F]{2})', re.UNICODE)
|
||||||
|
|
||||||
_STORAGE_UNIT_VALUE: Dict[str, int] = {
|
_STORAGE_UNIT_VALUE: Dict[str, int] = {
|
||||||
'TB': 1024 * 1024 * 1024 * 1024,
|
'TB': 1000 * 1000 * 1000 * 1000,
|
||||||
'GB': 1024 * 1024 * 1024,
|
'GB': 1000 * 1000 * 1000,
|
||||||
'MB': 1024 * 1024,
|
'MB': 1000 * 1000,
|
||||||
'TiB': 1000 * 1000 * 1000 * 1000,
|
'kB': 1000,
|
||||||
'MiB': 1000 * 1000,
|
'TiB': 1024 * 1024 * 1024 * 1024,
|
||||||
'KiB': 1000,
|
'GiB': 1024 * 1024 * 1024,
|
||||||
|
'MiB': 1024 * 1024,
|
||||||
|
'KiB': 1024,
|
||||||
}
|
}
|
||||||
|
|
||||||
_XPATH_CACHE: Dict[str, XPath] = {}
|
_XPATH_CACHE: Dict[str, XPath] = {}
|
||||||
|
|
Loading…
Add table
Reference in a new issue