Remove FetchContext::DidLoadResource
Remove FetchContext::DidLoadResource and move the operations in it to DispatchDidFinishLoading and DispatchDidFail. This leads to code duplication but I think this change is overall a good change because: - DidLoadResource is called only twice. Repeating yourself twice is not that bad. - DidLoadResource is confusing; Whether that precedes or succeeds DispatchDidFinishLoading, whether it should be called in DispatchDidFail, etc. Previously FetchContext::DispatchDidFinishLoading and DispatchDidFail were called before Resource::Finish, but now they are called after Resource::Finish. That affected a few devtools tests because some tests finished as soon as resource loading finishes and some error messages got missing with the new semantics. This CL delays test completion a bit in order to keep the expectations. Bug: 914739 Change-Id: I5245dca240ebc7496d1de51909d458a6ed5a61d2 Reviewed-on: https://chromium-review.googlesource.com/c/1474887 Commit-Queue: Yutaka Hirano <yhirano@chromium.org> Reviewed-by:Hiroshige Hayashizaki <hiroshige@chromium.org> Reviewed-by:
Dmitry Gozman <dgozman@chromium.org> Reviewed-by:
Kouhei Ueno <kouhei@chromium.org> Cr-Commit-Position: refs/heads/master@{#636660}
Showing
Please register or sign in to comment