https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=17600
--- Comment #84 from David Cook <[email protected]> --- (In reply to Jonathan Druart from comment #75) > I have rebased the branch (tricky!), but I get > > Undefined subroutine &C4::Items::TransformKohaToMarc called at > /home/vagrant/kohaclone/C4/Items.pm line 1491. > > when I hit /cgi-bin/koha/catalogue/MARCdetail.pl?biblionumber=42 > > TransformKohaToMarc is exported by C4::Biblio. > And it is what we are trying to avoid... > > Any ideas? I don't really understand the question here. Based on https://github.com/joubu/Koha/commit/9bbab48f740f1ebcb4c08549622d750b34fe14c0, I'm guessing that you're explicitly importing "TransformKohaToMarc" from C4::Biblio at the top of C4::Items, but you're still getting "Undefined subroutine &C4::Items::TransformKohaToMarc called at > /home/vagrant/kohaclone/C4/Items.pm line 1491."? I'd need to be able to poke around on the system to know exactly what's going on and I'd have to do some experiments (like dumping %INC and looking at functions by namespace to see what is declared at what time), but... ...wouldn't a solution be just to write C4::Biblio::TransformKohaToMarc? Personally, I think we overuse Exporter.pm. I think moving from EXPORT to EXPORT_OK is a great improvement, but I'm not sure why we export so many functions either. Perhaps because it makes things easier to write, but it makes things harder to read and understand, and it creates issues like these... -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
