fix javascript engine problem