simplify export logic