@op-engineering/op-sqlite 11.2.8 → 11.2.10

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/cpp/bridge.cpp CHANGED
@@ -68,14 +68,16 @@ std::string opsqlite_get_db_path(std::string const &db_name,
68
68
  }
69
69
 
70
70
  mkdir(location);
71
- return location + "/" + db_name;
71
+ char resolved_path[PATH_MAX];
72
+ realpath((location + "/" + db_name).c_str(), resolved_path);
73
+ return std::string(resolved_path);
72
74
  }
73
75
 
74
76
  #ifdef OP_SQLITE_USE_SQLCIPHER
75
77
  sqlite3 *opsqlite_open(std::string const &name, std::string const &path,
76
- std::string const &crsqlite_path,
77
- std::string const &sqlite_vec_path,
78
- std::string const &encryption_key) {
78
+ std::string const &crsqlite_path,
79
+ std::string const &sqlite_vec_path,
80
+ std::string const &encryption_key) {
79
81
  #else
80
82
  sqlite3 *opsqlite_open(std::string const &name, std::string const &path,
81
83
  [[maybe_unused]] std::string const &crsqlite_path,
@@ -95,7 +97,7 @@ sqlite3 *opsqlite_open(std::string const &name, std::string const &path,
95
97
  }
96
98
 
97
99
  #ifdef OP_SQLITE_USE_SQLCIPHER
98
- if(!encryption_key.empty()) {
100
+ if (!encryption_key.empty()) {
99
101
  opsqlite_execute(db, "PRAGMA key = '" + encryption_key + "'", nullptr);
100
102
  }
101
103
  #endif
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@op-engineering/op-sqlite",
3
- "version": "11.2.8",
3
+ "version": "11.2.10",
4
4
  "description": "Next generation SQLite for React Native",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",
@@ -51,12 +51,11 @@
51
51
  "react": "18.3.1",
52
52
  "react-native": "0.76.5",
53
53
  "react-native-builder-bob": "^0.23.2",
54
- "turbo": "^1.12.4",
55
54
  "typescript": "5.0.4"
56
55
  },
57
56
  "peerDependencies": {
58
57
  "react": "*",
59
- "react-native": ">0.73.0"
58
+ "react-native": "*"
60
59
  },
61
60
  "workspaces": [
62
61
  "example"