destruction errors out on HABTM w/out primary key

This should resolve #13893