mirror of
https://github.com/DoctorMcKay/node-steamcommunity.git
synced 2026-08-19 05:03:28 +08:00
Use custom user agent for logins
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
const {chrome} = require('@doctormckay/user-agents');
|
||||
|
||||
const SteamCommunity = require('../index.js');
|
||||
|
||||
/**
|
||||
@@ -41,7 +43,10 @@ SteamCommunity.prototype._modernLogin = function(logOnDetails) {
|
||||
logOnDetails.disableMobile
|
||||
? EAuthTokenPlatformType.WebBrowser
|
||||
: EAuthTokenPlatformType.MobileApp,
|
||||
{localAddress: this._options.localAddress}
|
||||
{
|
||||
localAddress: this._options.localAddress,
|
||||
userAgent: this._options.userAgent || chrome()
|
||||
}
|
||||
);
|
||||
|
||||
session.on('authenticated', async () => {
|
||||
|
||||
Reference in New Issue
Block a user