Make updateM functorial instead of monadic, rename it