Skip to content

3.0.0

Compare
Choose a tag to compare
@Ovyerus Ovyerus released this 12 Oct 00:27
· 38 commits to master since this release

This changes the previous call syntax db.foo() to one that returns a direct Promise when it encounters either .then, .catch, or .finally, changing it to db.foo.then(val => {}). This may seem like a kinda weird change, however when combined with the async/await syntax, this effectively makes any weird stuff disappear, becoming await db.foo.

Examples:

old style

const db = new Redite();

const foo = await db.foo();

new style

const db = new Redite();

const foo = await db.foo;