[fractal/bilelmoussaoui/bump-gtk-rs: 36/36] fix related cargo warnings
- From: Daniel Garcia Moreno <danigm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [fractal/bilelmoussaoui/bump-gtk-rs: 36/36] fix related cargo warnings
- Date: Fri, 21 Aug 2020 12:07:57 +0000 (UTC)
commit 2fa4a0a866f202a24e7ed2b6b962007dcae117de
Author: Bilal Elmoussaoui <bil elmoussaoui gmail com>
Date: Mon Aug 3 12:53:32 2020 +0200
fix related cargo warnings
fractal-gtk/src/app/connect/account.rs | 20 +++++++++-----------
1 file changed, 9 insertions(+), 11 deletions(-)
---
diff --git a/fractal-gtk/src/app/connect/account.rs b/fractal-gtk/src/app/connect/account.rs
index 3cc96e15..115a5345 100644
--- a/fractal-gtk/src/app/connect/account.rs
+++ b/fractal-gtk/src/app/connect/account.rs
@@ -105,17 +105,15 @@ impl App {
let button = name_btn.clone();
name_entry.connect_property_text_notify(clone!(@strong op => move |w| {
let username = w.get_text();
- if username != "" {
- if op.try_lock()
- .ok()
- .and_then(|guard| guard.login_data.clone())
- .and_then(|login_data| login_data.username)
- .filter(|u| *u != username)
- .is_some()
- {
- button.show();
- return;
- }
+ if username != "" && op.try_lock()
+ .ok()
+ .and_then(|guard| guard.login_data.clone())
+ .and_then(|login_data| login_data.username)
+ .filter(|u| *u != username)
+ .is_some()
+ {
+ button.show();
+ return;
}
button.hide();
}));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]