Commit Graph

9 Commits

Author SHA1 Message Date
Fatih Kadir Akın 53d12534b7 Remove ParamContainer abstraction to make it faster. 2016-03-06 21:43:13 +02:00
Fatih Kadir Akın 8267ffe2c5 Upgrade ParamParser to make it more convinient.
It now decouples `env.params` to `env.params.query`, `env.params.body`,
`env.params.json` and `env.params.url` and you still can access merged
values using `env.params.all`
2016-03-06 13:22:24 +02:00
sdogruyol 5a58ee3cbb Format code 2016-02-17 11:52:13 +02:00
Joris Moriau c5201f01ad added verb for filters and minor improvements 2016-02-17 10:34:01 +01:00
Sdogruyol 0b4a36953f Started reimplementing router 2016-01-12 21:37:12 +02:00
Sdogruyol aa0d97aa42 Update .travis.yml 2015-12-06 17:56:04 +02:00
Imran Latif c42f1f88e9 Added support for magic param `_method` just like Rails, Sinatra.
Following are the changes made in this commit:

- Added support for magic param `_method` just like Rails, Sinatra
etc.. Browsers which don't support `PUT`, `PATCH` and `DELETE` methods
can simulate them by sending `method` param in request body.

- The default Content-Type to parse request body submitted via forms
etc. is `application/x-www-form-urlencoded`. But if we send Ajax
request in Chrome ($.post) then by-default Content-Type is set to
`application/x-www-form-urlencoded; charset utf-8` which was not
getting matched. I changed the code from `==` to match against a
regular expression using `=~`.

- Print name and color of overridden HTTP method via Logger instead of
printing name and color or request's incoming HTTP method.

Making necessary changes as pointed by @sdogruyol

- Changed method name from`is_override_method_valid?` to
`override_method_valid?`.

- Refactored `if` condition in `override_method_valid?`.
2015-12-03 01:34:16 +05:00
Sdogruyol a8ad95aa67 Removing redundant code 2015-10-28 18:09:45 +02:00
Sdogruyol 5ca84fea4c Renamed all occurrences to Kemal 2015-10-23 21:33:26 +03:00
Renamed from src/frank/request.cr (Browse further)