Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
You sure your front end logic isn't doing it? Isn't the first request a cord request and creates the object anyway since you don't check for the http method?
-
remove32595y@EngineerCoding I seem to remember running into this a couple months ago, and I think you're right
-
hilaby785yChrome sometimes does this if your server does not respond fast enough. Or maybe your front end had bind the event twice on the same DOM object.
-
Google Chrome, stealing all yo personal data one unnoticeable POST request at a time 👌
-
gdb123111785yive seen this bug on chrome randomly on some of my web apps. I havent find out a real solution yet.
-
Hazarth95035yAre you checking for the http method, as per the CORS standard a lightweight [OPTION] request is sent before every request to check the waters. Option requests however dont send data in the body, they do however send url params, cookies and so forth
-
arekxv10545y@gdb123 It is not a bug.
Whenever you are sending an XHR / Fetch request to a domain which is not the same which rendered the initial page (that is how it usually is with rest spa apps) chrome sends one OPTIONS request including CORS data and the methods it wanted to perform.
Server needs to respond with 200 OK and valid CORS response before the browser will make the actual request.
It's a safety feature :)
Just spent hours, debugging why a system is creating two objects in the database when trying to create one.
Turns out it is Chrome re-sending a POST request.
Really.
What. The. Actual. Fuck. Google.
rant