added wrap-restful-format handler to middleware