Skip to content

Commit

Permalink
Merge pull request #1344 from burnash/fix/type-issue
Browse files Browse the repository at this point in the history
fix type issue (remove `.first()` function)
  • Loading branch information
alifeee authored Nov 6, 2023
2 parents 6944c1f + 6457676 commit 735feb8
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions gspread/worksheet.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,10 +310,14 @@ def cell(
"""
try:
data = self.get(
rowcol_to_a1(row, col), value_render_option=value_render_option
rowcol_to_a1(row, col),
value_render_option=value_render_option,
return_type=GridRangeType.ValueRange,
)

value = str(data.first())
try:
value = str(data[0][0])
except IndexError:
value = str(None)
except KeyError:
value = ""

Expand Down

0 comments on commit 735feb8

Please sign in to comment.