mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-17 18:14:42 +00:00
config: unify the change messages
Changes are not unknown, the config can be diff'ed.
This commit is contained in:
parent
ec244ebe52
commit
1955be171e
@ -336,7 +336,7 @@ function make_config_revision_entry($desc = '')
|
||||
}
|
||||
|
||||
if (empty($desc)) {
|
||||
$desc = sprintf(gettext('%s changed the configuration'), $_SERVER['SCRIPT_NAME']);
|
||||
$desc = sprintf(gettext('%s made changes'), $_SERVER['SCRIPT_NAME']);
|
||||
}
|
||||
|
||||
$revision = array();
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Copyright (C) 2015 Deciso B.V.
|
||||
*
|
||||
@ -26,6 +27,7 @@
|
||||
* POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
*/
|
||||
|
||||
namespace OPNsense\Core;
|
||||
|
||||
use \Phalcon\DI\FactoryDefault;
|
||||
@ -372,10 +374,10 @@ class Config extends Singleton
|
||||
}
|
||||
if (!empty($_SERVER['REQUEST_URI'])) {
|
||||
// when update revision is called from a controller, log the endpoint uri
|
||||
$revision['description'] = sprintf(gettext("%s made unknown change"), $_SERVER['REQUEST_URI']);
|
||||
$revision['description'] = sprintf(gettext('%s made changes'), $_SERVER['REQUEST_URI']);
|
||||
} else {
|
||||
// called from a script, log script name and path
|
||||
$revision['description'] = sprintf(gettext("%s made unknown change"), $_SERVER['SCRIPT_NAME']);
|
||||
$revision['description'] = sprintf(gettext('%s made changes'), $_SERVER['SCRIPT_NAME']);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user