status-based js