Fix (#548)
This commit is contained in:
parent
fc6f494f0d
commit
397a516dc1
11 changed files with 60 additions and 10 deletions
|
|
@ -25,7 +25,7 @@ namespace LibationAvalonia.Dialogs.Login
|
|||
{
|
||||
var dialog = new LoginChoiceEagerDialog(_account);
|
||||
|
||||
if (await dialog.ShowDialogAsync() is not DialogResult.OK)
|
||||
if (await dialog.ShowDialogAsync() is not DialogResult.OK || string.IsNullOrWhiteSpace(dialog.Password))
|
||||
return null;
|
||||
|
||||
switch (dialog.LoginMethod)
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ using Avalonia;
|
|||
using Avalonia.Controls;
|
||||
using Avalonia.Markup.Xaml;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace LibationAvalonia.Dialogs.Login
|
||||
{
|
||||
|
|
@ -31,6 +32,17 @@ namespace LibationAvalonia.Dialogs.Login
|
|||
DataContext = this;
|
||||
}
|
||||
|
||||
protected override async Task SaveAndCloseAsync()
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(Password))
|
||||
{
|
||||
await MessageBox.Show(this, "Please enter your password");
|
||||
return;
|
||||
}
|
||||
|
||||
await base.SaveAndCloseAsync();
|
||||
}
|
||||
|
||||
public async void ExternalLoginLink_Tapped(object sender, Avalonia.Input.TappedEventArgs e)
|
||||
{
|
||||
LoginMethod = LoginMethod.External;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue