Trying to fix a mess of combining two assignments