juzhiyuan commented on a change in pull request #158: Adding api key for the 
request
URL: 
https://github.com/apache/incubator-apisix-dashboard/pull/158#discussion_r394083354
 
 

 ##########
 File path: src/utils/request.ts
 ##########
 @@ -51,6 +56,9 @@ const errorHandler = (error: { response: Response }): 
Response => {
 const request = extend({
   errorHandler, // 默认错误处理
   credentials: 'include', // 默认请求是否带上cookie
+  headers: {
+    'X-API-KEY': fetchAPIKey()
 
 Review comment:
   sorry, there should be
   
   
![image](https://user-images.githubusercontent.com/2106987/76921399-f3d99800-6908-11ea-84b2-f47edbb6dc12.png)
   
   We just exported the API_KEY standalone, do not need put it in the default 
config value. 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to