mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-02-03 04:37:40 +01:00
Fix prompt manager sometimes erroring in groups with null members
This commit is contained in:
parent
059647b286
commit
1305f9dc4c
@ -825,7 +825,7 @@ PromptManagerModule.prototype.handleGroupSelected = function (event) {
|
||||
*/
|
||||
PromptManagerModule.prototype.getActiveGroupCharacters = function() {
|
||||
// ToDo: Ideally, this should return the actual characters.
|
||||
return (this.activeCharacter?.group?.members || []).map(member => member.substring(0, member.lastIndexOf('.')));
|
||||
return (this.activeCharacter?.group?.members || []).map(member => member && member.substring(0, member.lastIndexOf('.')));
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user