From ae9071b27d6bab03bcae6b124185e3188d2bcc99 Mon Sep 17 00:00:00 2001 From: thepaperpilot Date: Fri, 16 Feb 2024 03:51:46 +0000 Subject: [PATCH] Pass galaxy object to onLoggedIn cb --- galaxy.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/galaxy.js b/galaxy.js index fc00f92..251f7f8 100644 --- a/galaxy.js +++ b/galaxy.js @@ -113,7 +113,7 @@ * @param {boolean} [options.supportsSaving] - Indicates to Galaxy that this game supports saving. Defaults to false. * @param {boolean} [options.supportsSaveManager] - Indicates to Galaxy that this game supports a saves manager. Defaults to false. * @param {boolean} [options.ignoreApiVersion] - Ignores the api_version property received from Galaxy. By default this value is false, meaning if an unknown API version is encountered, the API will fail to initialize. - * @param {(loggedIn: boolean) => void} [options.onLoggedInChanged] - A callback for when the logged in status of the player changes after the initialization. + * @param {(galaxy: GalaxyApi) => void} [options.onLoggedInChanged] - A callback for when the logged in status of the player changes after the initialization. * @returns {Promise} */ export function initGalaxy({ @@ -203,7 +203,7 @@ export function initGalaxy({ if (firstInfoResponse) { accept(galaxy); } else { - galaxy.onLoggedInChanged?.(logged_in); + galaxy.onLoggedInChanged?.(galaxy); } } break;