javascript: inline conditions
javascript: remove some more constructors