fix remote scripts