Добавление медиа с форматом jpg
This commit is contained in:
parent
266fa40f61
commit
80ed3c432e
@ -695,6 +695,7 @@ class ApiMedia:
|
|||||||
def __filename_to_ext(filename: str):
|
def __filename_to_ext(filename: str):
|
||||||
formats = {
|
formats = {
|
||||||
".jpeg": "jpeg",
|
".jpeg": "jpeg",
|
||||||
|
".jpg": "jpg",
|
||||||
".png": "png",
|
".png": "png",
|
||||||
".pdf": "pdf"
|
".pdf": "pdf"
|
||||||
}
|
}
|
||||||
@ -707,6 +708,7 @@ class ApiMedia:
|
|||||||
@staticmethod
|
@staticmethod
|
||||||
def __ext_to_content_type(ext: str):
|
def __ext_to_content_type(ext: str):
|
||||||
formats = {
|
formats = {
|
||||||
|
"jpg": "image/jpeg",
|
||||||
"jpeg": "image/jpeg",
|
"jpeg": "image/jpeg",
|
||||||
"png": "image/png",
|
"png": "image/png",
|
||||||
"pdf": "application/pdf"
|
"pdf": "application/pdf"
|
||||||
|
Reference in New Issue
Block a user