fix default expressions

This commit is contained in:
RossAscends 2023-07-21 06:06:00 +09:00
parent cda78d3cf0
commit e2c7f770e4
1 changed files with 8 additions and 7 deletions

View File

@ -789,19 +789,20 @@ async function setExpression(character, expression, force) {
setDefault();
}
});
} else {
if (extension_settings.expressions.showDefault) {
setDefault();
}
}
} else {
if (extension_settings.expressions.showDefault) {
setDefault();
}
}
function setDefault() {
console.debug('setting default');
const defImgUrl = `/img/default-expressions/${expression}.png`;
//console.log(defImgUrl);
expressionClone.attr('src', defImgUrl);
expressionClone.addClass('default');
console.log(defImgUrl);
img.attr('src', defImgUrl);
img.addClass('default');
}
document.getElementById("expression-holder").style.display = '';
}