http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15446
--- Comment #2 from Jonathan Druart <jonathan.dru...@bugs.koha-community.org> --- Created attachment 46096 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=46096&action=edit Bug 15446: Rename Koha::Object[s]->type with _type In a few case (at least systempreferences and export_format (csv profiles), the type method of Koha::Object and Koha::Objects can be in conflict with the column names. Indeed systempreferences.type exists and so the method will return 'Systempreference' (the name of the module) instead of the value of the row in DB. I have found at least 1 place where it can cause issue: In C4::Context->set_preference: 601 my $syspref = Koha::Config::SysPrefs->find( $var ); 602 my $type = $syspref ? $syspref->type() : undef; 603 604 $value = 0 if ( $type && $type eq 'YesNo' && $value eq '' ); type will always be 'Systempreference' and the YesNo pref will be set to an empty string '' instead of 0. I am not sure about the consequences of this, but it is preferable to fix it ASAP. To reproduce: 0/ Do not apply this patch 1/ Edit a YesNo prefs, AutoEmailOpacUser for instance 2/ Set it to "Don't sent" 3/ Check the value in DB, it should be set to an empty string, instead of 0 4/ Apply this patch and try again. Now the value should be 0 -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list Koha-bugs@lists.koha-community.org 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/