[erlang-questions] configure http methods in yaws

Imants Cekusins imantc@REDACTED
Fri Feb 13 08:00:06 CET 2015

Cheers for another example, Steve! Very useful indeed.

> supporting both the state field for existing apps and the new field for new or revised apps

well there is probably already a test for #rewrite_response in state
field, somewhere. The modified test would be:

rewrite_response(Arg1) ->

State = Arg1#arg.state,
Is_in_state = is_record(State, rewrite_response),

case Is_in_state of
 true -> State;
 false -> Arg1#arg.rewrite_response


More information about the erlang-questions mailing list