mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2024-08-30 18:23:09 +00:00
Fix bug where no file error doesn't show up
This commit is contained in:
parent
8bad0fb0a9
commit
3840cc3863
@ -7,6 +7,7 @@ from jsonschema.exceptions import ValidationError
|
||||
from app.classes.models.crafty_permissions import EnumPermissionsCrafty
|
||||
from app.classes.shared.helpers import Helpers
|
||||
from app.classes.web.base_api_handler import BaseApiHandler
|
||||
from app.classes.web.websocket_handler import WebSocketManager
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
files_get_schema = {
|
||||
@ -73,7 +74,7 @@ class ApiImportFilesIndexHandler(BaseApiHandler):
|
||||
else:
|
||||
if user_id:
|
||||
user_lang = self.controller.users.get_user_lang_by_id(user_id)
|
||||
self.helper.websocket_helper.broadcast_user(
|
||||
WebSocketManager().broadcast_user(
|
||||
user_id,
|
||||
"send_start_error",
|
||||
{
|
||||
@ -85,7 +86,7 @@ class ApiImportFilesIndexHandler(BaseApiHandler):
|
||||
else:
|
||||
if not self.helper.check_path_exists(folder) and user_id:
|
||||
user_lang = self.controller.users.get_user_lang_by_id(user_id)
|
||||
self.helper.websocket_helper.broadcast_user(
|
||||
WebSocketManager().broadcast_user(
|
||||
user_id,
|
||||
"send_start_error",
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user