Skip to content

Commit

Permalink
fix: resolve null pointer exceptions accessing missing URIs
Browse files Browse the repository at this point in the history
  • Loading branch information
Iakobs committed Mar 1, 2024
1 parent fb98744 commit 94de851
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ fun fromEvent(godot: Godot, event: Event) = Dictionary().apply {
put("description", event.description)
put("eventId", event.eventId)
put("formattedValue", event.formattedValue)
event.iconImageUri.let {
event.iconImageUri?.let {
put(
"iconImageUri",
it.toStringAndSave(godot, "iconImageUri", event.eventId)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ fun fromLeaderboard(godot: Godot, leaderboard: Leaderboard) = Dictionary().apply
put("displayName", leaderboard.displayName)
put("variants", fromLeaderboardVariant(leaderboard.variants))
ScoreOrder.fromOrder(leaderboard.scoreOrder)?.let { put("scoreOrder", it.name) }
leaderboard.iconImageUri.let {
leaderboard.iconImageUri?.let {
put(
"iconImageUri",
it.toStringAndSave(
Expand Down

0 comments on commit 94de851

Please sign in to comment.