Commit f21b68a7 authored by Frédéric Buclin's avatar Frédéric Buclin

Bug 687247: Bugzilla crashes when creating a new flagtype on PostgreSQL

a=LpSolit
parent 67a74ece
......@@ -118,6 +118,8 @@ sub create {
$class->check_required_create_fields(@_);
my $params = $class->run_create_validators(@_);
# In the DB, only the first character of the target type is stored.
$params->{target_type} = substr($params->{target_type}, 0, 1);
# Extract everything which is not a valid column name.
$params->{grant_group_id} = delete $params->{grant_group};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment