Skip to content

Error: cannot await properties of a non object

MetaMemoryT edited this page Feb 4, 2015 · 2 revisions

Error: cannot await properties of a non-object.

The .props method expects to receive an object.

For example:

Promise.props({
    pictures: getPictures(),
    comments: getComments(),
    tweets: getTweets()
}).then(function(result){
    console.log(result.tweets, result.pictures, result.comments);
});

This happens when a non object value or a promise that resolves with something that is not an object is being passed instead.