made export() more friendly