Passing a primitive to a then handler

This is an interesting observation that I have made when experimenting with promises in JS. Consider this code:

Promise.resolve(1).then(2).then(console.log);

This prints out 1 as its output. Why didn’t the native-implemented promise API throw an exception? What is the benefit of “skipping” the non-function argument when it is being ignored anyway? I woud really apreciate an answer

This post is found in MDN.