From 2c8bc2cdcdb7b144b7a583d24922fd8064bcff3d Mon Sep 17 00:00:00 2001 From: Paul Nikitochkin Date: Fri, 6 Sep 2013 21:41:04 +0300 Subject: Use Ruby on Rails Coding Conventions for code examples in the guides * Indent after private/protected * Ruby >= 1.9 syntax for hashes * Prefer method { do_stuff } instead of method{do_stuff} for single-line blocks. [ci skip] --- guides/source/form_helpers.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'guides/source/form_helpers.md') diff --git a/guides/source/form_helpers.md b/guides/source/form_helpers.md index 578cfbe105..39852cb00a 100644 --- a/guides/source/form_helpers.md +++ b/guides/source/form_helpers.md @@ -914,9 +914,9 @@ def create end private -def person_params - params.require(:person).permit(:name, addresses_attributes: [:id, :kind, :street]) -end + def person_params + params.require(:person).permit(:name, addresses_attributes: [:id, :kind, :street]) + end ``` ### Removing Objects -- cgit v1.2.3