Skip to content

Commit

Permalink
feat(constructor): allow any promisable to be passed in (not just a P…
Browse files Browse the repository at this point in the history
…romise)
  • Loading branch information
RobertFischer committed Dec 13, 2020
1 parent e99a11c commit e30a32e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/fun-promise.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export default class FunPromise<T> implements Promise<T> {
/**
* Constructor, which takes the promise to wrap.
*/
constructor(wrapped: Promise<T>) {
constructor(wrapped: Promisable<T>) {
this.wrapped = new Promise(async (resolve, reject) => {
let resolved = null;
try {
Expand Down

0 comments on commit e30a32e

Please sign in to comment.