completed Chapter 9 of railstutorial.org