[Clock] Utility methods pollute global scope

RESOLVED FIXED

Status

Firefox OS
Gaia::Clock
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: jugglinmike, Assigned: jugglinmike)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

15.46 KB, patch
iliu@mozilla.com, ianliu.moz@gmail.com
: review+
Details | Diff | Splinter Review
(Assignee)

Description

5 years ago
All utility methods are currently declared on the global scope. Organizing utility methods under a single namespace increases code readability and minimizes global namespace pollution.
(Assignee)

Comment 1

5 years ago
Created attachment 779839 [details] [diff] [review]
Bug-897089-util-methods.patch

Hey Ian,

I'm not sure how you prefer to conduct code reviews, so I've also made a pull request on GitHub; you can find it here: https://github.com/mozilla-b2g/gaia/pull/11127
Attachment #779839 - Flags: review?(iliu)
(Assignee)

Updated

5 years ago
Depends on: 897088
(Assignee)

Updated

5 years ago
Blocks: 897090
Comment on attachment 779839 [details] [diff] [review]
Bug-897089-util-methods.patch

Review of attachment 779839 [details] [diff] [review]:
-----------------------------------------------------------------

Mike,

I leave a comment on Github. Beside of a nit, the patch works for me.
Please revise and set the review again. Then, I'll help you to take a look.
Thank you.
Attachment #779839 - Flags: review?(iliu) → review-
OS: Linux → Gonk (Firefox OS)
Hardware: x86_64 → ARM
Blocks: 898666
(Assignee)

Comment 3

5 years ago
Created attachment 782609 [details] [diff] [review]
Bug-897089-util-methods-v2.patch

Nice catch, Ian! I've incorporated your feedback (see attached). I've also pushed this new commit to the pull request on GitHub.
Attachment #779839 - Attachment is obsolete: true
Attachment #782609 - Flags: review?(iliu)
Comment on attachment 782609 [details] [diff] [review]
Bug-897089-util-methods-v2.patch

Review of attachment 782609 [details] [diff] [review]:
-----------------------------------------------------------------

Mike,

Looks fine. Thanks for your updated.
Attachment #782609 - Flags: review?(iliu) → review+
(Assignee)

Comment 5

5 years ago
Landed in `master` at commit 495b889386d02112aca9dc13fe2b8f14477406e6

Thanks for the review, Ian!
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.