fix js sequence