Skip to content

Commit

Permalink
add null check
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-ext-simba-jf committed Mar 14, 2024
1 parent 8f4514d commit 540e2df
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,10 @@ public BigDecimal toBigDecimal(int index) throws SFException {
}

public boolean shouldTreatDecimalAsInt(SFBaseSession session) {
if (!session.isJdbcArrowTreatDecimalAsInt() && !session.isJdbcTreatDecimalAsInt()) {
return false;
if (session != null) {
if (!session.isJdbcArrowTreatDecimalAsInt() && !session.isJdbcTreatDecimalAsInt()) {
return false;
}
}
return true;
}
Expand Down

0 comments on commit 540e2df

Please sign in to comment.