mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Use null coalescing operator
This commit is contained in:
@ -5927,7 +5927,7 @@ export async function getChatsFromFiles(data, isGroupChat) {
|
||||
* in descending order by file name. Returns `undefined` if the fetch request is unsuccessful.
|
||||
*/
|
||||
export async function getPastCharacterChats(characterId = null) {
|
||||
characterId = characterId || this_chid;
|
||||
characterId = characterId ?? this_chid;
|
||||
if (!characters[characterId]) return [];
|
||||
|
||||
const response = await fetch('/api/characters/chats', {
|
||||
|
Reference in New Issue
Block a user