Http-Method changes from POST to OPTIONS when changing Content-Type

后端 未结 3 1321
-上瘾入骨i
-上瘾入骨i 2021-01-13 22:27

I am using closure library to do a simple POST. I think XhrIo should work because from my machine when I use any other rest client ,like Firefox browser app RESTClient or Ch

3条回答
  •  臣服心动
    2021-01-13 22:37

    If you are pass Content-Type on authorization request it will convert POST method to OPTIONS method so while we are use ouath and passing authorization token that time do not required Content-Type.

    So do not pass Content-Type on all authorization request it won't change your method POST to OPTIONS

提交回复
热议问题