The plugins-login-common library for authenticating with the Google Cloud Platform shared by several IDE plugins including Google Cloud Tools for Eclipse, Google Cloud Tools for IntelliJ, and Android Studio.
Apache License 2.0
2
stars
9
forks
source link
Eliminate warnings / clean up and simplify code #20
I had this code clean-up hanging around for a while.
A few points in this code clean-up:
connected has always been true, so it's essentially meaningless.
Removed the private method checkLoggedIn(), which automatically pops up a login browser if no one is logged in. It wasn't compatible with the login flow using a local server, so it shouldn't be used anyway. For the existing places where checkLoggedIn() is used, I enforced the precondition that the class should be in a logged-in state.
There had been mixed use of GregorianCalendar().getTimeInMillis() and System.currentTimeMillis().
I had this code clean-up hanging around for a while.
A few points in this code clean-up:
connected
has always been true, so it's essentially meaningless.checkLoggedIn()
, which automatically pops up a login browser if no one is logged in. It wasn't compatible with the login flow using a local server, so it shouldn't be used anyway. For the existing places wherecheckLoggedIn()
is used, I enforced the precondition that the class should be in a logged-in state.GregorianCalendar().getTimeInMillis()
andSystem.currentTimeMillis()
.@nbashirbello @elharo @briandealwis @akerekes