remove debug clause (no logical error)
add dynamic entry function