@konfuzio/document-validation-ui 0.1.44 → 0.1.45-dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@konfuzio/document-validation-ui",
3
- "version": "0.1.44",
3
+ "version": "0.1.45-dev.0",
4
4
  "repository": "git://github.com:konfuzio-ai/document-validation-ui.git",
5
5
  "main": "dist/app.js",
6
6
  "scripts": {
package/src/api.js CHANGED
@@ -4,8 +4,7 @@ let HTTP, FILE_REQUEST, authToken, appLocale;
4
4
  const DEFAULT_URL = "https://app.konfuzio.com";
5
5
  const FILE_URL = process.env.VUE_APP_IMAGE_URL;
6
6
 
7
- axios.defaults.xsrfCookieName = "csrftoken";
8
- axios.defaults.xsrfHeaderName = "X-CSRFToken";
7
+ axios.defaults.withCredentials = true;
9
8
 
10
9
  HTTP = axios.create({
11
10
  baseURL: process.env.VUE_APP_API_URL || `${DEFAULT_URL}/api/v3/`,
@@ -35,8 +34,9 @@ const setLocale = (locale) => {
35
34
  const getInterceptorConfig = (config) => {
36
35
  if (authToken) {
37
36
  config.headers["Authorization"] = `Token ${authToken}`;
38
- config.headers["Accept-Language"] = `${appLocale}-${appLocale}`;
39
37
  }
38
+ config.headers["Accept-Language"] = `${appLocale}-${appLocale}`;
39
+
40
40
  return config;
41
41
  };
42
42