Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix null pointer error when saving flutter widget #182

Merged
merged 4 commits into from
Dec 2, 2023

Conversation

milindgoel15
Copy link
Contributor

fix for renderFlutterWidget

Relevant issue comments that provide what the exception was:

#91 (comment)
#91 (comment)

The issue happens if the user tries to save a flutter widget data into storage and hasn't defined any groupID for iOS. The null pointer exception occurred because the code checks for a null value. Hence, throwing the exception.

So we added a platform check for both iOS and Android and assigned value based on the active platform.

If user does not define an iOS groupId, the plugin fails to save any flutter widget into storage resulting in `(Failed to save screenshot to app group container: Null check operator used on a null value)`
@ABausG ABausG self-requested a review December 2, 2023 11:17
lib/home_widget.dart Outdated Show resolved Hide resolved
@ABausG ABausG self-requested a review December 2, 2023 11:29
Copy link
Owner

@ABausG ABausG left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super thank you! I'm currently fixing the pipeline. This should be released today!

@milindgoel15
Copy link
Contributor Author

Might need to rebase/fix the conflicts by the PR as the new flutter changes was also merged by you in (18cb7c7)

Copy link

codecov bot commented Dec 2, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (7031a9c) 100.00% compared to head (f0a9c90) 100.00%.

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #182   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            2         2           
  Lines           68        67    -1     
=========================================
- Hits            68        67    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ABausG ABausG merged commit 58e99a4 into ABausG:main Dec 2, 2023
5 checks passed
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