JS: fixed useless parameter.
JS: refactorization → type detection of lambdas.

Lambdas = anonymous functions.