Skip to content

Commit

Permalink
Update readme and fix the markdown files so hex docs likes them
Browse files Browse the repository at this point in the history
  • Loading branch information
choptastic committed Mar 27, 2023
1 parent 73536d6 commit 7137f6a
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 10 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
13 changes: 6 additions & 7 deletions README.markdown → README.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ A Handler module is expected to export the following functions:

+ `run(Bridge)` - Bridge will be an initialized instance of a SimpleBridge
object, and the last step of the run will be the return value of
`BridgeX:build_response()`
`sbw:build_response(Bridge)`
+ `ws_init(Bridge)` - Called when a websocket connection is initialized.
+ Return Values:
+ `ok` - Everything went okay, proceed with the connection.
Expand Down Expand Up @@ -280,10 +280,9 @@ inconvenient to have to include the `simple_bridge.hrl` header in your
application's modules. The safer and more portable approach is to use the
`sb_uploaded_file` module provided by Simple Bridge.

As with the Bridge module above, all `sb_uploaded_file` objects can be referenced in either of two ways:
As with the Bridge module above, all `sb_uploaded_file` objects can be referenced by:

+ Standard Erlang Calls: `sb_uploaded_file:function_name(File)`
+ Parameter Module Style Calls: `File:function_name()`
+ `sb_uploaded_file:function_name(File)`

`sb_uploaded_file` exports the following functions:

Expand Down Expand Up @@ -358,7 +357,7 @@ The Bridge modules export the following functions:


Finally, you build the response to send to your HTTP server with the
`build_response/0` function.
`sbw:build_response/1` function.

* **sbw:build_response(Bridge)** - Create a response tuple that you can hand
off to your HTTP server.
Expand Down Expand Up @@ -461,7 +460,7 @@ We can be found on:

If you wish to contribute to SimpleBridge's development, check out our
[contribution
guidelines](https://github.com/nitrogen/nitrogen/blob/master/CONTRIB.markdown).
guidelines](https://github.com/nitrogen/nitrogen/blob/master/CONTRIB.md).

## License and Copyright

Expand All @@ -471,4 +470,4 @@ been maintained by [Jesse Gumm](http://jessegumm.com) since 2011.
Simple Bridge is copyright 2008-2023 Rusty Klophaus and Jesse Gumm.

Licensed under the [MIT
License](https://github.com/nitrogen/simple_bridge/blob/master/LICENSE.markdown)
License](https://github.com/nitrogen/simple_bridge/blob/master/LICENSE.md)
2 changes: 1 addition & 1 deletion rebar.config
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

{ex_doc, [
{source_url, <<"https://github.com/nitrogen/simple_bridge">>},
{extras, [<<"README.markdown">>, <<"CHANGELOG.markdown">>, <<"LICENSE.markdown">>]},
{extras, [<<"README.md">>, <<"CHANGELOG.md">>, <<"LICENSE.md">>, <<"CONTRIB.md">>]},
{main, <<"readme">>}
]}.

Expand Down
4 changes: 2 additions & 2 deletions src/simple_bridge_util.erl
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,8 @@ binarize_header(Header) when is_list(Header) ->
%% list, it will be easier to check for existence, and shouldn't require all
%% this conversion that's being done right here.
%%
%% Checks if `Header` exists as a key in `HeaderList`
%% if it doesn't, inserts it with the value `Value`
%% Checks if Header exists as a key in HeaderList
%% if it doesn't, inserts it with the provided Value.
-spec ensure_header(header_list(), {header_key(), term()}) -> header_list().
ensure_header(HeaderList,{Header,Value}) ->
ensure_header(HeaderList,Header,Value).
Expand Down

0 comments on commit 7137f6a

Please sign in to comment.