Skip to content

Commit 224c3cc

Browse files
committed
Return values for functions with return type
Rather than calling pass and letting the function end and returning None implicitly, which is considered bad style if the function can return an explicit value elsewhere.
1 parent 59b04ce commit 224c3cc

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/scyjava/_convert.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -789,7 +789,7 @@ def _is_table(obj: Any) -> bool:
789789
return jinstance(obj, "org.scijava.table.Table")
790790
except BaseException:
791791
# No worries if scijava-table is not available.
792-
pass
792+
return False
793793

794794

795795
def _convert_table(obj: Any):
@@ -798,7 +798,7 @@ def _convert_table(obj: Any):
798798
return _table_to_pandas(obj)
799799
except BaseException:
800800
# No worries if scijava-table is not available.
801-
pass
801+
return None
802802

803803

804804
def _import_pandas(required=True):

0 commit comments

Comments
 (0)