[Koha-bugs] [Bug 14375] DBIx::Connector should be stored in C4::Context instead of dbh
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Thu Aug 6 13:26:56 CEST 2015
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14375
Olli-Antti Kivilahti <olli-antti.kivilahti at jns.fi> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |olli-antti.kivilahti at jns.fi
--- Comment #11 from Olli-Antti Kivilahti <olli-antti.kivilahti at jns.fi> ---
Hi there! I like your approach, you are doing the right thing.
DBIx::Connector is said to be more robust and I am happy to hear it has solved
your issues.
However there is an issue with this patch that needs addressing if you want a
sign off from me.
First of all the naming convention is changed which can cause a lot of issues
for everybody. Some tests, custom modifications etc. can depend on
$context->{dbh}. The new name doesn't help increase clarity IMHO and we should
stick to the old "dbh".
- return $context->{"dbh"};
+ return $context->{'DBconn'}->dbh;
Same issue here
-sub _new_dbh
+sub _new_DBconn
_new_dbh is addressed directly from many places (atleast I do) regardless of it
being a private method. This is to circumvent bugs/limitations of the
C4::Context->dbh()-system. No reason to change it.
Because of these things a small and beautiful, yet invaluably important fix is
drowned into a large commit changing too many things for reasons I do not agree
of.
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list