Skip to content

Commit 1d3472f

Browse files
committed
Add MOVE and COPY verbs
1 parent 2117fcc commit 1d3472f

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,8 @@ data Method
169169
| PATCH
170170
| POST
171171
| PUT
172+
| MOVE
173+
| COPY
172174
| CustomMethod String
173175
```
174176

src/Network/HTTP/Method.purs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ data Method
1010
| PATCH
1111
| POST
1212
| PUT
13+
| MOVE
14+
| COPY
1315
| CustomMethod String
1416

1517
instance eqMethod :: Eq Method where
@@ -20,6 +22,8 @@ instance eqMethod :: Eq Method where
2022
(==) PATCH PATCH = true
2123
(==) POST POST = true
2224
(==) PUT PUT = true
25+
(==) MOVE MOVE = true
26+
(==) COPY COPY = true
2327
(==) _ _ = false
2428
(/=) x y = not (x == y)
2529

@@ -31,6 +35,8 @@ instance showMethod :: Show Method where
3135
show PATCH = "PATCH"
3236
show POST = "POST"
3337
show PUT = "PUT"
38+
show MOVE = "MOVE"
39+
show COPY = "COPY"
3440
show (CustomMethod m) = "(CustomMethod " ++ show m ++ ")"
3541

3642
instance isOptionMethod :: IsOption Method where

0 commit comments

Comments
 (0)