add-on repository fixes

digging into the add-on repository update code, i have found some regression caused by c311b9c2

i'll tack on fixes to this PR once i get hold of @jmarshallnz for some discussions. don't merge just yet.