fixed javascript compile error