https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=29768
--- Comment #9 from Emmi Takkinen <[email protected]> --- (In reply to Joonas Kylmälä from comment #8) > The bug fix to patron-title.inc misses the closing tag for the link "</a>", > thus it produces now invalid HTML. > > It would make more sense to replace > > > [%- IF display_patron_name OR display_cardnumber -%] > > with > > > [%- IF can_see_patron_infos -%] > > also, that would then allow to get rid of the following block above it: > > > [%- IF hide_patron_infos_if_needed %] [%# Should only be set if patron is > > set -%] > > [%- SET can_see_patron_infos = logged_in_user.can_see_patron_infos( > > patron ) -%] > > [%- UNLESS can_see_patron_infos -%] > > [%- SET display_patron_name = 0 -%] > > [%- SET display_cardnumber = 0 -%] > > [%- ELSIF Koha.Preference('HidePatronName') -%] > > [%- SET display_patron_name = 0 -%] > > [%- END -%] > > [%- END -%] > > Then similar bugs to miss a closing HTML tag would be avoided as everything > would be under one if block. > > One more thing: could you please provide the bug fix in patron-title.inc in > a separate commit so if it is needed to fix some other bug and/or we need to > revert the fix you are doing here it would be possible. Weird, patch worked fine even when closing tag was behind > [%- IF hide_patron_infos_if_needed AND ( display_patron_name OR > display_cardnumber ) -%]. And replacing > [%- IF display_patron_name OR display_cardnumber -%] with > [%- IF can_see_patron_infos -%] broke it :D so I don't think that's the best approache to this. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
