fixed internal server error due to a misnamed dictionary key on lines 204-213. All set now.