made the export trigger a little more general