-
Notifications
You must be signed in to change notification settings - Fork 88
#86 Fix singletone class initialisation #87
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
Conversation
…ndle stob start observing issue.
So you do not have init multiple times after this PR? |
Actually init called multiple times, but initPrivate only ones. Also on multiple call of init the returning result is same initialised only one time object. But generally this PR implements real singletone pattern. |
About I don't think
I think the more appropriate way would be needing an event api like |
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.
-
remove
stopObserving
workaround for refresh, keep this PR simple and could be discussed in another PR -
remove unused / commented debugging logs
-(instancetype) initPrivate { | ||
self = [super init]; | ||
if (self) { | ||
// Initialization code here. |
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.
above should only change the function name, instead making a mess diff
Hello, would you mind to take a look if this solves your problem described in #85? |
Thanks @Romick2005 |
Since this an open source, so it would be better to follow the current code base's style, and makes minimal changes in a single PR. But fire a PR to adjust them is acceptable for sure |
Thank you @zxcpoiu, it's just styling, so never mind. No worries I am ok with this, until it works as expected :). |
Also take care of start stop Observing issue on metro bundler restart/reload/hot-reload.