Skip to content

Commit

Permalink
Add ability to specify database location instead of always using 'def…
Browse files Browse the repository at this point in the history
…ault'
  • Loading branch information
zbarbuto committed Apr 8, 2016
1 parent dae7810 commit 8bef9be
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions src/localforage-cordovasqlitedriver.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,12 +113,13 @@
// Open the database; the openDatabase API will automatically
// create it for us if it doesn't exist.
try {
dbInfo.location = dbInfo.location || 'default';
dbInfo.db = openDatabase({
name: dbInfo.name,
version: String(dbInfo.version),
description: dbInfo.description,
size: dbInfo.size,
location: 'default'
name: dbInfo.name,
version: String(dbInfo.version),
description: dbInfo.description,
size: dbInfo.size,
location: dbInfo.location
});
} catch (e) {
reject(e);
Expand Down

0 comments on commit 8bef9be

Please sign in to comment.