Don't try to access injected omnipodPumpStatus in constructor
This commit is contained in:
parent
e432346fc5
commit
0fef4128ef
1 changed files with 5 additions and 0 deletions
|
@ -62,6 +62,11 @@ public class OmnipodCommunicationManager extends RileyLinkCommunicationManager {
|
|||
@Inject
|
||||
public OmnipodCommunicationManager(HasAndroidInjector injector, RFSpy rfspy) {
|
||||
super(injector, rfspy);
|
||||
}
|
||||
|
||||
@Inject
|
||||
public void onInit() {
|
||||
// this cannot be done in the constructor, as sp is not populated at that time
|
||||
omnipodPumpStatus.previousConnection = sp.getLong(
|
||||
RileyLinkConst.Prefs.LastGoodDeviceCommunicationTime, 0L);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue