assignByClick appears to be working as intended except when deleting it is off by one keystroke.  Also hardly tested at all so very likely there are other problems.