Send flipperstate to cert downloader

Summary: Add flipperstate to the cert downloader.

Reviewed By: jknoxville

Differential Revision: D23172851

fbshipit-source-id: f0eb23ec709d656918831c2ee82a6ddb426596e5
This commit is contained in:
Pritesh Nandgaonkar
2020-08-18 17:14:32 -07:00
committed by Facebook GitHub Bot
parent 2e98c7f3c7
commit 3c3d76be60
2 changed files with 9 additions and 0 deletions

View File

@@ -10,6 +10,8 @@
#include <functional>
#include <string>
#include "FlipperCertificateExchangeMedium.h"
#include "FlipperState.h"
#include "FlipperStep.h"
namespace facebook {
namespace flipper {
@@ -44,6 +46,12 @@ class FlipperCertificateProvider {
* `stop` is called.
*/
virtual bool shouldResetCertificateFolder() = 0;
/**
* Sets the FlipperState, so that Cert Provider can send debuggin information
* to troubleshoot screen.
*/
virtual void setFlipperState(std::shared_ptr<FlipperState> state) = 0;
};
} // namespace flipper

View File

@@ -379,6 +379,7 @@ void FlipperConnectionManagerImpl::requestSignedCertFromFlipper() {
contextStore_->storeConnectionConfig(config);
}
if (certProvider_) {
certProvider_->setFlipperState(flipperState_);
auto gettingCertFromProvider =
flipperState_->start("Getting cert from Cert Provider");