shortened the generated code