Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix an issue when fetching policy without local cache of token policy.
Because the first policy cache will be loaded synchronously before local_state creation. We'll miss its OnStoreLoaded/Error event as CloudPolicyService has to be created after |local_state|. It means we won't know the result of cache loading. To resolve this, check the initialization status once the CloudPolicyService has been created. Fetch policy from server if cache is not loaded properly. Bug: 832694 Change-Id: Idd0b9e35ea2afded586b73c765197b5574ba3900 Reviewed-on: https://chromium-review.googlesource.com/1011211 Commit-Queue: Owen Min <zmin@chromium.org> Reviewed-by: Roger Tawa <rogerta@chromium.org> Reviewed-by: Julian Pastarmov <pastarmovj@chromium.org> Cr-Original-Commit-Position: refs/heads/master@{#550684}(cherry picked from commit bcf5d8e) Reviewed-on: https://chromium-review.googlesource.com/1013342 Reviewed-by: Owen Min <zmin@chromium.org> Cr-Commit-Position: refs/branch-heads/3396@{#10} Cr-Branched-From: 9ef2aa8-refs/heads/master@{#550428}
- Loading branch information