[gnome-boxes] Remove redundant if block
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes] Remove redundant if block
- Date: Tue, 7 Feb 2012 22:19:07 +0000 (UTC)
commit c894eeb4afbd81566914a0a0cc9b80d1fe724997
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Wed Feb 8 00:14:29 2012 +0200
Remove redundant if block
src/wizard.vala | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/src/wizard.vala b/src/wizard.vala
index 5f78203..a6c9da9 100644
--- a/src/wizard.vala
+++ b/src/wizard.vala
@@ -199,9 +199,8 @@ private class Boxes.Wizard: Boxes.UI {
source = new CollectionSource (uri.server ?? uri_as_text, uri.scheme, uri_as_text);
- if (uri.scheme == "spice" || uri.scheme == "vnc") {
- // accept any spice:// or vnc:// uri
- } else
+ // Accept any spice:// or vnc:// uri but not any other
+ if (uri.scheme != "spice" && uri.scheme != "vnc")
throw new Boxes.Error.INVALID ("Unsupported protocol %s".printf (uri.scheme));
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]