bugfix: javascript validate