projects
/
koha_gimpoz
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7655eae
)
Bug 6132: Update sysprefs cache in set_preference
author
Julian Maurice
<julian.maurice@biblibre.com>
Mon, 2 Jan 2012 09:45:55 +0000
(10:45 +0100)
committer
Paul Poulain
<paul.poulain@biblibre.com>
Mon, 16 Jan 2012 13:52:23 +0000
(14:52 +0100)
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
C4/Context.pm
patch
|
blob
|
history
diff --git
a/C4/Context.pm
b/C4/Context.pm
index
7581faa
..
659ba05
100644
(file)
--- a/
C4/Context.pm
+++ b/
C4/Context.pm
@@
-514,7
+514,7
@@
the sysprefs cache.
sub set_preference {
my $self = shift;
- my $var =
shift
;
+ my $var =
lc(shift)
;
my $value = shift;
my $dbh = C4::Context->dbh or return 0;
@@
-530,7
+530,9
@@
sub set_preference {
ON DUPLICATE KEY UPDATE value = VALUES(value)
" );
- $sth->execute( $var, $value );
+ if($sth->execute( $var, $value )) {
+ $sysprefs{$var} = $value;
+ }
$sth->finish;
}