diff options
| author | Jeremy Kersten <jke@odoo.com> | 2018-02-15 15:15:29 +0100 |
|---|---|---|
| committer | Jeremy Kersten <jke@odoo.com> | 2018-02-15 16:01:45 +0100 |
| commit | 665496fc5c00f212ee8425bc95b987d42b3b0c37 (patch) | |
| tree | ac6d89fa0d3454e3d0dc3cd47c442afd35824c66 /addons/website_forum/controllers | |
| parent | 1550c27b84542993af66b533ac45c8692c17a43f (diff) | |
[FIX] website_forum: fix 'submit a link' feature
The pooling of the title was wrong since P3 refactoring.
Diffstat (limited to 'addons/website_forum/controllers')
| -rw-r--r-- | addons/website_forum/controllers/main.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/website_forum/controllers/main.py b/addons/website_forum/controllers/main.py index 94043cdb0b0..ac84166d528 100644 --- a/addons/website_forum/controllers/main.py +++ b/addons/website_forum/controllers/main.py @@ -225,9 +225,9 @@ class WebsiteForum(http.Controller): @http.route('/forum/get_url_title', type='json', auth="user", methods=['POST'], website=True) def get_url_title(self, **kwargs): try: - req = requests.get(kwargs.get('url'), stream=True) + req = requests.get(kwargs.get('url')) req.raise_for_status() - arch = lxml.html.parse(req.raw) + arch = lxml.html.fromstring(req.content) return arch.find(".//title").text except IOError: return False |
