controllers now take models instead of hashmaps