From 4e2110bf25618cd23c1570fa558d71924dcc90b2 Mon Sep 17 00:00:00 2001 From: Matchu Date: Tue, 18 Jun 2024 15:26:28 -0700 Subject: [PATCH] Add comment to `Item#inferred_dyeworks_base_item` --- app/models/item/dyeworks.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/models/item/dyeworks.rb b/app/models/item/dyeworks.rb index d79602bb..a5ccb9d0 100644 --- a/app/models/item/dyeworks.rb +++ b/app/models/item/dyeworks.rb @@ -40,6 +40,10 @@ class Item nc_trade_value.value_text.match?(DYEWORKS_LIMITED_PATTERN) end + # Infer what base item this Dyeworks item probably relates to, based on + # their names. We only use this when a new item is modeled to initialize + # the `dyeworks_base_item` relationship in the database; after that, we + # just use whatever the database says. (This allows manual overrides!) DYEWORKS_NAME_PATTERN = %r{ ^( # Most Dyeworks items have a colon in the name.