cozy-client 60.8.0 → 60.11.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.
@@ -3126,7 +3126,7 @@ var CozyClient = /*#__PURE__*/function () {
3126
3126
  CozyClient.hooks = CozyClient.hooks || {};
3127
3127
  CozyClient.fetchPolicies = _policies.default; //COZY_CLIENT_VERSION_PACKAGE in replaced by babel. See babel config
3128
3128
 
3129
- CozyClient.version = "60.8.0";
3129
+ CozyClient.version = "60.11.0";
3130
3130
 
3131
3131
  _microee.default.mixin(CozyClient);
3132
3132
 
@@ -886,7 +886,7 @@ var uploadFileWithConflictStrategy = /*#__PURE__*/function () {
886
886
  });
887
887
  _context6.prev = 2;
888
888
  _context6.next = 5;
889
- return getFullpath(client, dirId, name);
889
+ return getFullpath(client, dirId, name, driveId);
890
890
 
891
891
  case 5:
892
892
  path = _context6.sent;
@@ -91,10 +91,11 @@ exports.hasAnOffer = hasAnOffer;
91
91
 
92
92
  var buildPremiumLink = function buildPremiumLink(instanceInfo) {
93
93
  var managerUrl = (0, _get.default)(instanceInfo, 'context.data.manager_url', false);
94
+ var locale = (0, _get.default)(instanceInfo, 'instance.data.locale', 'en');
94
95
  var uuid = getUuid(instanceInfo);
95
96
 
96
97
  if (managerUrl && uuid) {
97
- return "".concat(managerUrl, "/cozy/instances/").concat(uuid, "/premium");
98
+ return "".concat(managerUrl, "/cozy/instances/").concat(uuid, "/premium?lang=").concat(locale);
98
99
  } else {
99
100
  return null;
100
101
  }
@@ -9,7 +9,8 @@ const noSelfHostedInstance = {
9
9
  },
10
10
  instance: {
11
11
  data: {
12
- uuid: '1234'
12
+ uuid: '1234',
13
+ locale: 'fr'
13
14
  }
14
15
  },
15
16
  diskUsage: {
@@ -78,7 +79,9 @@ describe('instance', () => {
78
79
 
79
80
  it('should generate the link to the manager', () => {
80
81
  const url = instance.buildPremiumLink(noSelfHostedInstance)
81
- expect(url).toBe('https://manager.cozy.cc/cozy/instances/1234/premium')
82
+ expect(url).toBe(
83
+ 'https://manager.cozy.cc/cozy/instances/1234/premium?lang=fr'
84
+ )
82
85
  })
83
86
 
84
87
  it('should test if an instance has already subscribed to one of our offers', () => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cozy-client",
3
- "version": "60.8.0",
3
+ "version": "60.11.0",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.node.js",
6
6
  "browser": "dist/index.js",
@@ -74,5 +74,5 @@
74
74
  "react-native-ios11-devicecheck": "^0.0.3"
75
75
  },
76
76
  "sideEffects": false,
77
- "gitHead": "f6fce3e1d1c2377fa07b6d594e34055986fbbbff"
77
+ "gitHead": "8a114254c6f27a0358b0d79338f452337745b297"
78
78
  }