Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1030)

Unified Diff: remoting/webapp/crd/js/host_screen.js

Issue 963103004: Remove getCached* methods from remoting.Identity. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase and jscompile fixes. Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/webapp/crd/js/host_controller.js ('k') | remoting/webapp/crd/js/identity.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/webapp/crd/js/host_screen.js
diff --git a/remoting/webapp/crd/js/host_screen.js b/remoting/webapp/crd/js/host_screen.js
index 183deb7f1884543312d7222909f8c9531ab3cd36..cb3695d0c272ee5445647a09690325cc4f674abb 100644
--- a/remoting/webapp/crd/js/host_screen.js
+++ b/remoting/webapp/crd/js/host_screen.js
@@ -94,10 +94,12 @@ remoting.tryShareWithToken_ = function(hostFacade, token) {
base.debug.assert(hostSession_ === null);
hostSession_ = new remoting.HostSession();
- var email = /** @type {string} */ (remoting.identity.getCachedEmail());
- hostSession_.connect(
- hostFacade, email, token, onHostStateChanged_,
- onNatTraversalPolicyChanged_, logDebugInfo_, it2meConnectFailed_);
+ remoting.identity.getEmail().then(
+ function(/** string */ email) {
+ hostSession_.connect(
+ hostFacade, email, token, onHostStateChanged_,
+ onNatTraversalPolicyChanged_, logDebugInfo_, it2meConnectFailed_);
+ });
};
/**
@@ -336,4 +338,4 @@ function onNatTraversalPolicyChanged_(enabled) {
}
}
-})();
+})();
« no previous file with comments | « remoting/webapp/crd/js/host_controller.js ('k') | remoting/webapp/crd/js/identity.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698