Improvements/1977 promise.empty

see #1977