rewrote (and simplified) action up