update to use Guard::Compat::UI
avoid creating var in global scope