finished sketching out controller code