Update master key works

Key file creation works
Code cleanup
This commit is contained in:
Geoffroy BONNEVILLE
2020-04-22 17:06:16 +02:00
parent a7da427ded
commit 61f5e9df0b
19 changed files with 78 additions and 925 deletions

View File

@@ -27,7 +27,7 @@ namespace ModernKeePass.Application.Database.Commands.UpdateCredentials
if (!_database.IsOpen) throw new DatabaseClosedException();
_database.UpdateCredentials(new Credentials
{
KeyFileContents = await _file.OpenBinaryFile(message.KeyFilePath),
KeyFileContents = !string.IsNullOrEmpty(message.KeyFilePath) ? await _file.OpenBinaryFile(message.KeyFilePath) : null,
Password = message.Password
});
}