fix PUT and DELETE in REST API