mirror of
https://github.com/aljazceru/turso.git
synced 2026-01-06 01:34:21 +01:00
Disable extension loading for wasm
We should enable it later when wasm become more mature
This commit is contained in:
3
bindings/javascript/.gitignore
vendored
3
bindings/javascript/.gitignore
vendored
@@ -121,7 +121,7 @@ dist
|
||||
.AppleDouble
|
||||
.LSOverride
|
||||
|
||||
# Icon must end with two
|
||||
# Icon must end with two
|
||||
Icon
|
||||
|
||||
|
||||
@@ -195,3 +195,4 @@ Cargo.lock
|
||||
!.yarn/versions
|
||||
|
||||
*.node
|
||||
*.wasm
|
||||
|
||||
@@ -189,9 +189,12 @@ impl Database {
|
||||
#[napi]
|
||||
pub fn load_extension(&self, path: String) -> napi::Result<()> {
|
||||
let ext_path = turso_core::resolve_ext_path(path.as_str()).map_err(into_napi_error)?;
|
||||
self.conn
|
||||
.load_extension(ext_path)
|
||||
.map_err(into_napi_error)?;
|
||||
#[cfg(not(target_family = "wasm"))]
|
||||
{
|
||||
self.conn
|
||||
.load_extension(ext_path)
|
||||
.map_err(into_napi_error)?;
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user