For hooks, put the environment in the action env