-
Notifications
You must be signed in to change notification settings - Fork 253
allow to update delegate every time attachViewDelegate called. #156
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
base: master
Are you sure you want to change the base?
Conversation
allow to update delegate every time attachViewDelegate called.
|
I tested this and it seems to work! |
|
Me too. Please merge. However I would prefer to delete the line instead of commenting it out. |
|
It is working! |
|
Please merge this PR |
|
Maybe if it can help someone. Here are some details... The lib is composed of
The lib takes one of the following wrong assumption:
The ok-but-not-great fix is to comment or remove the guard as proposed. It clean the left over UIViewController instance in the static object. Ideally someone with experience with the lib would evaluate and fix it by finding the others path of cleanup (when switching app for example). In time being patch-package can be your friend, it is simple to use: https://dev.to/zhnedyalkow/the-easiest-way-to-patch-your-npm-package-4ece |
1 similar comment
|
Maybe if it can help someone. Here are some details... The lib is composed of
The lib takes one of the following wrong assumption:
The ok-but-not-great fix is to comment or remove the guard as proposed. It clean the left over UIViewController instance in the static object. Ideally someone with experience with the lib would evaluate and fix it by finding the others path of cleanup (when switching app for example). In time being patch-package can be your friend, it is simple to use: https://dev.to/zhnedyalkow/the-easiest-way-to-patch-your-npm-package-4ece |
|
|
||
| public static func attachViewDelegate(_ delegate: ReactShareViewDelegate!) { | ||
| guard (ShareMenuReactView.viewDelegate == nil) else { return } | ||
| // guard (ShareMenuReactView.viewDelegate == nil) else { return } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this fix the listener?
oniOS I check initialShare on view because the listener doesn't fire
this PR is related to this issue #135.