implement timeouts. still not ideal because ui can be out of sync, but it will do