Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Issue 5193308200501248: Issue 1287 - Use window.location instead document.location (Closed)

Created:
Aug. 29, 2014, 3:33 p.m. by Sebastian Noack
Modified:
Aug. 30, 2014, 10:27 a.m.
Reviewers:
Wladimir Palant
Visibility:
Public.

Description

Issue 1287 - Use window.location instead document.location

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+4 lines, -4 lines) Patch
M include.preload.js View 1 chunk +2 lines, -2 lines 0 comments Download
M safari/ext/content.js View 1 chunk +1 line, -1 line 0 comments Download
M safari/ext/popup.js View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 6
Sebastian Noack
Aug. 29, 2014, 3:45 p.m. (2014-08-29 15:45:48 UTC) #1
Wladimir Palant
I generally prefer spelling things out: window.location.href (to make it obvious that location is a ...
Aug. 29, 2014, 7:54 p.m. (2014-08-29 19:54:28 UTC) #2
Sebastian Noack
I don't have a strong opinion on that. However I like consistency. And we don't ...
Aug. 29, 2014, 7:59 p.m. (2014-08-29 19:59:11 UTC) #3
Wladimir Palant
On 2014/08/29 19:59:11, Sebastian Noack wrote: > I don't have a strong opinion on that. ...
Aug. 29, 2014, 8:44 p.m. (2014-08-29 20:44:37 UTC) #4
Sebastian Noack
On 2014/08/29 20:44:37, Wladimir Palant wrote: > On 2014/08/29 19:59:11, Sebastian Noack wrote: > > ...
Aug. 29, 2014, 9:55 p.m. (2014-08-29 21:55:51 UTC) #5
Wladimir Palant
Aug. 29, 2014, 10:20 p.m. (2014-08-29 22:20:52 UTC) #6
On 2014/08/29 21:55:51, Sebastian Noack wrote:
> I see. However, the problem you try to address seems to be Gecko specific.

Really? And what if some of the code you write there moves to libadblockplus
tomorrow?

> And
> in fact, fully-qualifying global variables, by prepending "window.", is a
rather
> uncommon practice in the Chrome/OPera/Safari codebase.

I agree, it seems to be a bit inconsistent. As I said, it is up to you whether
you want to address this.

Powered by Google App Engine
This is Rietveld