steamutils 1.1.91 → 1.1.93

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.
@@ -0,0 +1,5 @@
1
+ <component name="ProjectCodeStyleConfiguration">
2
+ <state>
3
+ <option name="USE_PER_PROJECT_SETTINGS" value="true" />
4
+ </state>
5
+ </component>
@@ -2,8 +2,8 @@
2
2
  <module type="WEB_MODULE" version="4">
3
3
  <component name="NewModuleRootManager">
4
4
  <content url="file://$MODULE_DIR$">
5
- <excludeFolder url="file://$MODULE_DIR$/temp" />
6
5
  <excludeFolder url="file://$MODULE_DIR$/.tmp" />
6
+ <excludeFolder url="file://$MODULE_DIR$/temp" />
7
7
  <excludeFolder url="file://$MODULE_DIR$/tmp" />
8
8
  </content>
9
9
  <orderEntry type="inheritedJdk" />
package/.idea/vcs.xml CHANGED
@@ -1,6 +1,6 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
2
  <project version="4">
3
3
  <component name="VcsDirectoryMappings">
4
- <mapping directory="$PROJECT_DIR$" vcs="Git" />
4
+ <mapping directory="" vcs="Git" />
5
5
  </component>
6
6
  </project>
package/index.js CHANGED
@@ -1072,7 +1072,7 @@ class SteamUser {
1072
1072
 
1073
1073
  static async getUserFriendListByWebApiKey(webApiKey, steamId) {
1074
1074
  const response = await request(`http://api.steampowered.com/ISteamUser/GetFriendList/v0001/?key=${webApiKey}&steamid=${steamId}&relationship=friend`);
1075
- return response.data.friendslist.friends.map(({steamid}) => steamid) || []
1075
+ return response?.data?.friendslist?.friends?.map?.(({steamid}) => steamid) || []
1076
1076
  const resultExample = ["76561198112239954", "76561199239548264", "76561199446829671"]
1077
1077
  }
1078
1078
 
@@ -1597,7 +1597,7 @@ class SteamUser {
1597
1597
  break
1598
1598
  }
1599
1599
  case 429: {
1600
- console.log('Too Many Requests', config.url)
1600
+ console.log(`[${config.method?.toUpperCase()}] Too Many Requests`, config.url)
1601
1601
  tooManyRequestTimestamp = new Date().getTime()
1602
1602
  checkTooManyRequest = true
1603
1603
  await sleep(30000)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "steamutils",
3
- "version": "1.1.91",
3
+ "version": "1.1.93",
4
4
  "main": "index.js",
5
5
  "dependencies": {
6
6
  "axios": "^1.3.4",