Fixed query promises to be able to resolve multiple times
Merge pull request #561 from Zeroto/promisefix

Fixed query promises to be able to resolve multiple times