[Refactor] Minor refactor in mod_advancedOptions. For code related to previous commit.