steamutils 1.1.10 → 1.1.12

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.
@@ -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$/.tmp" />
6
5
  <excludeFolder url="file://$MODULE_DIR$/temp" />
6
+ <excludeFolder url="file://$MODULE_DIR$/.tmp" />
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="" vcs="Git" />
4
+ <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
5
  </component>
6
6
  </project>
package/SteamClient.js CHANGED
@@ -10,7 +10,6 @@ import {fileURLToPath} from "url";
10
10
  import path from "path";
11
11
  import SteamUtils from "./index.js";
12
12
  import {v4 as uuidv4} from 'uuid';
13
- import { steamID } from 'steam-user/components/helpers.js'
14
13
 
15
14
  const __filename = fileURLToPath(import.meta.url);
16
15
  const __dirname = path.dirname(__filename);
@@ -239,7 +238,7 @@ function SteamClient({
239
238
  }
240
239
 
241
240
  async function getPersonas(steamIDs) {
242
- steamIDs = steamIDs.map(steamID => steamID instanceof SteamID ? steamID.getSteamID64() : steamID)
241
+ steamIDs = steamIDs.map(steamId => steamId instanceof SteamID ? steamId.getSteamID64() : steamId)
243
242
  const notCachesteamIDs = steamIDs.filter(id => !PersonasCache.some(p => p.id == id))
244
243
  const cachedPersonas = PersonasCache.filter(p => steamIDs.includes(p.id))
245
244
 
@@ -845,7 +844,7 @@ function SteamClient({
845
844
  const timestamp = new Date(data.server_timestamp).getTime()
846
845
  const steamId = data.steamid_friend.getSteamID64()
847
846
  const personas = await getPersonas([steamId])
848
- const player_name = personas.find(p => p.id == steamID)?.player_name || ''
847
+ const player_name = personas.find(p => p.id == steamId)?.player_name || ''
849
848
  log('friendMessage', data)
850
849
  const invite = [`Inited you to play a game!`, `Đã mời bạn chơi một trò chơi!`].includes(data.message_no_bbcode || data.message)
851
850
 
@@ -859,9 +858,9 @@ function SteamClient({
859
858
 
860
859
  });
861
860
 
862
- steamClient.on('friendTyping', async function (steamID, message) {
861
+ steamClient.on('friendTyping', async function (steamId, message) {
863
862
  callEvent(events.friendTyping, {
864
- steamID, message
863
+ steamId, message
865
864
  })
866
865
  });
867
866
 
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "steamutils",
3
- "version": "1.1.10",
3
+ "version": "1.1.12",
4
+ "main":"index.js",
4
5
  "dependencies": {
5
6
  "axios": "^1.3.4",
6
7
  "cheerio": "^1.0.0-rc.12",
@@ -1,5 +0,0 @@
1
- <component name="ProjectCodeStyleConfiguration">
2
- <state>
3
- <option name="USE_PER_PROJECT_SETTINGS" value="true" />
4
- </state>
5
- </component>