Skip to content

Fix: nullability issue with Bitmap on Android - #4299

Closed
samipshresthaq wants to merge 1 commit into
rnmapbox:mainfrom
samipshresthaq:fix/android_bitmap_compile_error
Closed

samipshresthaq wants to merge 1 commit into
rnmapbox:mainfrom
samipshresthaq:fix/android_bitmap_compile_error

Conversation

@samipshresthaq

Copy link
Copy Markdown

Description

Fixes the following compile error when building the Android app.

DownloadMapImageTask.kt:80:56 Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type 'Bitmap?'.

Reproduced using

  • @rnmapbox/maps version: 10.3.5
  • React Native version: 0.87.0
  • Gradle: 9.4.1

Screenshot OR Video

image

Verification

Verified that the app built successfully without any :rnmapbox_maps:compileDebugKotlin errors.

@mfazekas

Copy link
Copy Markdown
Contributor

Superseded by #4297, which fixes the same nullable-bitmap compile error without the force-unwrap (avoids a possible NPE if the bitmap is ever actually null). Merged in e33400c. Thanks for the report and the fix.

@mfazekas mfazekas closed this Sep 21, 2026

This branch is waiting to be deployed

1 waiting deployment
CI with Mapbox Tokens df043eaf Waiting Sep 13, 2026 by samipshresthaq via CI requiring tokens / Web/Mapbox / Example Build for Web #1176
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants