Skip to content
This repository has been archived by the owner on Jan 10, 2024. It is now read-only.

removed "resolveActivity" check on open camera #1507

Merged
merged 2 commits into from
Aug 10, 2022

Conversation

tobiasjungmann
Copy link
Contributor

Issue

This PR is a fix for a small bug I stumbled on. Since I found a solution rather quickly, I've skipped the creating an additional issue.

The problem was that the camera view in the feedback activity could not be opened.

Solution

This code (FeedbackPresenter) finished the method too early:

if (takePictureIntent.resolveActivity(context.packageManager) == null) {  
    return  
}

This check returns null even if successful in more recent API versions. This check is now removed and the potential exception will be caught if the activity does actually not exist.

How to test

Open Feedback tab and add a new image with the camera. Camera view should open.

@CommanderStorm
Copy link
Member

I will review this once my exams are done next week.

@CommanderStorm CommanderStorm merged commit 0f27eb7 into master Aug 10, 2022
@CommanderStorm CommanderStorm deleted the bugfix/open-camera branch August 10, 2022 17:46
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants