From 9c1cbba163fb907a44264038c5fbb0d10c324a91 Mon Sep 17 00:00:00 2001 From: Alexey Stoletniy Date: Wed, 8 Feb 2017 13:30:49 +0300 Subject: [PATCH] Fix 'Create a new form' link on widgets page having no feedback [MAILPOET-691] --- lib/Form/Widget.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Form/Widget.php b/lib/Form/Widget.php index 6caa4db161..70c37e2211 100644 --- a/lib/Form/Widget.php +++ b/lib/Form/Widget.php @@ -79,9 +79,9 @@ class Widget extends \WP_Widget { endpoint: 'forms', action: 'create' }).done(function(response) { - if(response.result && response.form_id) { + if(response.data && response.data.id) { window.location = - "" + response.form_id; + "" + response.data.id; } }); return false;