Skip to content

Commit

Permalink
Signal INTERNAL ERROR in case of attempt to reuse db on Windows
Browse files Browse the repository at this point in the history
Should never happen due to workaround solution to
#666
  • Loading branch information
Christopher J. Brody committed Jan 2, 2018
1 parent 31185b6 commit 760dec7
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
3 changes: 2 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Changes

##### cordova-sqlite-legacy-core 1.0.7-pre4
##### cordova-sqlite-legacy-core 1.0.7-pre5

- Signal INTERNAL ERROR in case of attempt to reuse db on Windows (should never happen due to workaround solution to BUG 666)
- SQLITE_DEFAULT_CACHE_SIZE build flag fix for macOS ("osx") and Windows

###### cordova-sqlite-legacy-express-core 1.0.5
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cordova-sqlite-legacy-core",
"version": "1.0.7-pre4",
"version": "1.0.7-pre5",
"description": "Native interface to SQLite for PhoneGap/Cordova (legacy core version branch)",
"cordova": {
"id": "cordova-sqlite-legacy-core",
Expand Down
2 changes: 1 addition & 1 deletion plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<plugin xmlns="http://www.phonegap.com/ns/plugins/1.0"
xmlns:android="http://schemas.android.com/apk/res/android"
id="cordova-sqlite-legacy-core"
version="1.0.7-pre4">
version="1.0.7-pre5">

<name>Cordova sqlite storage plugin - legacy core version branch</name>

Expand Down
6 changes: 5 additions & 1 deletion src/windows/sqlite-proxy.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ module.exports = {
var res;

function openImmediate(dbname) {
//var dbname = options.name;
if (!!dbmap[dbname]) {
// NO LONGER EXPECTED due to BUG 666 workaround solution:
fail("INTERNAL ERROR: database already open for dbname: " + dbname);
}

// from @EionRobb / phonegap-win8-sqlite:
var opendbname = Windows.Storage.ApplicationData.current.localFolder.path + "\\" + dbname;
console.log("open db name: " + dbname + " at full path: " + opendbname);
Expand Down

0 comments on commit 760dec7

Please sign in to comment.