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

Issue 2671453003: [NTP::Cleanup] Avoid nested complex function calls (Closed)

Created:
3 years, 10 months ago by vitaliii
Modified:
3 years, 10 months ago
CC:
chromium-reviews, marq+watch_chromium.org, pkl (ping after 24h if needed), noyau+watch_chromium.org, ntp-dev+reviews_chromium.org, sdefresne+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[NTP::Cleanup] Avoid nested complex function calls The RemoteSuggestionsProviderImpl constructor takes a long list of parameters and previously the RemoteSuggestionFetcher (which also takes a lot of parameters) was constructed in line. This was confusing, because one could not easily determine to which MakeUnique given argument belonged to. This CL moves the RemoteSuggestionsFetcher into a local variable to improve readability. BUG=674033 Review-Url: https://codereview.chromium.org/2671453003 Cr-Commit-Position: refs/heads/master@{#448992} Committed: https://chromium.googlesource.com/chromium/src/+/5a842fb2c97ce7c2e140a2d77d503c1dc6e1a299

Patch Set 1 #

Patch Set 2 : resolve iOS compile error. #

Total comments: 3

Patch Set 3 : tschumann@ & treib@ comments. #

Total comments: 1

Patch Set 4 : clean rebase. #

Patch Set 5 : tschumann@ comment. #

Patch Set 6 : clean rebase. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+14 lines, -15 lines) Patch
M chrome/browser/ntp_snippets/content_suggestions_service_factory.cc View 1 2 3 4 5 1 chunk +7 lines, -7 lines 0 comments Download
M ios/chrome/browser/ntp_snippets/ios_chrome_content_suggestions_service_factory.cc View 1 2 3 4 1 chunk +7 lines, -8 lines 0 comments Download

Messages

Total messages: 55 (38 generated)
vitaliii
Hi jkrcal@, could you have a look at content_suggestions_service_factory.cc?
3 years, 10 months ago (2017-02-01 08:55:01 UTC) #4
jkrcal
lgtm, thanks!
3 years, 10 months ago (2017-02-01 08:58:03 UTC) #5
vitaliii
Hi noyau@, Could you have a look at iOS bit?
3 years, 10 months ago (2017-02-01 09:08:55 UTC) #14
tschumann
https://codereview.chromium.org/2671453003/diff/20001/chrome/browser/ntp_snippets/content_suggestions_service_factory.cc File chrome/browser/ntp_snippets/content_suggestions_service_factory.cc (right): https://codereview.chromium.org/2671453003/diff/20001/chrome/browser/ntp_snippets/content_suggestions_service_factory.cc#newcode192 chrome/browser/ntp_snippets/content_suggestions_service_factory.cc:192: std::move(status_service)); I'm having a hard time following the motivation. ...
3 years, 10 months ago (2017-02-01 11:35:37 UTC) #18
Marc Treib
https://codereview.chromium.org/2671453003/diff/20001/chrome/browser/ntp_snippets/content_suggestions_service_factory.cc File chrome/browser/ntp_snippets/content_suggestions_service_factory.cc (right): https://codereview.chromium.org/2671453003/diff/20001/chrome/browser/ntp_snippets/content_suggestions_service_factory.cc#newcode192 chrome/browser/ntp_snippets/content_suggestions_service_factory.cc:192: std::move(status_service)); On 2017/02/01 11:35:37, tschumann wrote: > I'm having ...
3 years, 10 months ago (2017-02-01 12:33:20 UTC) #20
noyau (Ping after 24h)
I don't care one way or another. But this method is now becoming very long ...
3 years, 10 months ago (2017-02-01 12:33:34 UTC) #22
vitaliii
Hi tschumann@ and treib@, I addressed your comments, please have a look. noyau@, do you ...
3 years, 10 months ago (2017-02-01 13:15:15 UTC) #25
Marc Treib
This seems fine to me; I don't feel very strongly either way. rs lgtm if ...
3 years, 10 months ago (2017-02-01 13:19:01 UTC) #27
tschumann
https://codereview.chromium.org/2671453003/diff/40001/chrome/browser/ntp_snippets/content_suggestions_service_factory.cc File chrome/browser/ntp_snippets/content_suggestions_service_factory.cc (right): https://codereview.chromium.org/2671453003/diff/40001/chrome/browser/ntp_snippets/content_suggestions_service_factory.cc#newcode174 chrome/browser/ntp_snippets/content_suggestions_service_factory.cc:174: { sorry for the late response. I'm not a ...
3 years, 10 months ago (2017-02-01 15:07:59 UTC) #30
noyau (Ping after 24h)
On 2017/02/01 13:15:15, vitaliii wrote: > Hi tschumann@ and treib@, > > I addressed your ...
3 years, 10 months ago (2017-02-03 12:01:18 UTC) #31
vitaliii
[jkrcal@, treib@ - feel free to ignore] I addressed tschumann@ comment, could you have a ...
3 years, 10 months ago (2017-02-07 14:53:29 UTC) #37
sdefresne
noyau is OOO for the whole week
3 years, 10 months ago (2017-02-07 15:03:47 UTC) #39
vitaliii
sdefresne@, thanks for notifying me about noyau@'s absence. Would you mind having a look (as ...
3 years, 10 months ago (2017-02-07 15:42:26 UTC) #42
sdefresne
ios/ lgtm
3 years, 10 months ago (2017-02-07 15:58:15 UTC) #43
tschumann
lgtm
3 years, 10 months ago (2017-02-08 14:44:58 UTC) #49
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2671453003/160001
3 years, 10 months ago (2017-02-08 14:46:57 UTC) #52
commit-bot: I haz the power
3 years, 10 months ago (2017-02-08 14:51:30 UTC) #55
Message was sent while issue was closed.
Committed patchset #6 (id:160001) as
https://chromium.googlesource.com/chromium/src/+/5a842fb2c97ce7c2e140a2d77d50...

Powered by Google App Engine
This is Rietveld 408576698