diff --git a/public/script.js b/public/script.js index 9ebc97aa6..b3c1f6e6b 100644 --- a/public/script.js +++ b/public/script.js @@ -5610,12 +5610,14 @@ $(document).ready(function () { let thumbURL = $(this).children('img').attr('src'); let charsPath = '/characters/' let targetAvatarImg = thumbURL.substring(thumbURL.lastIndexOf("=") + 1); + let avatarSrc = charsPath + targetAvatarImg; - if ($(this).parent().attr('is_user') == 'true') { //handle user avatars + console.log(avatarSrc); + if ($(this).parent().parent().attr('is_user') == 'true') { //handle user avatars $("#zoomed_avatar").attr('src', thumbURL); - } else if ($(this).parent().attr('is_system') == 'true') { //handle system avatars + } else if ($(this).parent().parent().attr('is_system') == 'true') { //handle system avatars $("#zoomed_avatar").attr('src', thumbURL); - } else if ($(this).parent().attr('is_user') == 'false') { //handle char avatars + } else if ($(this).parent().parent().attr('is_user') == 'false') { //handle char avatars $("#zoomed_avatar").attr('src', avatarSrc); } $('#avatar_zoom_popup').toggle();