File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
notebook/static/notebook/js Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ define(function (require) {
88 "use strict" ;
99 var IPython = require ( 'base/js/namespace' ) ;
1010 var $ = require ( 'jquery' ) ;
11+ var _ = require ( 'underscore' ) ;
1112 var utils = require ( 'base/js/utils' ) ;
1213 var dialog = require ( 'base/js/dialog' ) ;
1314 var cellmod = require ( 'notebook/js/cell' ) ;
@@ -245,7 +246,7 @@ define(function (require) {
245246 display_name : data . spec . display_name ,
246247 language : data . spec . language ,
247248 } ;
248- if ( ! existing_spec || JSON . stringify ( existing_spec ) != JSON . stringify ( that . metadata . kernelspec ) ) {
249+ if ( ! existing_spec || ! _ . isEqual ( existing_spec , that . metadata . kernelspec ) ) {
249250 that . set_dirty ( true ) ;
250251 }
251252 // start session if the current session isn't already correct
@@ -263,7 +264,7 @@ define(function (require) {
263264 var existing_info = that . metadata . language_info ;
264265 var langinfo = kinfo . language_info ;
265266 that . metadata . language_info = langinfo ;
266- if ( ! existing_info || JSON . stringify ( existing_info ) != JSON . stringify ( langinfo ) ) {
267+ if ( ! existing_info || ! _ . isEqual ( existing_info , langinfo ) ) {
267268 that . set_dirty ( true ) ;
268269 }
269270 // Mode 'null' should be plain, unhighlighted text.
You can’t perform that action at this time.
0 commit comments