-
Notifications
You must be signed in to change notification settings - Fork 5
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
MOBILE-455: Don't show CTA if custom api keys are used #16
base: main
Are you sure you want to change the base?
MOBILE-455: Don't show CTA if custom api keys are used #16
Conversation
appStorage.save(value, StorageKey.SignupPromptHideTimeMillis) | ||
|
||
private suspend fun getCustomApiKeysEnabled() = | ||
appStorage.load(StorageKey.CustomApiKeysEnabled, Boolean::class).get() ?: false |
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.
Although it should work, I'd rather consider injecting CustomApiKeysUseCase
in this class and checking the state
property of it. For the sake of the separation of concerns 🙂 That state
is designed to always contain a relevant value.
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.
np, I just wasn't sure whether there is a convention of injecting classes of same level to each other
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.
Hi guys attention plzy 5 gmail acomt data sum number apps device haking can posibale recovery strong late pass cl
oud
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.
I took an alternative path - instead of injecting one use case with the logic to another usecase with its own logic (which seems to be a bit of code smell for me), I created a unified usecase that joins them. Old usecase was renamed and new combined use case got its old name eliminating the need to change view model(s).
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.
@opof17pro I didn't get you, sorry. Could you elaborate?
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.
Send me link cloud
No description provided.