fix membership add code