Skip to content

Commit

Permalink
Add bare :ping and :pong frames to the spec
Browse files Browse the repository at this point in the history
  • Loading branch information
Azolo committed Aug 31, 2018
1 parent 88b1fd6 commit 703ee8a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
## In Git
### Bug Fixes
- Fix `pong` frame not being a correct return type in spec
- Fix bare `ping` and `pong` frames in spec
- When neither grame doesn't have a payload

## 0.4.1
### Enhancements
Expand Down
5 changes: 3 additions & 2 deletions lib/websockex.ex
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,9 @@ defmodule WebSockex do
@type client :: pid | :atom | {:via, module, atom}

@type frame ::
{:ping | :ping, nil | message :: binary}
| {:pong | :pong, nil | message :: binary}
:ping
| :pong
| {:ping | :pong, nil | message :: binary}
| {:text | :binary, message :: binary}

@typedoc """
Expand Down

0 comments on commit 703ee8a

Please sign in to comment.