And some more notices ...

This commit is contained in:
Michael 2018-07-31 18:10:34 +00:00
parent c0ecafcfdc
commit 06c6bfc88d
3 changed files with 22 additions and 12 deletions

View file

@ -81,14 +81,14 @@ class="settings-submit" value="' . L10n::t('Save Settings') . '" /></div>';
function fromgplus_addon_settings_post(&$a,&$b) {
if(! local_user())
if (!local_user())
return;
if($_POST['fromgplus-submit']) {
if (!empty($_POST['fromgplus-submit'])) {
PConfig::set(local_user(),'fromgplus','account',trim($_POST['fromgplus-account']));
$enable = ((x($_POST,'fromgplus-enable')) ? intval($_POST['fromgplus-enable']) : 0);
$enable = (x($_POST,'fromgplus-enable') ? intval($_POST['fromgplus-enable']) : 0);
PConfig::set(local_user(),'fromgplus','enable', $enable);
$keywords = ((x($_POST, 'fromgplus-keywords')) ? intval($_POST['fromgplus-keywords']) : 0);
$keywords = (x($_POST, 'fromgplus-keywords') ? intval($_POST['fromgplus-keywords']) : 0);
PConfig::set(local_user(),'fromgplus', 'keywords', $keywords);
if (!$enable)