From 618668e18de30b2482f21ffd09bbd0e5cd89769d Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 13 Dec 2019 19:58:52 +0000 Subject: [PATCH] Bug 24244: Send null instead of empty string if branch not set --- C4/Suggestions.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/C4/Suggestions.pm b/C4/Suggestions.pm index 764c331752..836b13fc42 100644 --- a/C4/Suggestions.pm +++ b/C4/Suggestions.pm @@ -448,6 +448,8 @@ sub NewSuggestion { $suggestion->{suggesteddate} = dt_from_string unless $suggestion->{suggesteddate}; + delete $suggestion->{branchcode} if $suggestion->{branchcode} eq ''; + my $suggestion_object = Koha::Suggestion->new( $suggestion )->store; my $suggestion_id = $suggestion_object->suggestionid; -- 2.11.0