Addressed comments made by @puck42

This commit is contained in:
nielsvangijzen 2019-11-29 09:58:46 +01:00
parent 86a8ec5302
commit 1a917b30eb
2 changed files with 2 additions and 2 deletions

View File

@ -107,7 +107,7 @@ function verifyCsrf($csrf_token) {
return hash_equals($current_csrf, $csrf_token);
}
return false;
return $current_csrf === $csrf_token;
}
/**

View File

@ -245,7 +245,7 @@ function principal_editor() {
$c->messages[] = i18n("Updating Principal record.");
}
$editor->Write();
if ( $_POST['type_id'] != 3 && $editor->IsCreate() ) {
if ( $_POST['type_id'] != 3 && $editor->IsCreate() ) {
/** We only add the default calendar if it isn't a group, and this is a create action */
require_once('auth-functions.php');
CreateHomeCollections($editor->Value('username'));