mirror of
https://github.com/apache/zeppelin
synced 2026-05-24 09:38:26 +00:00
check for empty originalText
This commit is contained in:
parent
d2a835f778
commit
8b8c2f9741
2 changed files with 6 additions and 3 deletions
|
|
@ -1073,8 +1073,11 @@ function NotebookCtrl ($scope, $route, $routeParams, $location, $rootScope,
|
|||
let thisScope = angular.element(
|
||||
'#' + par.id + '_paragraphColumn_main').scope()
|
||||
|
||||
if (thisScope.dirtyText !== undefined ||
|
||||
thisScope.dirtyText !== thisScope.originalText) {
|
||||
if (thisScope.dirtyText === undefined ||
|
||||
thisScope.originalText === undefined ||
|
||||
thisScope.dirtyText === thisScope.originalText) {
|
||||
return true
|
||||
} else {
|
||||
event.preventDefault()
|
||||
|
||||
BootstrapDialog.show({
|
||||
|
|
|
|||
|
|
@ -645,7 +645,7 @@ function ResultCtrl ($scope, $rootScope, $route, $window, $routeParams, $locatio
|
|||
}, newParagraphConfig.results[resultIndex], paragraph, resultIndex)
|
||||
renderResult($scope.type, true)
|
||||
} else {
|
||||
websocketMsgSrv.commitParagraph(paragraph.id, title, text, newParagraphConfig, params)
|
||||
return websocketMsgSrv.commitParagraph(paragraph.id, title, text, newParagraphConfig, params)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue