mirror of
https://github.com/zulip/zulip.git
synced 2025-11-02 04:53:36 +00:00
migration_0064: Remove usage of Text type.
This commit is contained in:
@@ -2,7 +2,6 @@
|
|||||||
# Generated by Django 1.10.5 on 2017-03-18 12:38
|
# Generated by Django 1.10.5 on 2017-03-18 12:38
|
||||||
|
|
||||||
import os
|
import os
|
||||||
from typing import Text
|
|
||||||
|
|
||||||
from boto.s3.connection import S3Connection
|
from boto.s3.connection import S3Connection
|
||||||
from django.conf import settings
|
from django.conf import settings
|
||||||
@@ -13,7 +12,7 @@ from django.db.migrations.state import StateApps
|
|||||||
class MissingUploadFileException(Exception):
|
class MissingUploadFileException(Exception):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
def get_file_size_local(path_id: Text) -> int:
|
def get_file_size_local(path_id: str) -> int:
|
||||||
file_path = os.path.join(settings.LOCAL_UPLOADS_DIR, 'files', path_id)
|
file_path = os.path.join(settings.LOCAL_UPLOADS_DIR, 'files', path_id)
|
||||||
try:
|
try:
|
||||||
size = os.path.getsize(file_path)
|
size = os.path.getsize(file_path)
|
||||||
|
|||||||
Reference in New Issue
Block a user