src/strip.vala
[app.mailtrimmer] / src / strip.vala
index c8ebbd6..b26230a 100644 (file)
@@ -370,7 +370,7 @@ public class Strip : GLib.Object {
        
        // initialize it with known data..
        // that should wipe out dupes.
-       var filesize = this.query("SELECT filesize FROM Attachment WHERE id = %d".printf(
+       var filesize = this.exect("SELECT filesize FROM Attachment WHERE id = %d".printf(
                        int.parse(sid)));       
                if (int.parse(filesize) < 1) {
                GLib.debug("Could not get filesize from id :%s = %s", sid,filesize);
@@ -608,7 +608,7 @@ public class Strip : GLib.Object {
                
                }
                if (!need_return) {
-                       return "";
+                       return got_row ? "" : ret;
                }
                if (!got_row) {
                         GLib.debug("ERROR : no rows returned");