Skip to content

Commit

Permalink
Return the notebook when no conversion is needed (#221)
Browse files Browse the repository at this point in the history
The bare return statement returns None by default. If nothing is to be upgraded, the original notebook should be returned.
  • Loading branch information
bryanwweber authored May 18, 2021
1 parent 373d926 commit dd4725f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nbformat/v4/convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ def upgrade(nb, from_version=None, from_minor=None):
return nb
elif from_version == 4:
if from_minor == nbformat_minor:
return
return nb

# other versions migration code e.g.
# if from_minor < 3:
Expand Down

0 comments on commit dd4725f

Please sign in to comment.