mirror of
https://github.com/samsonjs/http-cookie.git
synced 2026-03-25 08:55:53 +00:00
origin=: Do not raise error if the new value is the same as the stock value.
This commit is contained in:
parent
5a78013d85
commit
48f5783ba5
1 changed files with 1 additions and 0 deletions
|
|
@ -413,6 +413,7 @@ class HTTP::Cookie
|
|||
|
||||
# See #origin.
|
||||
def origin=(origin)
|
||||
return origin if origin == @origin
|
||||
@origin.nil? or
|
||||
raise ArgumentError, "origin cannot be changed once it is set"
|
||||
origin = URI(origin)
|
||||
|
|
|
|||
Loading…
Reference in a new issue