fix compile error with mozjs

Signed-off-by: xiehuc <xiehuc@gmail.com>