SGU: Updates to logic to make it more robust