Making some changes to baseui cleanup function to accomodate sauce