stream-chat-flutter icon indicating copy to clipboard operation
stream-chat-flutter copied to clipboard

[Android] App don't show enablePhotoAndVideoAccessMessage after denying permissions

Open arteminthesky opened this issue 4 years ago • 2 comments

Which packages are you using?

stream_chat_flutter

On what platforms did you experience the issue?

Android

What version are you using?

4.5.0

What happened?

The problem is there are two places where the package requests photo permissions simultaneously First place Second place

And in second place throws error which is not handled in the package

Error: PlatformException(PERMISSION_REQUESTING, Another permission request is still ongoing. Please request after the existing one is done.)

Steps to reproduce

1. Go to Chat contains StreamMessageInput
2. Tap Attachment button
3. Deny permission
4. See empty placeholder (Offstage)

Supporting info to reproduce

No response

Relevant log output

No response

Flutter analyze output

No response

Flutter doctor output

No response

Code of Conduct

  • [X] I agree to follow this project's Code of Conduct

arteminthesky avatar Aug 31 '22 12:08 arteminthesky

Possible solution is to use permission request in first place only for iOS (since PermissionState.limited available only on iOS)

arteminthesky avatar Aug 31 '22 12:08 arteminthesky

This has been solved in v5, it's a beta release, but it will be promoted to stable soon

imtoori avatar Sep 12 '22 10:09 imtoori