Use Webogram credentials
This commit is contained in:
parent
e40d913ef9
commit
8f7a791f9f
@ -173,14 +173,14 @@ export class AppSidebarLeft extends SidebarSlider {
|
||||
onClick: () => {
|
||||
location.href = 'https://web.telegram.org/z/';
|
||||
},
|
||||
verify: () => location.hostname === 'web.telegram.org'
|
||||
verify: () => App.isMainDomain
|
||||
}, {
|
||||
icon: 'char w',
|
||||
text: 'ChatList.Menu.SwitchTo.Webogram',
|
||||
onClick: () => {
|
||||
location.href = 'https://web.telegram.org/';
|
||||
},
|
||||
verify: () => location.hostname === 'web.telegram.org'
|
||||
verify: () => App.isMainDomain
|
||||
}];
|
||||
|
||||
this.toolsBtn = ButtonMenuToggle({}, 'bottom-right', menuButtons, (e) => {
|
||||
@ -201,7 +201,7 @@ export class AppSidebarLeft extends SidebarSlider {
|
||||
btnMenuFooter.classList.add('btn-menu-footer');
|
||||
const t = document.createElement('span');
|
||||
t.classList.add('btn-menu-footer-text');
|
||||
t.innerHTML = 'Telegram WebK alpha ' + App.version;
|
||||
t.innerHTML = 'Telegram Web' + App.suffix + ' alpha ' + App.version;
|
||||
btnMenuFooter.append(t);
|
||||
btnMenu.classList.add('has-footer');
|
||||
btnMenu.append(btnMenuFooter);
|
||||
|
@ -17,7 +17,14 @@ const App = {
|
||||
langPack: 'macos',
|
||||
langPackCode: 'en',
|
||||
domains: [] as string[],
|
||||
baseDcId: 2
|
||||
baseDcId: 2,
|
||||
isMainDomain: location.hostname === 'web.telegram.org',
|
||||
suffix: 'K'
|
||||
};
|
||||
|
||||
if(App.isMainDomain) { // use Webogram credentials then
|
||||
App.id = 2496;
|
||||
App.hash = '8da85b0d5bfe62527e5b244c209159c3';
|
||||
}
|
||||
|
||||
export default App;
|
||||
|
@ -304,7 +304,7 @@ export default class MTPNetworker {
|
||||
serializer.storeInt(App.id, 'api_id');
|
||||
serializer.storeString(navigator.userAgent || 'Unknown UserAgent', 'device_model');
|
||||
serializer.storeString(navigator.platform || 'Unknown Platform', 'system_version');
|
||||
serializer.storeString(App.version, 'app_version');
|
||||
serializer.storeString(App.version + (App.isMainDomain ? ' ' + App.suffix : ''), 'app_version');
|
||||
serializer.storeString(navigator.language || 'en', 'system_lang_code');
|
||||
serializer.storeString(App.langPack, 'lang_pack');
|
||||
serializer.storeString(navigator.language || 'en', 'lang_code');
|
||||
|
Loading…
Reference in New Issue
Block a user