Fix variable scoping issue in Rocket_DocumentAction