Allow default custcode to be overwritten by an option