From 1dc84549bc5451cb22e65d783871a64b3173ff6b Mon Sep 17 00:00:00 2001 From: tabarra Date: Sun, 31 Dec 2023 12:57:55 -0300 Subject: [PATCH] fix: cfx.re login not working in some cases The issue affected only admins which forum username does not match the admin name in txAdmin. --- core/webroutes/authentication/providerCallback.ts | 2 +- fxmanifest.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/webroutes/authentication/providerCallback.ts b/core/webroutes/authentication/providerCallback.ts index 83069b2b9..687eaa890 100644 --- a/core/webroutes/authentication/providerCallback.ts +++ b/core/webroutes/authentication/providerCallback.ts @@ -61,7 +61,7 @@ export default async function AuthProviderCallback(ctx: InitializedCtx) { //Setting session const sessData = { type: 'cfxre', - username: userInfo.name, + username: vaultAdmin.name, csrfToken: ctx.txAdmin.adminVault.genCsrfToken(), expiresAt: Date.now() + 86_400_000, //24h, identifier: fivemIdentifier, diff --git a/fxmanifest.lua b/fxmanifest.lua index 1ea155c52..7f3816d3a 100644 --- a/fxmanifest.lua +++ b/fxmanifest.lua @@ -5,7 +5,7 @@ author 'Tabarra' description 'Remotely Manage & Monitor your GTA5 FiveM Server' repository 'https://github.com/tabarra/txAdmin' -version '7.0.0-beta1' +version '7.0.0-beta2-dev' ui_label 'txAdmin' rdr3_warning 'I acknowledge that this is a prerelease build of RedM, and I am aware my resources *will* become incompatible once RedM ships.'