Converted from generic handler to mvc