summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordoktornotor <notordoktor@gmail.com>2017-08-26 12:37:25 +0200
committerRenato Botelho <garga@FreeBSD.org>2017-09-22 08:57:30 -0300
commit43edba8403c8d5d08c192301dae9a53b55c713d4 (patch)
tree74e2f41d8ef0ce98e6fa8a9b2eb301a94fa990da
parent5d7095aa7fdc1e92ba5c4e93c39c359f0c20b2ee (diff)
downloadFreeBSD-ports-43edba8403c8d5d08c192301dae9a53b55c713d4.zip
FreeBSD-ports-43edba8403c8d5d08c192301dae9a53b55c713d4.tar.gz
Add reason to write_config() call
Also nuke obsolete useless code while here. (cherry picked from commit 2771d9f7d4719e66281845a03ea8f4bd076ba8af)
-rw-r--r--sysutils/pfSense-pkg-System_Patches/files/usr/local/www/system_patches_edit.php11
1 files changed, 3 insertions, 8 deletions
diff --git a/sysutils/pfSense-pkg-System_Patches/files/usr/local/www/system_patches_edit.php b/sysutils/pfSense-pkg-System_Patches/files/usr/local/www/system_patches_edit.php
index 057a9c6d..602d776 100644
--- a/sysutils/pfSense-pkg-System_Patches/files/usr/local/www/system_patches_edit.php
+++ b/sysutils/pfSense-pkg-System_Patches/files/usr/local/www/system_patches_edit.php
@@ -3,7 +3,7 @@
* system_patches_edit.php
*
* part of pfSense (https://www.pfsense.org)
- * Copyright (c) 2012-2015 Rubicon Communications, LLC (Netgate)
+ * Copyright (c) 2012-2017 Rubicon Communications, LLC (Netgate)
* All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -80,12 +80,7 @@ if ($_POST) {
$reqdfieldsn = array(gettext("Description"),gettext("URL/Commit ID"));
}
- $pf_version=substr(trim(file_get_contents("/etc/version")),0,3);
- if ($pf_version < 2.1) {
- $input_errors = eval('do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); return $input_errors;');
- } else {
- do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors);
- }
+ do_input_validation($_POST, $reqdfields, $reqdfieldsn, $input_errors);
if (!empty($_POST['location']) && !is_commit_id($_POST['location']) && !is_URL($_POST['location'])) {
$input_errors[] = gettext("The supplied commit ID/URL appears to be invalid.");
@@ -131,7 +126,7 @@ if ($_POST) {
}
}
- write_config();
+ write_config(gettext("System: Patches: edited a patch."));
if ($thispatch['autoapply']) {
patch_add_shellcmd();
}
OpenPOWER on IntegriCloud