fix: Silence false positive sequelize class fields warning (#13224)

sequelize-strict-attributes defines per-instance accessors for attributes
omitted from a query's selection, which trips Sequelize's public class field
detection. The removed `Fix` decorator used to suppress this per model; do it
once on the base model instead.
This commit is contained in:
Tom Moor
2026-08-01 11:47:37 -04:00
committed by GitHub
parent b67b7a24a8
commit a6b5898283
+7
View File
@@ -50,6 +50,13 @@ class Model<
TModelAttributes extends object = any,
TCreationAttributes extends object = TModelAttributes,
> extends SequelizeModel<TModelAttributes, TCreationAttributes> {
/**
* Disables Sequelize's public class field detection, which reports a false positive for the
* per-instance accessors that sequelize-strict-attributes installs on attributes omitted from
* a query's selection.
*/
static _overwrittenAttributesChecked = true;
/**
* The namespace to use for events - defaults to the table name if none is provided.
*/