GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — Kill BaseHelper and friends by samtstern · Pull Request #777 · firebase/FirebaseUI-Android Conversation
|
| import android.view.ContextThemeWrapper; | ||
|
|
||
| @RestrictTo(RestrictTo.Scope.LIBRARY_GROUP) | ||
| public class DialogBase extends DialogFragment { |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
@samtstern Could we just get rid of this class? The only dialog using it is the RecoveryEmailSentDialog and it doesn't use any of this. I also noticed that there's dead code in the RecoveryEmailSentDialog:
public static void show(String email, FlowParameters parameters, FragmentManager manager) { // We never use the flow params bundle.putParcelable(ExtraConstants.EXTRA_FLOW_PARAMS, parameters); }
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Good catch!
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| public class FragmentBase extends Fragment { | ||
| protected FragmentHelper mHelper; | ||
|
|
||
| protected FlowParameters mFlowParameters; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't the flow params be private since we have a getter to handle initialization?
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| public class HelperActivityBase extends AppCompatActivity { | ||
|
|
||
| protected ActivityHelper mActivityHelper; | ||
| protected FlowParameters mFlowParameters; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Same.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
|
||
| protected ActivityHelper mActivityHelper; | ||
| protected FlowParameters mFlowParameters; | ||
| protected ProgressDialogHolder mProgressDialogHolder; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
It looks like the dialog can also be private since you have a getter. Or we could remove the getter, seems easier and would be more consistent with the other code you've written.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| public static void show(String email, FlowParameters parameters, FragmentManager manager) { | ||
| RecoveryEmailSentDialog result = new RecoveryEmailSentDialog(); | ||
| Bundle bundle = new Bundle(); | ||
| bundle.putParcelable(ExtraConstants.EXTRA_FLOW_PARAMS, parameters); |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Oh, just noticed you added the flow params. Yeah, lol. We should just kill DialogBase since we aren't using any of it and it's forcing us to add dead code to the RecoveryEmailSentDialog.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| return Auth.CredentialsApi; | ||
| } | ||
|
|
||
| public static FirebaseUser getCurrentUser(FlowParameters parameters) { |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
@samtstern We should probably mark this as @Nullable.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Change-Id: Ib07cea70703f6f7fdc2b47e5c9aab43f764350cf
|
@SUPERCILEX thanks for the comments! Think I fixed them all. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
@samtstern LGTM! 😄 |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.