We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e93f16c commit 628fc08Copy full SHA for 628fc08
crates/core/src/crud_vtab.rs
@@ -109,7 +109,7 @@ impl VirtualTable {
109
let metadata = args[5];
110
let data = Self::value_to_json(&args[3]);
111
112
- if flags.include_old_only_when_changed()
+ if flags.ignore_empty_update()
113
&& op == "PATCH"
114
&& data.map(|r| r.get()) == Some("{}")
115
{
crates/core/src/schema/table_info.rs
@@ -149,6 +149,10 @@ impl TableInfoFlags {
149
self.0 & Self::INCLUDE_OLD_ONLY_WHEN_CHANGED != 0
150
}
151
152
+ pub const fn ignore_empty_update(self) -> bool {
153
+ self.0 & Self::IGNORE_EMPTY_UPDATE != 0
154
+ }
155
+
156
const fn with_flag(self, flag: u32) -> Self {
157
Self(self.0 | flag)
158
0 commit comments