summaryrefslogtreecommitdiffstats
path: root/editfields.cgi
diff options
context:
space:
mode:
Diffstat (limited to 'editfields.cgi')
-rw-r--r--editfields.cgi4
1 files changed, 2 insertions, 2 deletions
diff --git a/editfields.cgi b/editfields.cgi
index a77aafe77..f7a059016 100644
--- a/editfields.cgi
+++ b/editfields.cgi
@@ -63,8 +63,8 @@ elsif ($action eq 'new') {
# Validate these fields.
$name || ThrowUserError('customfield_missing_name');
# Don't want to allow a name that might mess up SQL.
- $name =~ /^\w+$/ || ThrowUserError('customfield_invalid_name',
- { name => $name });
+ $name =~ /^\w+$/ && $name ne "cf_"
+ || ThrowUserError('customfield_invalid_name', { name => $name });
# Prepend cf_ to the custom field name to distinguish it from standard fields.
if ($name !~ /^cf_/) {
$name = 'cf_' . $name;