Fix middleware RESTFULL format