Comments (4)
Oh, I was just about to say that I released rest-builder 0.9.2 :)
Thank you for confirming and using rest-core.
from rest-core.
I remembered that I once touched this, because I realized that DELETE shouldn't have any payload according to the specification.
However if that works, and people need it, I don't mind to support it. Could you please see if this patch would work for you?
diff --git a/lib/rest-builder/middleware.rb b/lib/rest-builder/middleware.rb
index 230da59..aa16fed 100644
--- a/lib/rest-builder/middleware.rb
+++ b/lib/rest-builder/middleware.rb
@@ -1,7 +1,7 @@
module RestBuilder
module Middleware
- METHODS_WITH_PAYLOAD = [:post, :put, :patch]
+ METHODS_WITH_PAYLOAD = [:post, :put, :patch, :delete]
def self.included mod
mod.send(:attr_reader, :app)
Note that this is now implemented in https://github.com/godfat/rest-builder so you'll need to apply the patch there. Let me know if you don't know how to patch it.
from rest-core.
Yes. I was able to patch that in rest-builder & DELETE is working perfectly with the change. It is needed for us to perform batch deletions where we wish to send bulk Ids in the REQUEST_PAYLOAD.
from rest-core.
Thank you very much for the release. You are simply amazing!
from rest-core.
Related Issues (18)
- Connection refused does not emit exception, future just returns nil instead HOT 4
- FTP client support HOT 3
- JsonResponse error on redirect HOT 2
- Future and nil values HOT 5
- incompatible encoding regexp match (UTF-8 regexp with ASCII-8BIT string) HOT 2
- Stuck processes HOT 5
- Setting SSL options HOT 5
- RestCore::JsonResponse::ParseError on non-success http status code HOT 5
- Listen for "child_added" HOT 4
- support for oj gem HOT 2
- access response content as Tempfile IO object HOT 6
- add dalli extension for hash compatibility HOT 1
- rest-core [3.0.0] and Ruby 2.4.0. Not able to build client HOT 5
- RestBuilder::Promise: ERROR: incompatible encoding regexp match (UTF-8 regexp with ASCII-8BIT string) HOT 11
- EventSource vs WebSocket? HOT 5
- "\xAD" from ASCII-8BIT to UTF-8 ERROR when requested GET HOT 7
- Unwanted payload for DELETE request from JsonRequest HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rest-core.