diff --git a/src/bot/helpers/handleMissingGameLicenses.js b/src/bot/helpers/handleMissingGameLicenses.js index 3f73deef..d0b72c61 100644 --- a/src/bot/helpers/handleMissingGameLicenses.js +++ b/src/bot/helpers/handleMissingGameLicenses.js @@ -4,7 +4,7 @@ * Created Date: 29.06.2023 21:31:53 * Author: 3urobeat * - * Last Modified: 14.10.2023 10:35:38 + * Last Modified: 25.12.2023 22:12:16 * Modified By: 3urobeat * * Copyright (c) 2023 3urobeat @@ -27,7 +27,7 @@ Bot.prototype.handleMissingGameLicenses = function() { // Check if user provided games specifically for this account. We only need to check this for child accounts let configChildGames = data.config.childaccplayinggames; - if (typeof configChildGames[0] == "object") { + if (typeof configChildGames[0] == "object" && configChildGames[0] != null) { // - typeof null == "object" if (Object.keys(configChildGames[0]).includes(this.loginData.logOnOptions.accountName)) configChildGames = configChildGames[0][this.loginData.logOnOptions.accountName]; // Get the specific settings for this account if included else configChildGames = configChildGames.slice(1); // ...otherwise remove object containing acc specific settings to use the generic ones @@ -40,7 +40,7 @@ Bot.prototype.handleMissingGameLicenses = function() { let options = { includePlayedFreeGames: true, - filterAppids: this.index == 0 ? data.config.playinggames.filter(e => !isNaN(e)) : configChildGames.filter(e => !isNaN(e)), // We only need to check for these appIDs. Filter custom game string + filterAppids: this.index == 0 ? data.config.playinggames.filter(e => !isNaN(e)) : configChildGames.filter(e => !isNaN(e) && e != null), // We only need to check for these appIDs. Filter custom game string and null values includeFreeSub: false }; @@ -94,4 +94,4 @@ Bot.prototype.handleMissingGameLicenses = function() { startPlaying(); } -}; \ No newline at end of file +}; diff --git a/src/data/fileStructure.json b/src/data/fileStructure.json index da1631d7..9af16be5 100644 --- a/src/data/fileStructure.json +++ b/src/data/fileStructure.json @@ -358,7 +358,7 @@ { "path": "src/bot/helpers/handleMissingGameLicenses.js", "url": "https://raw.githubusercontent.com/3urobeat/steam-comment-service-bot/beta-testing/src/bot/helpers/handleMissingGameLicenses.js", - "checksum": "841bf2256855624b39a5370a67c09bc0" + "checksum": "a2f8b1267bc2cda3bc2b5a0281fd9b52" }, { "path": "src/bot/helpers/handleRelog.js",