[openstreetmap/openstreetmap-website] Get the value of the text node to unescape it (PR #3765)

Brian DeRocher notifications at github.com
Sun Oct 23 20:07:52 UTC 2022


get_text("reversegeocode/result") returns an XML text node.  We want to get the value of that node.

This will un-escape ' into an apostrophe.

All callers of this function will later re-encode it depending out output whether it be HTML in an email, or XML in an RSS feed.

* app/mailers/user_mail.rb
* app/helpers/geocode_helper.rb
* app/views/api/notes/feed.rss.builder
* app/views/api/notes/_note.rss.builder

Fixes openstreetmap/openstreetmap-website#3761
You can view, comment on, or merge this pull request online at:

  https://github.com/openstreetmap/openstreetmap-website/pull/3765

-- Commit Summary --

  * get_text("reversegeocode/result") returns an XML node.  We want to get the text value of that node.

-- File Changes --

    M lib/nominatim.rb (2)

-- Patch Links --

https://github.com/openstreetmap/openstreetmap-website/pull/3765.patch
https://github.com/openstreetmap/openstreetmap-website/pull/3765.diff

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/3765
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/3765 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20221023/f405bf68/attachment.htm>


More information about the rails-dev mailing list