Skip to content

Commit 0dbdfd9

Browse files
committed
examples: compare-tokens: use .first() instead of .get(0)
Clippy suggests that .first() is more readable than .get(0).
1 parent da20f05 commit 0dbdfd9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/compare-tokens.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ async fn main() -> Result<()> {
4545
.await?
4646
.rows
4747
.unwrap()
48-
.get(0)
48+
.first()
4949
.expect("token query no rows!")
5050
.columns[0]
5151
.as_ref()

0 commit comments

Comments
 (0)