service worker: Fix fetch timing UMA recording for subresource loading

Before this CL there was a path in ServiceWorkerSubresourceLoader
where we called RecordTimingMetrics(true) even when the request
fell back to network. Specifically:

OnFallback()
-> CommitEmptyResponseAndComplete()
-> CommitCompleted()
-> RecordTimingMetrics(true)

This generated bogus numbers for
ServiceWorker.LoadTiming.Subresource.ResponseReceivedToCompleted2.
This CL fixes it by updating CommitCompleted() to check a flag
that indicates that network fallback was requested.

Bug: 877972
Change-Id: Ia944903938b8a7daed1665475f4b2a871f2b21ab
Reviewed-on: https://chromium-review.googlesource.com/c/1397504
Commit-Queue: Kenichi Ishibashi <bashi@chromium.org>
Reviewed-by: Matt Falkenhagen <falken@chromium.org>
Cr-Commit-Position: refs/heads/master@{#620631}
2 files changed