This makes field-adder incompatible with various inputs, such as a file upload from helper_attach_upload. A null check before attempting the counter replace would surely fix it.