aboutsummaryrefslogtreecommitdiff
path: root/qlite/src/update_builder.vala
diff options
context:
space:
mode:
authorMarvin W <git@larma.de>2017-03-09 21:46:16 +0100
committerMarvin W <git@larma.de>2017-03-10 17:33:27 +0100
commit93fd134a92fb50cc6e8a9b5db3d6f25e84e6fa10 (patch)
tree760dffada9b7d3515df5be306fe3a2ae9d848a64 /qlite/src/update_builder.vala
parent9b8cf706d6b0ff83472af53c31b96c4c2f55f6b7 (diff)
downloaddino-93fd134a92fb50cc6e8a9b5db3d6f25e84e6fa10.tar.gz
dino-93fd134a92fb50cc6e8a9b5db3d6f25e84e6fa10.zip
Fix bugs and warnings in qlite
Diffstat (limited to 'qlite/src/update_builder.vala')
-rw-r--r--qlite/src/update_builder.vala6
1 files changed, 3 insertions, 3 deletions
diff --git a/qlite/src/update_builder.vala b/qlite/src/update_builder.vala
index 5f721a32..41fd28b2 100644
--- a/qlite/src/update_builder.vala
+++ b/qlite/src/update_builder.vala
@@ -48,7 +48,7 @@ public class UpdateBuilder : StatementBuilder {
return this;
}
- public UpdateBuilder set_null<T>(Column<T> column) {
+ public UpdateBuilder set_null<T>(Column<T> column) throws DatabaseError {
if (column.not_null) throw new DatabaseError.ILLEGAL_QUERY(@"Can't set non-null column $(column.name) to null");
if (fields == null) {
fields = { new NullField<T>(column) };
@@ -63,8 +63,8 @@ public class UpdateBuilder : StatementBuilder {
return this;
}
- public UpdateBuilder where(string selection, string[]? selection_args = null) {
- if (selection != null) throw new DatabaseError.ILLEGAL_QUERY("selection was already done, but where() was called.");
+ public UpdateBuilder where(string selection, string[]? selection_args = null) throws DatabaseError {
+ if (this.selection != null) throw new DatabaseError.ILLEGAL_QUERY("selection was already done, but where() was called.");
this.selection = selection;
if (selection_args != null) {
this.selection_args = new StatementBuilder.Field[selection_args.length];