[TikiWiki-commits] [Git][tikiwiki/tiki][master] [FIX] login: Fix display of username when avatar is also "y"

"Jonny Bradley \(@jonnybradley\) via TikiWiki-cvs" <[email protected]> Fri, 17 Jul 2026 15:40:54 +0000
Newsgroups gmane.comp.cms.tiki.cvs
Message-ID <6a5a4d06265b4_3819ceb8568bc@gitlab-sidekiq-low-urgency-cpu-bound-v2-7456c65c79-vlpnd.mail>

Jonny Bradley pushed to branch master at Tiki Wiki CMS Groupware / Tiki


Commits:
8d9f0445 by Jonny Bradley at 2026-07-17T15:22:18+00:00
[FIX] login: Fix display of username when avatar is also "y"
---
* [FIX] login: Restore defaults for show_user_avatar and show_user_name as they are in 27.x (even though the description seems to be incorrect, should be `y/N` or `n/y` to indicate n is the default i reckon)
Let's have a migration script if we're going to change these?
Also from !7557

* [FIX] login: Fix display of username when avatar is also "y" (and fix the default on show_user_name which is y according to the description)
Regression from !7557

See merge request tikiwiki/tiki!10750

- - - - -


2 changed files:

- modules/mod-func-login_box.php
- templates/modules/mod-login_box.tpl


Changes:

=====================================
modules/mod-func-login_box.php
=====================================
@@ -176,7 +176,4 @@ function module_login_box($mod_reference, &$module_params)
     if (! isset($module_params['allowNone'])) {
         $module_params['allowNone'] = 'y';
     }
-    if (! isset($module_params['show_user_avatar'])) {
-        $module_params['show_user_avatar'] = 'y';
-    }
 }


=====================================
templates/modules/mod-login_box.tpl
=====================================
@@ -362,6 +362,7 @@ $('label[for="login-remember-module_{{$module_logo_instance}}"]').on('click', fu
                 {if isset($module_params.show_user_avatar) && $module_params.show_user_avatar eq 'y'}
                     <div class="dropdown-toggle login_link mod-login-avatar" role="button" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
                         {$user|avatarize:n:n:n:n}
+                        {if isset($module_params.show_user_name) || $module_params.show_user_name eq 'y'}{$user|username:n:n:n}{/if}
                     </div>
                 {else}
                     <button type="button" class="dropdown-toggle login_link btn btn-link" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">



View it on GitLab: https://gitlab.com/tikiwiki/tiki/-/commit/8d9f0445b5ebfe7d745f027c6c401909db87a2e7

-- 
View it on GitLab: https://gitlab.com/tikiwiki/tiki/-/commit/8d9f0445b5ebfe7d745f027c6c401909db87a2e7
You're receiving this email because of your account on gitlab.com. Manage all notifications: https://gitlab.com/-/profile/notifications | Help: https://gitlab.com/help

_______________________________________________
TikiWiki-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-cvs