Fixing rails snippets