Browse Source

Fix network status when no base dc id in LS

master
Eduard Kuzmenko 4 years ago
parent
commit
55047b6687
  1. 2
      src/components/chat/input.ts
  2. 6
      src/lib/appManagers/appDialogsManager.ts

2
src/components/chat/input.ts

@ -589,7 +589,7 @@ export class ChatInput { @@ -589,7 +589,7 @@ export class ChatInput {
//let str = this.serializeNodes(Array.from(this.messageInput.childNodes));
let str = getRichValue(this.messageInput);
console.log('childnode str after:', str/* , getRichValue(this.messageInput) */);
//console.log('childnode str after:', str/* , getRichValue(this.messageInput) */);
//return;

6
src/lib/appManagers/appDialogsManager.ts

@ -20,7 +20,7 @@ import {MyDialogFilter as DialogFilter} from "../storages/filters"; @@ -20,7 +20,7 @@ import {MyDialogFilter as DialogFilter} from "../storages/filters";
import appPeersManager from './appPeersManager';
import appStateManager from "./appStateManager";
import appUsersManager, { User } from "./appUsersManager";
import { MOUNT_CLASS_TO } from "../mtproto/mtproto_config";
import { App, MOUNT_CLASS_TO } from "../mtproto/mtproto_config";
import Button from "../../components/button";
import SetTransition from "../../components/singleTransition";
import AppStorage from '../storage';
@ -94,6 +94,10 @@ class ConnectionStatusComponent { @@ -94,6 +94,10 @@ class ConnectionStatusComponent {
const setConnectionStatus = () => {
AppStorage.get<number>('dc').then(baseDcID => {
if(!baseDcID) {
baseDcID = App.baseDcID;
}
if(setFirstConnectionTimeout) {
clearTimeout(setFirstConnectionTimeout);
setFirstConnectionTimeout = 0;

Loading…
Cancel
Save