3980 primary address demotion

QA were running into problems with primary address getting demoted then promoted.  This patch should address this issue along with a related issue of rank selection.