Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
refactor!: singleton API only way to use SDK now #209
refactor!: singleton API only way to use SDK now #209
Changes from all commits
1409add
8144244
50e4dcc
8f539da
bba0714
0d018a2
b56a494
d9a5b6b
ce0de69
74586d8
eae9c63
b31ecbd
68b4806
12ca20b
c208835
dec4535
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
This file was deleted.
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.
This code was originally added to the SDK so we could do something such as running background queue tasks for all of the site-ids ever registered to the SDK. Today, we only run background queue tasks for the currently initialized site-id (most to all of our customers use our SDK in this way).
However, we have never used this feature so I removed it. We can bring it back in the future if we decide we need this feature.
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.
afaik swift cares about initialized & uninitialized variables. so before it was initialized to an empty string as a default, now that it is not any edge cases to consider if people dont set region?
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.
Not sure what you mean by, "...if people don't set region".
Having the default value be
""
is error-prone, IMO. Our SDK should set a value for this when the SDK is initialized. So, by me removing the default, it reminds us to set a value for it at SDK initialization.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.
No more need for a SDK store. We now store the SDKConfig instance in the dependency injection graph.