Skip to content

Commit

Permalink
2.1.27
Browse files Browse the repository at this point in the history
Fix for #1769
  • Loading branch information
nilsteampassnet committed Jun 3, 2017
1 parent 8fd89fc commit 6a24dfa
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
3 changes: 2 additions & 1 deletion changelog.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
2.1.27

#1769 Installation issue - no admin account is created
#1775 Can not decrypt a created crypted Backup - Improved encryption with Defuse
#1774 Announce this Item by email
#1769 Installation issue - no admin account is created

New: Multiselection in Roles vs Folders matrix
New: LDAP configuration test mode (in progress)
Expand Down
5 changes: 1 addition & 4 deletions items.load.php
Original file line number Diff line number Diff line change
Expand Up @@ -602,9 +602,6 @@ function AjouterItem()
||
$("#create_item_without_password").val() === "1"
) {
var annonce = 0;
if ($('#annonce').is(':checked')) annonce = 1;

//Manage restrictions
var restriction = restriction_role = "";
$("#restricted_to_list option:selected").each(function () {console.log($(this).val());
Expand Down Expand Up @@ -675,7 +672,7 @@ function AjouterItem()
'"login":"' + sanitizeString($('#item_login').val()) + '", "is_pf":"' + is_pf + '", ' +
'"description":"' + (description) + '", "email":"' + $('#email').val() + '", "url":"' + url + '", "categorie":"' + selected_folder + '", ' +
'"restricted_to":"' + restriction + '", "restricted_to_roles":"' + restriction_role + '", "salt_key_set":"' + $('#personal_sk_set').val()+
'", "annonce":"' + annonce + '", "diffusion":"' + diffusion + '", "id":"' + $('#id_item').val() + '", ' +
'", "diffusion":"' + diffusion + '", "id":"' + $('#id_item').val() + '", ' +
'"anyone_can_modify":"' + $('#anyone_can_modify:checked').val() + '", "tags":"' + sanitizeString($('#item_tags').val())+
'", "random_id_from_files":"' + $('#random_id').val() + '", "to_be_deleted":"' + to_be_deleted + '", "fields":"' + sanitizeString(fields) + '", ' +
'"complexity_level":"' + parseInt($("#mypassword_complex").val()) + '"}';
Expand Down
8 changes: 6 additions & 2 deletions sources/admin.queries.php
Original file line number Diff line number Diff line change
Expand Up @@ -1130,8 +1130,12 @@
* Test the email configuraiton
*/
case "admin_email_test_configuration":
require_once $_SESSION['settings']['cpassman_dir'].'/sources/main.functions.php';
echo '[{"result":"email_test_conf", '.sendEmail($LANG['admin_email_test_subject'], $LANG['admin_email_test_body'], $_SESSION['user_email']).'}]';
if (empty($_SESSION['user_email'])) {
echo '[{"result":"email_test_conf", "error":"error_mail_not_send" , "message":"User has no email defined!"}]';
} else {
require_once $_SESSION['settings']['cpassman_dir'].'/sources/main.functions.php';
echo '[{"result":"email_test_conf", '.sendEmail($LANG['admin_email_test_subject'], $LANG['admin_email_test_body'], $_SESSION['user_email']).'}]';
}
break;

/*
Expand Down
2 changes: 1 addition & 1 deletion sources/items.queries.php
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@
}

// Announce by email?
if ($dataReceived['annonce'] == 1) {
if ($dataReceived['diffusion'] !== "") {
// get links url
if (empty($_SESSION['settings']['email_server_url'])) {
$_SESSION['settings']['email_server_url'] = $_SESSION['settings']['cpassman_url'];
Expand Down

0 comments on commit 6a24dfa

Please sign in to comment.