fix recursive loading so that loaded is only triggered when all of the associations are loaded