gologin 1.0.28 → 1.0.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/gologin.js +24 -1
- package/package.json +1 -1
package/gologin.js
CHANGED
|
@@ -386,6 +386,8 @@ class GoLogin {
|
|
|
386
386
|
publicIP: _.get(profile, 'webRTC.fillBasedOnIp') ? this._tz.ip : _.get(profile, 'webRTC.publicIp'),
|
|
387
387
|
localIps: _.get(profile, 'webRTC.localIps', []),
|
|
388
388
|
};
|
|
389
|
+
|
|
390
|
+
debug('profile.webRtc=', profile.webRtc);
|
|
389
391
|
|
|
390
392
|
const audioContext = profile.audioContext || {};
|
|
391
393
|
const { mode: audioCtxMode = 'off', noise: audioCtxNoise } = audioContext;
|
|
@@ -563,7 +565,6 @@ class GoLogin {
|
|
|
563
565
|
}
|
|
564
566
|
debug('getTimeZone finish', body.body);
|
|
565
567
|
this._tz = body;
|
|
566
|
-
|
|
567
568
|
return this._tz.timezone;
|
|
568
569
|
}
|
|
569
570
|
|
|
@@ -1110,6 +1111,28 @@ class GoLogin {
|
|
|
1110
1111
|
}
|
|
1111
1112
|
|
|
1112
1113
|
if (profileResponse.body === 'ok') {
|
|
1114
|
+
const profile = await this.getProfile();
|
|
1115
|
+
const { navigator = {}, fonts, os: profileOs } = profile;
|
|
1116
|
+
this.fontsMasking = fonts?.enableMasking;
|
|
1117
|
+
this.profileOs = profileOs;
|
|
1118
|
+
this.differentOs =
|
|
1119
|
+
profileOs !== 'android' && (
|
|
1120
|
+
OS_PLATFORM === 'win32' && profileOs !== 'win' ||
|
|
1121
|
+
OS_PLATFORM === 'darwin' && profileOs !== 'mac' ||
|
|
1122
|
+
OS_PLATFORM === 'linux' && profileOs !== 'lin'
|
|
1123
|
+
);
|
|
1124
|
+
|
|
1125
|
+
const {
|
|
1126
|
+
resolution = '1920x1080',
|
|
1127
|
+
language = 'en-US,en;q=0.9',
|
|
1128
|
+
} = navigator;
|
|
1129
|
+
this.language = language;
|
|
1130
|
+
const [screenWidth, screenHeight] = resolution.split('x');
|
|
1131
|
+
this.resolution = {
|
|
1132
|
+
width: parseInt(screenWidth, 10),
|
|
1133
|
+
height: parseInt(screenHeight, 10),
|
|
1134
|
+
};
|
|
1135
|
+
|
|
1113
1136
|
let wsUrl = await this.waitDebuggingUrl(delay_ms);
|
|
1114
1137
|
return { 'status': 'success', wsUrl }
|
|
1115
1138
|
}
|