diff options
| author | Christophe Simonis <chs@odoo.com> | 2019-03-21 13:58:37 +0100 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2019-03-21 13:58:37 +0100 |
| commit | 4eff0af02ef2c182793fce5f32d2d15f53a5fba7 (patch) | |
| tree | 8790e0051f631240562a9408ccd5e2a5cd64782b /addons/website/static/src/js | |
| parent | 45e3e432a3621cf03a38ce48562eb967f1ff76e0 (diff) | |
| parent | 6878c9f3424f27df9b07a665f9c0f5ef6e254996 (diff) | |
[MERGE] forward port branch saas-12.1 up to 6878c9f3424
Diffstat (limited to 'addons/website/static/src/js')
| -rw-r--r-- | addons/website/static/src/js/editor/snippets.options.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/website/static/src/js/editor/snippets.options.js b/addons/website/static/src/js/editor/snippets.options.js index f51dda964db..078bccc9f42 100644 --- a/addons/website/static/src/js/editor/snippets.options.js +++ b/addons/website/static/src/js/editor/snippets.options.js @@ -642,11 +642,11 @@ var FacebookPageDialog = weWidgets.Dialog.extend({ */ _renderPreview: function () { var self = this; - var match = this.fbData.href.match(/^(?:https?:\/\/)?(?:www\.)?(?:fb|facebook)\.com\/(\w+)/); + var match = this.fbData.href.match(/^(?:https?:\/\/)?(?:www\.)?(?:fb|facebook)\.com\/(?:([\w.]+)|[^/?#]+-([0-9]{15,16}))(?:$|[\/?# ])/); if (match) { // Check if the page exists on Facebook or not $.ajax({ - url: 'https://graph.facebook.com/' + match[1] + '/picture', + url: 'https://graph.facebook.com/' + (match[2] || match[1]) + '/picture', statusCode: { 200: function () { self._toggleWarning(true); |
