-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Variable Explorer: Fix error when viewing DataFrame with no rows
Fixes #2791
- Loading branch information
1 parent
ba5c735
commit 336a8fc
Showing
1 changed file
with
3 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Now that I see this,
Should we have some style guide to avoid having returns in the middle of a method?
I know sometimes it is maybe the best choice, but in general I think having multiple forks inside a method do not help with readability. In these cases either the method is too large and has to be decomposed in smaller routines or, the result should be captured in a variable and returned at the end of the method.
In this particular case is weird that we return to escape a method that actually does not return anything by default. An if wrapping the whole functionality or just the part that makes the max_r and min_r calculations....
Food for thought...