Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Editing a comment within Blacklist/Whitelist that contains apostrophe symbol (') gets changed to ' after confirming #2279

Open
DinoBrdar92 opened this issue Aug 1, 2022 · 2 comments

Comments

@DinoBrdar92
Copy link

Versions

  • Pi-hole: v5.11.4
  • AdminLTE: v5.13
  • FTL: v5.16.1

Platform

  • OS and version: Windows 10 Education x64 21H2
  • Platform: Raspberry Pi 4 model B

Expected behavior

Writing a comment within Blacklist/Whitelist with an apostrophe (') should have an apostrophe after confirming my comment

Actual behavior / bug

Writing a comment within Blacklist/Whitelist that contains apostrophe (') gets changed to ' after confirming

Steps to reproduce

Steps to reproduce the behavior:

  1. Go to 'Blacklist or Whitelist'
  2. Edit comment of any of the entries (add an entry first if there's none) and write ' in it
  3. Click anywhere to confirm editing
  4. See error: ' should change to '

Debug Token

Screenshots

Screenshot from Reddit post here

@yubiuser yubiuser added the Bug label Aug 1, 2022
@andrewmccarthy
Copy link

Comparing groups-adlists.php and groups-domains.php they both seem to work the same. Also, in both cases they store an apostrophe in the database as '. The difference is at lines 520-522 at script/.../groups.php, where for get_domains the comment and domain fields are passed through htmlentities() (thus turning ' into '), but for get_adlists they aren't.

@yubiuser
Copy link
Member

Will be fixed by #2851 in v6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants