openstreetmap-website
https://github.com/openstreetmap/openstreetmap-website
Ruby
The Rails application that powers OpenStreetMap
UserBlocksController#require_valid_params
check that the input parameters are valid, setting an instance variable if not. note that this doesn't do any redirection, as it's called before two different actions, each of which should redirect to a different place.
Edit
git clone [email protected]:openstreetmap/openstreetmap-website.git
cd openstreetmap-website
open app/controllers/user_blocks_controller.rb
Contribute
# Make a new branchgit checkout -b -your-name--update-docs-UserBlocksController-require_valid_params-for-pr
# Commit to gitgit add app/controllers/user_blocks_controller.rbgit commit -m "better docs for UserBlocksController#require_valid_params"
# Open pull requestgem install hub # on a mac you can `brew install hub`
hub fork
git push <your name> -your-name--update-docs-UserBlocksController-require_valid_params-for-pr
hub pull-request
# Celebrate!