Skip to content

Commit

Permalink
fix fexpr.cc
Browse files Browse the repository at this point in the history
  • Loading branch information
samukweku committed Mar 12, 2023
1 parent 21226cc commit 67890c5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/core/expr/fexpr.cc
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,8 @@ DECLARE_METHOD(&PyFExpr::min)

oobj PyFExpr::nth(const XArgs& args) {
auto nthFn = oobj::import("datatable", "nth");
auto n = args[1].to<py::oobj>(py::oint(0));
oobj n = args[0].to_oobj() ? args[0].to_oobj()
: py::oint(0);
oobj skipna = args[1].to_oobj_or_none();
return nthFn.call({this, n, skipna});
}
Expand Down

0 comments on commit 67890c5

Please sign in to comment.