Closed
Bug 1215473
Opened 9 years ago
Closed 9 years ago
Avoid accessing private variable placesStore in history DataAdapter
Categories
(Firefox OS Graveyard :: Sync, defect, P3)
Tracking
(Not tracked)
RESOLVED
FIXED
FxOS-S11 (13Nov)
People
(Reporter: mbdejong, Assigned: mbdejong)
References
Details
(Whiteboard: [partner-cherry-pick])
Attachments
(1 file)
At this line [1] and also two lines below, `store` is not defined.
[1] https://github.com/mozilla-b2g/gaia/blob/4d1ff2b17850c3ec3d9c6869b73e9a45e4338db4/apps/sync/js/adapters/bookmarks.js#L123
Comment 1•9 years ago
|
||
Assignee | ||
Updated•9 years ago
|
Attachment #8674818 -
Flags: feedback?(selee)
Assignee | ||
Comment 2•9 years ago
|
||
Needs a unit test, still.
Assignee | ||
Comment 3•9 years ago
|
||
The reason this is currently working is that ensureStore uses a variable that's also called 'store'. We could leave this as it is, but I think it's cleaner to rename the private variable to _store, and force the rest of the code to always use the value provided ensureStore, instead of sometimes accessing the private variable directly.
Comment 4•9 years ago
|
||
Comment on attachment 8674818 [details] [review]
[gaia] michielbdejong:1215473-store-variable-in-scope > mozilla-b2g:master
Hello Michiel, I leave some comments at github. BTW, how do you think if keeping store as a local variable in addBookmark function?
Please f? or r? me again once you have any update. Thank you!
Attachment #8674818 -
Flags: feedback?(selee)
Updated•9 years ago
|
Blocks: TV_FxAccount
Comment 5•9 years ago
|
||
I am going to implement this in bug 1215086.
Assignee | ||
Comment 6•9 years ago
|
||
Great!
Assignee | ||
Updated•9 years ago
|
Assignee: mbdejong → selee
Assignee | ||
Updated•9 years ago
|
Attachment #8674818 -
Flags: review?(selee)
Comment 7•9 years ago
|
||
Comment on attachment 8674818 [details] [review]
[gaia] michielbdejong:1215473-store-variable-in-scope > mozilla-b2g:master
LGTM :)
Attachment #8674818 -
Flags: review?(selee) → review+
Updated•9 years ago
|
Updated•9 years ago
|
Assignee: selee → mbdejong
Assignee | ||
Updated•9 years ago
|
Priority: P1 → P2
Assignee | ||
Updated•9 years ago
|
Summary: 'store is not defined' error in history DataAdapter → Avoid accessing private variable placesStore in history DataAdapter
Assignee | ||
Comment 8•9 years ago
|
||
Marking this as P3 / Sprint 11 because it's code cleanup and doesn't affect functionality.
Priority: P2 → P3
Target Milestone: FxOS-S10 (30Oct) → FxOS-S11 (13Nov)
Assignee | ||
Comment 9•9 years ago
|
||
Rebased.
Assignee | ||
Updated•9 years ago
|
Attachment #8674818 -
Flags: review+ → review?(ferjmoreno)
Updated•9 years ago
|
Attachment #8674818 -
Flags: review?(ferjmoreno) → review+
Comment 10•9 years ago
|
||
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Updated•9 years ago
|
Whiteboard: [partner-cherry-pick]
You need to log in
before you can comment on or make changes to this bug.
Description
•