Fix persona auto-lock to chat not working - When auto lock was enabled, it didn't auto-lock to chat when the persona was already selected (like choosing the same persona you have used before)
| @@ -1464,6 +1464,10 @@ async function loadPersonaForCurrentChat({ doRender = false } = {}) { | |||
| 1464 | toastr.success(message, t`Persona Auto Selected`, { escapeHtml: false }); | 1464 | toastr.success(message, t`Persona Auto Selected`, { escapeHtml: false }); |
| 1465 | } | 1465 | } |
| 1466 | } | 1466 | } |
| 1467 | // Even if it's the same persona, we still might need to auto-lock to chat if that's enabled | ||
| 1468 | else if (chatPersona && power_user.persona_auto_lock && !chat_metadata['persona']) { | ||
| 1469 | lockPersona('chat'); | ||
| 1470 | } | ||
| 1467 | 1471 | ||
| 1468 | updatePersonaUIStates(); | 1472 | updatePersonaUIStates(); |
| 1469 | 1473 | ||