Fixed a bug (invalid promise reject value).