Index: chrome/browser/extensions/api/easy_unlock_private/easy_unlock_private_api.cc |
diff --git a/chrome/browser/extensions/api/easy_unlock_private/easy_unlock_private_api.cc b/chrome/browser/extensions/api/easy_unlock_private/easy_unlock_private_api.cc |
index 6bbdc5cc8b47901689036493f648b66f81fa1ece..c8cc9273f78a3ef461e3b429cd4561ba26679331 100644 |
--- a/chrome/browser/extensions/api/easy_unlock_private/easy_unlock_private_api.cc |
+++ b/chrome/browser/extensions/api/easy_unlock_private/easy_unlock_private_api.cc |
@@ -541,9 +541,14 @@ EasyUnlockPrivateGetSignInChallengeFunction:: |
~EasyUnlockPrivateGetSignInChallengeFunction() { |
} |
-bool EasyUnlockPrivateGetSignInChallengeFunction::RunAsync() { |
- SetError("Not implemented"); |
- SendResponse(false); |
+bool EasyUnlockPrivateGetSignInChallengeFunction::RunSync() { |
+ Profile* profile = Profile::FromBrowserContext(browser_context()); |
+ const std::string challenge = |
+ EasyUnlockService::Get(profile)->GetChallenge(); |
+ if (!challenge.empty()) { |
+ results_ = |
+ easy_unlock_private::GetSignInChallenge::Results::Create(challenge); |
+ } |
return true; |
} |