@capacitor-community/sqlite 3.4.1-4 → 3.4.1

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/README.md CHANGED
@@ -28,11 +28,13 @@
28
28
 
29
29
  ## CAPACITOR 3 (Master)
30
30
 
31
- 🚨 Since release 3.4.1-4 ->> 🚨
32
- MacOS only, databases location for Electron can be set in `the config.config.ts` as followed:
31
+ 🚨 Since release 3.4.1 ->> 🚨
32
+ Databases location for Electron can be set in `the config.config.ts` as followed:
33
33
  plugins: {
34
34
  CapacitorSQLite: {
35
- electronMacLocation: "/YOUR_DATABASES_PATH"
35
+ electronMacLocation: "/YOUR_DATABASES_PATH",
36
+ electronWindowsLocation: "C:\\ProgramData\\CapacitorDatabases",
37
+ electronLinuxLocation: "/home/CapacitorDatabases"
36
38
  }
37
39
  }
38
40
  For existing databases, YOU MUST COPY old databases to the new location
@@ -49,7 +51,7 @@
49
51
  npm run build
50
52
  npx cap copy @capacitor-community/electron
51
53
  npx cap open @capacitor-community/electron
52
- 🚨 Since release 3.4.1-4 <<- 🚨
54
+ 🚨 Since release 3.4.1 <<- 🚨
53
55
 
54
56
  🚨 Since release 3.4.1-1 ->> 🚨
55
57
 
@@ -2562,9 +2562,10 @@ class UtilsFile {
2562
2562
  * @param directory
2563
2563
  */
2564
2564
  _mkdirSyncRecursive(directory) {
2565
- const path = directory.replace(/\/$/, '').split('/');
2565
+ const sep = this.Path.sep;
2566
+ const path = directory.replace(/\/$/, '').split(sep);
2566
2567
  for (let i = 1; i <= path.length; i++) {
2567
- const segment = path.slice(0, i).join('/');
2568
+ const segment = path.slice(0, i).join(sep);
2568
2569
  segment.length > 0 && !this.NodeFs.existsSync(segment)
2569
2570
  ? this.NodeFs.mkdirSync(segment)
2570
2571
  : null;