Skip to content
This repository was archived by the owner on Mar 13, 2018. It is now read-only.

Commit 258675a

Browse files
committed
Fix cookie property setting and syntax error
1 parent 0db6998 commit 258675a

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

polymer-cookie/polymer-cookie.html

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,16 +29,17 @@
2929
};
3030
});
3131
var nom = this.name;
32-
return map.filter(function(kv){ return kv.name === nom })[0];
32+
return map.filter(function(kv){ return kv.name === nom; })[0];
3333
},
3434
load: function() {
3535
var kv = this.parseCookie();
3636
this.value = kv && kv.value;
3737
},
38-
// TODO(dfreedman): collapse these when 'multiple props -> single change function' exists in Polymer
3938
valueChanged: function() {
39+
this.expire = FOREVER;
4040
this.save();
4141
},
42+
// TODO(dfreedman): collapse these when 'multiple props -> single change function' exists in Polymer
4243
expiresChanged: function() {
4344
this.save();
4445
},
@@ -65,7 +66,7 @@
6566
for (var i = 0, k; i < cookieProps.length; i++) {
6667
k = cookieProps[i];
6768
if (this[k]) {
68-
prepared += ';' + escape(k) + '=' escape(this[k]);
69+
prepared += (';' + k + '=' + this[k]);
6970
}
7071
}
7172
return prepared;

0 commit comments

Comments
 (0)