fixed notebook checking code

v923z 11 years ago
parent ef49e32ef0
commit 9c122dcd15

@ -2195,18 +2195,18 @@ define([
var orig_nbformat_minor = nbmodel.metadata.orig_nbformat_minor;
if (orig_nbformat !== undefined && nbmodel.nbformat !== orig_nbformat) {
var src;
if (nb.nbformat > nb.orig_nbformat) {
if (nbmodel.nbformat > nbmodel.orig_nbformat) {
src = " an older notebook format ";
} else {
src = " a newer notebook format ";
}
var msg = "This notebook has been converted from" + src +
"(v"+nb.orig_nbformat+") to the current notebook " +
"format (v"+nb.nbformat+"). The next time you save this notebook, the " +
"(v"+nbmodel.orig_nbformat+") to the current notebook " +
"format (v"+nbmodel.nbformat+"). The next time you save this notebook, the " +
"current notebook format will be used.";
if (nb.nbformat > nb.orig_nbformat) {
if (nbmodel.nbformat > nbmodel.orig_nbformat) {
msg += " Older versions of IPython may not be able to read the new format.";
} else {
msg += " Some features of the original notebook may not be available.";

Loading…
Cancel
Save