finished ch6, refactored controllers using model relations