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

Issue 1106723002: ServiceWorker: Decompose SWRegistration::SetVersionInternal for readability (Closed)

Created:
5 years, 8 months ago by nhiroki
Modified:
5 years, 8 months ago
Reviewers:
falken
CC:
chromium-reviews, michaeln, jsbell+serviceworker_chromium.org, tzik, serviceworker-reviews, jam, darin-cc_chromium.org, horo+watch_chromium.org, kinuko+serviceworker, kinuko+watch
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

ServiceWorker: Decompose SWRegistration::SetVersionInternal for readability Originally SetVersionInternal() was quite simple function, but that has been puzzuled as the codebase has evolved. This CL decomposes the function for readability and simplifies lifetime management for a version to be set, that is, passes a refcounted version as an argument instead of making temporary protect object. BUG=n/a TEST=n/a Committed: https://crrev.com/964b57ac5be1001f57dfb03262454324ef8b173a Cr-Commit-Position: refs/heads/master@{#326753}

Patch Set 1 #

Patch Set 2 : Remove .get() #

Patch Set 3 : make the argument const-ref #

Messages

Total messages: 11 (2 generated)
nhiroki
PTAL
5 years, 8 months ago (2015-04-24 04:03:40 UTC) #2
falken
Looks good, that function was nuts. Should we update callsites that are unnecessarily doing .get() ...
5 years, 8 months ago (2015-04-24 04:14:00 UTC) #3
nhiroki
On 2015/04/24 04:14:00, falken wrote: > Looks good, that function was nuts. Should we update ...
5 years, 8 months ago (2015-04-24 04:38:27 UTC) #4
falken
Actually should we just make this take a const scoped_refptr& to avoid refcount churn? I ...
5 years, 8 months ago (2015-04-24 04:45:39 UTC) #5
nhiroki
On 2015/04/24 04:45:39, falken wrote: > Actually should we just make this take a const ...
5 years, 8 months ago (2015-04-24 05:26:10 UTC) #6
falken
lgtm
5 years, 8 months ago (2015-04-24 05:33:21 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1106723002/40001
5 years, 8 months ago (2015-04-24 05:47:02 UTC) #9
commit-bot: I haz the power
Committed patchset #3 (id:40001)
5 years, 8 months ago (2015-04-24 07:38:22 UTC) #10
commit-bot: I haz the power
5 years, 8 months ago (2015-04-24 07:39:12 UTC) #11
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/964b57ac5be1001f57dfb03262454324ef8b173a
Cr-Commit-Position: refs/heads/master@{#326753}

Powered by Google App Engine
This is Rietveld 408576698