Only try to patch translation environment if it exists