send admin token

This commit is contained in:
harid 2025-10-06 10:33:21 +07:00
parent cd9c1721c1
commit bb13a34dfa

View file

@ -1536,7 +1536,7 @@ export class CommandController extends Controller {
_profile.lastUpdatedAt = _Date;
if (_profile.keycloak != null && _profile.keycloak != "") {
// console.log("4. disable keycloak/authen")
const delUserKeycloak = await deleteUser(_profile.keycloak);
const delUserKeycloak = await deleteUser(_profile.keycloak, adminToken);
if (delUserKeycloak) {
_profile.keycloak = "";
_profile.roleKeycloaks = [];
@ -1589,7 +1589,7 @@ export class CommandController extends Controller {
_profileEmp.lastUpdatedAt = _Date;
if (_profileEmp.keycloak != null && _profileEmp.keycloak != "") {
// disable keycloak/authen
const delUserKeycloak = await deleteUser(_profileEmp.keycloak);
const delUserKeycloak = await deleteUser(_profileEmp.keycloak, adminToken);
if (delUserKeycloak) {
_profileEmp.keycloak = "";
_profileEmp.roleKeycloaks = [];