Skip to content

Commit

Permalink
fix(storage): localForage accepts arbitrary engines
Browse files Browse the repository at this point in the history
  • Loading branch information
jgw96 authored Sep 30, 2016
1 parent b45e23d commit 529831d
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/storage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,7 @@ export class Storage {
* @param engine engine allows you to specify a specific storage engine to use. Can be INDEXEDB, WEBSQL or LOCALSTORAGE
*/
setEngine(engine: string) {
if (engine !== 'INDEXEDB' || engine !== 'WEBSQL' || engine !== 'LOCALSTORAGE') {
console.error('Engine not recognized, engine choices are INDEXEDDB, WEBSQL and LOCALSTORAGE');
} else {
this._db.setDriver(this._db.engine);
}
this._db.setDriver(this._db.engine);
}

}

0 comments on commit 529831d

Please sign in to comment.