From 27ffcf2c1e792ceed256ff10dee8ca224938473a Mon Sep 17 00:00:00 2001 From: Isaac Date: Tue, 26 Jan 2016 12:29:47 -0700 Subject: [PATCH 1/2] docs($cookiesProvider): Clarify cookie domain rules Fixed a grammatical mistake ("equals to"), made hyphenation consistent, fixed punctuation and clarified the sentence structure. --- src/ngCookies/cookies.js | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/ngCookies/cookies.js b/src/ngCookies/cookies.js index 5bcf39bfeb76..12c4587c49a6 100644 --- a/src/ngCookies/cookies.js +++ b/src/ngCookies/cookies.js @@ -34,16 +34,17 @@ angular.module('ngCookies', ['ng']). * The object may have following properties: * * - **path** - `{string}` - The cookie will be available only for this path and its - * sub-paths. By default, this would be the URL that appears in your base tag. + * sub-paths. By default, this is the URL that appears in your `` tag. * - **domain** - `{string}` - The cookie will be available only for this domain and - * its sub-domains. For obvious security reasons the user agent will not accept the - * cookie if the current domain is not a sub domain or equals to the requested domain. + * its sub-domains. For security reasons the user agent will not accept the cookie + * if the current domain is not a sub-domain of this domain or equal to it. * - **expires** - `{string|Date}` - String of the form "Wdy, DD Mon YYYY HH:MM:SS GMT" * or a Date object indicating the exact date/time this cookie will expire. - * - **secure** - `{boolean}` - The cookie will be available only in secured connection. + * - **secure** - `{boolean}` - `true` if the cookie will be available only through a + * secured connection. * - * Note: by default the address that appears in your `` tag will be used as path. - * This is important so that cookies will be visible for all routes in case html5mode is enabled + * Note: By default, the address that appears in your `` tag will be used as the path. + * This is important so that cookies will be visible for all routes when html5mode is enabled. * **/ var defaults = this.defaults = {}; From 4bcc7731c4a229a296087791b6a8edf9bb169ef1 Mon Sep 17 00:00:00 2001 From: Isaac Date: Tue, 26 Jan 2016 14:15:59 -0700 Subject: [PATCH 2/2] Update cookies.js --- src/ngCookies/cookies.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ngCookies/cookies.js b/src/ngCookies/cookies.js index 12c4587c49a6..28a761bf21de 100644 --- a/src/ngCookies/cookies.js +++ b/src/ngCookies/cookies.js @@ -40,7 +40,7 @@ angular.module('ngCookies', ['ng']). * if the current domain is not a sub-domain of this domain or equal to it. * - **expires** - `{string|Date}` - String of the form "Wdy, DD Mon YYYY HH:MM:SS GMT" * or a Date object indicating the exact date/time this cookie will expire. - * - **secure** - `{boolean}` - `true` if the cookie will be available only through a + * - **secure** - `{boolean}` - If `true`, then the cookie will only be available through a * secured connection. * * Note: By default, the address that appears in your `` tag will be used as the path.