object: clarify comment

This commit is contained in:
Emi Gutekanst 2024-11-27 18:30:21 -07:00
parent 314b761b71
commit a43ffcacc2

View file

@ -316,8 +316,9 @@ pub fn Objects(options: ObjectsOptions, comptime T: type) type {
return unpacked; return unpacked;
} }
/// Returns true if the field has an `updated` bit set in internal, after setting the bit /// If options have tracking enabled, this returns true when the given field has been set using the set()
/// back to false. /// or setAll() methods. A subsequent call to .updated() will return false until another set() or setAll()
/// call is made.
pub fn updated(objs: *@This(), id: ObjectID, field_name: anytype) bool { pub fn updated(objs: *@This(), id: ObjectID, field_name: anytype) bool {
if (options.track_fields) { if (options.track_fields) {
const unpacked = objs.validateAndUnpack(id, "updated"); const unpacked = objs.validateAndUnpack(id, "updated");