Skip to content
This repository was archived by the owner on Apr 1, 2026. It is now read-only.

Commit a63f377

Browse files
committed
Merge pull request #18 from sakshityagi/master
Set data.content.openInApp field to null in case datastore save is called from CP.
2 parents b0503fe + 4eaf5c0 commit a63f377

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

control/content/app.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,8 @@ webviewPluginApp.controller("webviewPluginCtrl", ["$scope", "$log", "$timeout",
8383
if (!/^https?\:\/\//.test(data.content.url)) {
8484
data.content.url = "http://" + data.content.url;
8585
}
86-
86+
if (data.content.openInApp != 'undefined')
87+
data.content.openInApp = null;
8788
buildfire.datastore.save(data, function (err, result) {
8889
if (err || !result) {
8990
$log.error('Error saving the widget details: ', err);
@@ -103,6 +104,8 @@ webviewPluginApp.controller("webviewPluginCtrl", ["$scope", "$log", "$timeout",
103104
dataChanged = true;
104105
if (!$scope.frmMain.$invalid) {
105106
var data = $scope.data;
107+
if (data.content.openInApp != 'undefined')
108+
data.content.openInApp = null;
106109
buildfire.datastore.save(data, function (err, result) {
107110
if (err || !result) {
108111
$log.error('Error saving the widget details: ', err);

0 commit comments

Comments
 (0)