Refused to set unsafe header "cookie"

天晴同志發表於2018-06-01

axios做請求攔截的時候,加了個

this.$ajax.interceptors.request.use(config=> {
    config.headers.Cookie = 'JSESSIONID=B8CC9786DD7EFA8DAD24E525F3442DF1'
    return config
})
複製程式碼

然後報錯Refused to set unsafe header "cookie"

Cookie改成Authorization就可以了

相關文章