[tracker/tracker-needle-improved-tagging] tracker-needle: Don't use requires and check for null without use of "?"
- From: Martyn James Russell <mr src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/tracker-needle-improved-tagging] tracker-needle: Don't use requires and check for null without use of "?"
- Date: Wed, 5 Oct 2011 14:11:15 +0000 (UTC)
commit 93b9a2d262796a22f19f71434efc4f8f4d3253f4
Author: Martyn Russell <martyn lanedo com>
Date: Wed Oct 5 15:10:19 2011 +0100
tracker-needle: Don't use requires and check for null without use of "?"
This is done by Vala
src/tracker-needle/tracker-tags-view.vala | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/tracker-needle/tracker-tags-view.vala b/src/tracker-needle/tracker-tags-view.vala
index ad73c9f..be23a65 100644
--- a/src/tracker-needle/tracker-tags-view.vala
+++ b/src/tracker-needle/tracker-tags-view.vala
@@ -87,7 +87,7 @@ public class TrackerTagsView : VBox {
TRUE = 1
}
- public TrackerTagsView (List<string> _files) requires (_files != null) {
+ public TrackerTagsView (List<string> _files) requires (_files.length () > 0) {
try {
connection = Sparql.Connection.get ();
} catch (GLib.Error e) {
@@ -699,7 +699,7 @@ public class TrackerTagsView : VBox {
td = null;
}
- private string sparql_get_filter_string (string? tag) requires (files != null) {
+ private string sparql_get_filter_string (string? tag) requires (files.length () > 0) {
string filter = "FILTER (";
if (tag != null && tag != "") {
@@ -726,7 +726,7 @@ public class TrackerTagsView : VBox {
return filter;
}
- private string sparql_get_escaped_string (string str) requires (str != null) {
+ private string sparql_get_escaped_string (string str) {
string escaped = Sparql.escape_string (str);
return "\"%s\"".printf (escaped);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]