refacs to deal with bundles better