{"$schema":"https://json.schemastore.org/sarif-2.1.0.json","version":"2.1.0","runs":[{"tool":{"driver":{"name":"codehealth","informationUri":"https://codehealth.canine.dev","rules":[{"id":"D1","name":"Cyclomatic Complexity","shortDescription":{"text":"Cyclomatic Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D1"},{"id":"D2","name":"Cognitive Complexity","shortDescription":{"text":"Cognitive Complexity"},"helpUri":"https://codehealth.canine.dev/dimensions/D2"},{"id":"D3","name":"God Classes","shortDescription":{"text":"God Classes"},"helpUri":"https://codehealth.canine.dev/dimensions/D3"},{"id":"D4","name":"Code Duplication","shortDescription":{"text":"Code Duplication"},"helpUri":"https://codehealth.canine.dev/dimensions/D4"},{"id":"D6","name":"Cohesion (LCOM4)","shortDescription":{"text":"Cohesion (LCOM4)"},"helpUri":"https://codehealth.canine.dev/dimensions/D6"},{"id":"D8","name":"Code Coverage","shortDescription":{"text":"Code Coverage"},"helpUri":"https://codehealth.canine.dev/dimensions/D8"},{"id":"D11","name":"Test Reliability","shortDescription":{"text":"Test Reliability"},"helpUri":"https://codehealth.canine.dev/dimensions/D11"},{"id":"D12","name":"Dependency Hygiene","shortDescription":{"text":"Dependency Hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/D12"},{"id":"D13","name":"Secret Scanning","shortDescription":{"text":"Secret Scanning"},"helpUri":"https://codehealth.canine.dev/dimensions/D13","relationships":[{"target":{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A07:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-798","CWE-259"],"owasp":"A07:2025"}},{"id":"D14","name":"License Compliance","shortDescription":{"text":"License Compliance"},"helpUri":"https://codehealth.canine.dev/dimensions/D14"},{"id":"D15","name":"Churn \u00D7 Complexity Hotspots","shortDescription":{"text":"Churn \u00D7 Complexity Hotspots"},"helpUri":"https://codehealth.canine.dev/dimensions/D15"},{"id":"D16","name":"Bus Factor","shortDescription":{"text":"Bus Factor"},"helpUri":"https://codehealth.canine.dev/dimensions/D16"},{"id":"D17","name":"Explicit Debt","shortDescription":{"text":"Explicit Debt"},"helpUri":"https://codehealth.canine.dev/dimensions/D17"},{"id":"D19","name":"Documentation Quality","shortDescription":{"text":"Documentation Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D19"},{"id":"D20","name":"ADR Quality","shortDescription":{"text":"ADR Quality"},"helpUri":"https://codehealth.canine.dev/dimensions/D20"},{"id":"D21","name":"Naming Consistency","shortDescription":{"text":"Naming Consistency"},"helpUri":"https://codehealth.canine.dev/dimensions/D21"},{"id":"D23","name":"Boundary Type-Coupling","shortDescription":{"text":"Boundary Type-Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D23"},{"id":"D26","name":"Project Cohesion","shortDescription":{"text":"Project Cohesion"},"helpUri":"https://codehealth.canine.dev/dimensions/D26"},{"id":"D27","name":"Navigability","shortDescription":{"text":"Navigability"},"helpUri":"https://codehealth.canine.dev/dimensions/D27"},{"id":"D29","name":"Static Analysis (SAST)","shortDescription":{"text":"Static Analysis (SAST)"},"helpUri":"https://codehealth.canine.dev/dimensions/D29","relationships":[{"target":{"id":"CWE-79","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-78","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-94","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-77","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-79","CWE-89","CWE-78","CWE-94","CWE-77"],"owasp":"A05:2025"}},{"id":"D30","name":"Dependency Vulnerabilities","shortDescription":{"text":"Dependency Vulnerabilities"},"helpUri":"https://codehealth.canine.dev/dimensions/D30","relationships":[{"target":{"id":"CWE-1395","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-937","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1395","CWE-937"],"owasp":"A03:2025"}},{"id":"D31","name":"IaC \u0026 Container Security","shortDescription":{"text":"IaC \u0026 Container Security"},"helpUri":"https://codehealth.canine.dev/dimensions/D31","relationships":[{"target":{"id":"CWE-1032","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-732","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-16","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-1032","CWE-732","CWE-16"],"owasp":"A02:2025"}},{"id":"D32","name":"Data Compliance (PII/GDPR)","shortDescription":{"text":"Data Compliance (PII/GDPR)"},"helpUri":"https://codehealth.canine.dev/dimensions/D32","relationships":[{"target":{"id":"CWE-359","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-312","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"CWE-200","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A01:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-359","CWE-312","CWE-200"],"owasp":"A01:2025"}},{"id":"D34","name":"Knowledge Freshness","shortDescription":{"text":"Knowledge Freshness"},"helpUri":"https://codehealth.canine.dev/dimensions/D34"},{"id":"D35","name":"Change Coupling","shortDescription":{"text":"Change Coupling"},"helpUri":"https://codehealth.canine.dev/dimensions/D35"},{"id":"D43","name":"Malicious Dependencies","shortDescription":{"text":"Malicious Dependencies"},"helpUri":"https://codehealth.canine.dev/dimensions/D43","relationships":[{"target":{"id":"CWE-506","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},"kinds":["relevant"]},{"target":{"id":"A08:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}},"kinds":["relevant"]}],"properties":{"cwe":["CWE-506"],"owasp":"A08:2025"}},{"id":"D44","name":"Platform End-of-Life","shortDescription":{"text":"Platform End-of-Life"},"helpUri":"https://codehealth.canine.dev/dimensions/D44"},{"id":"AC1","name":"Text alternatives","shortDescription":{"text":"Text alternatives"},"helpUri":"https://codehealth.canine.dev/dimensions/AC1"},{"id":"AC2","name":"Forms \u0026 labels","shortDescription":{"text":"Forms \u0026 labels"},"helpUri":"https://codehealth.canine.dev/dimensions/AC2"},{"id":"AC3","name":"Page structure","shortDescription":{"text":"Page structure"},"helpUri":"https://codehealth.canine.dev/dimensions/AC3"},{"id":"AC4","name":"Keyboard semantics","shortDescription":{"text":"Keyboard semantics"},"helpUri":"https://codehealth.canine.dev/dimensions/AC4"},{"id":"AC5","name":"ARIA correctness","shortDescription":{"text":"ARIA correctness"},"helpUri":"https://codehealth.canine.dev/dimensions/AC5"},{"id":"AC6","name":"Visual \u0026 motion safety","shortDescription":{"text":"Visual \u0026 motion safety"},"helpUri":"https://codehealth.canine.dev/dimensions/AC6"},{"id":"AX10","name":"Code composition","shortDescription":{"text":"Code composition"},"helpUri":"https://codehealth.canine.dev/dimensions/AX10"},{"id":"AX2","name":"Stateful singletons","shortDescription":{"text":"Stateful singletons"},"helpUri":"https://codehealth.canine.dev/dimensions/AX2"},{"id":"AX3","name":"Project dependency cycles","shortDescription":{"text":"Project dependency cycles"},"helpUri":"https://codehealth.canine.dev/dimensions/AX3"},{"id":"AX4","name":"Dependency direction","shortDescription":{"text":"Dependency direction"},"helpUri":"https://codehealth.canine.dev/dimensions/AX4"},{"id":"AX6","name":"Interface segregation","shortDescription":{"text":"Interface segregation"},"helpUri":"https://codehealth.canine.dev/dimensions/AX6"},{"id":"DM1","name":"Aggregate boundaries","shortDescription":{"text":"Aggregate boundaries"},"helpUri":"https://codehealth.canine.dev/dimensions/DM1"},{"id":"DM10","name":"One transaction, one aggregate","shortDescription":{"text":"One transaction, one aggregate"},"helpUri":"https://codehealth.canine.dev/dimensions/DM10"},{"id":"DM11","name":"Constructible invalid state","shortDescription":{"text":"Constructible invalid state"},"helpUri":"https://codehealth.canine.dev/dimensions/DM11"},{"id":"DM12","name":"Ambient inputs in the domain","shortDescription":{"text":"Ambient inputs in the domain"},"helpUri":"https://codehealth.canine.dev/dimensions/DM12"},{"id":"DM2","name":"Strongly-typed ids","shortDescription":{"text":"Strongly-typed ids"},"helpUri":"https://codehealth.canine.dev/dimensions/DM2"},{"id":"DM4","name":"Rich vs anemic model","shortDescription":{"text":"Rich vs anemic model"},"helpUri":"https://codehealth.canine.dev/dimensions/DM4"},{"id":"DM5","name":"Encapsulated state","shortDescription":{"text":"Encapsulated state"},"helpUri":"https://codehealth.canine.dev/dimensions/DM5"},{"id":"DM6","name":"Domain \u2194 infrastructure boundary","shortDescription":{"text":"Domain \u2194 infrastructure boundary"},"helpUri":"https://codehealth.canine.dev/dimensions/DM6"},{"id":"DM7","name":"Repository granularity","shortDescription":{"text":"Repository granularity"},"helpUri":"https://codehealth.canine.dev/dimensions/DM7"},{"id":"DM9","name":"Scattered domain decisions","shortDescription":{"text":"Scattered domain decisions"},"helpUri":"https://codehealth.canine.dev/dimensions/DM9"},{"id":"ED5","name":"Idempotency","shortDescription":{"text":"Idempotency"},"helpUri":"https://codehealth.canine.dev/dimensions/ED5"},{"id":"M1","name":"Documentation (README)","shortDescription":{"text":"Documentation (README)"},"helpUri":"https://codehealth.canine.dev/dimensions/M1"},{"id":"M2","name":"Architecture documentation","shortDescription":{"text":"Architecture documentation"},"helpUri":"https://codehealth.canine.dev/dimensions/M2"},{"id":"M3","name":"Folder \u0026 project structure","shortDescription":{"text":"Folder \u0026 project structure"},"helpUri":"https://codehealth.canine.dev/dimensions/M3"},{"id":"M4","name":"Documentation accuracy","shortDescription":{"text":"Documentation accuracy"},"helpUri":"https://codehealth.canine.dev/dimensions/M4"},{"id":"P1","name":"CI/CD gates","shortDescription":{"text":"CI/CD gates"},"helpUri":"https://codehealth.canine.dev/dimensions/P1"},{"id":"P2","name":"Observability","shortDescription":{"text":"Observability"},"helpUri":"https://codehealth.canine.dev/dimensions/P2"},{"id":"P3","name":"Security \u0026 performance tooling","shortDescription":{"text":"Security \u0026 performance tooling"},"helpUri":"https://codehealth.canine.dev/dimensions/P3"},{"id":"P4","name":"Deployment \u0026 Rollback","shortDescription":{"text":"Deployment \u0026 Rollback"},"helpUri":"https://codehealth.canine.dev/dimensions/P4"},{"id":"P5","name":"DR \u0026 Backup","shortDescription":{"text":"DR \u0026 Backup"},"helpUri":"https://codehealth.canine.dev/dimensions/P5"},{"id":"P7","name":"Outbound HTTP resilience","shortDescription":{"text":"Outbound HTTP resilience"},"helpUri":"https://codehealth.canine.dev/dimensions/P7"},{"id":"P8","name":"Schema migrations","shortDescription":{"text":"Schema migrations"},"helpUri":"https://codehealth.canine.dev/dimensions/P8"},{"id":"P9","name":"Domain vs controller coverage","shortDescription":{"text":"Domain vs controller coverage"},"helpUri":"https://codehealth.canine.dev/dimensions/P9"},{"id":"PF1","name":"Benchmark discipline","shortDescription":{"text":"Benchmark discipline"},"helpUri":"https://codehealth.canine.dev/dimensions/PF1"},{"id":"PF3","name":"Async \u0026 latency hygiene","shortDescription":{"text":"Async \u0026 latency hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/PF3"},{"id":"SC1","name":"Supply-chain hygiene","shortDescription":{"text":"Supply-chain hygiene"},"helpUri":"https://codehealth.canine.dev/dimensions/SC1"},{"id":"X10","name":"Duplicated predicate","shortDescription":{"text":"Duplicated predicate"},"helpUri":"https://codehealth.canine.dev/dimensions/X10"},{"id":"X13","name":"Undrained process stream","shortDescription":{"text":"Undrained process stream"},"helpUri":"https://codehealth.canine.dev/dimensions/X13"},{"id":"X14","name":"Bypassable address classification","shortDescription":{"text":"Bypassable address classification"},"helpUri":"https://codehealth.canine.dev/dimensions/X14"},{"id":"X15","name":"Unvalidated length from an untrusted reader","shortDescription":{"text":"Unvalidated length from an untrusted reader"},"helpUri":"https://codehealth.canine.dev/dimensions/X15"},{"id":"X17","name":"Uncapped recursion over a caller-supplied document","shortDescription":{"text":"Uncapped recursion over a caller-supplied document"},"helpUri":"https://codehealth.canine.dev/dimensions/X17"},{"id":"X19","name":"Unrestored process-global state","shortDescription":{"text":"Unrestored process-global state"},"helpUri":"https://codehealth.canine.dev/dimensions/X19"},{"id":"X2","name":"Cancellation propagation","shortDescription":{"text":"Cancellation propagation"},"helpUri":"https://codehealth.canine.dev/dimensions/X2"},{"id":"X20","name":"Mistyped argument guard","shortDescription":{"text":"Mistyped argument guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X20"},{"id":"X21","name":"Side-effecting pattern guard","shortDescription":{"text":"Side-effecting pattern guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X21"},{"id":"X22","name":"Contradicted release guard","shortDescription":{"text":"Contradicted release guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X22"},{"id":"X23","name":"Unguarded diagnostic materialisation","shortDescription":{"text":"Unguarded diagnostic materialisation"},"helpUri":"https://codehealth.canine.dev/dimensions/X23"},{"id":"X26","name":"Unsynchronised callback handoff","shortDescription":{"text":"Unsynchronised callback handoff"},"helpUri":"https://codehealth.canine.dev/dimensions/X26"},{"id":"X27","name":"Collection changed while being enumerated","shortDescription":{"text":"Collection changed while being enumerated"},"helpUri":"https://codehealth.canine.dev/dimensions/X27"},{"id":"X28","name":"Index access outside its own emptiness guard","shortDescription":{"text":"Index access outside its own emptiness guard"},"helpUri":"https://codehealth.canine.dev/dimensions/X28"},{"id":"X3","name":"Exception handling","shortDescription":{"text":"Exception handling"},"helpUri":"https://codehealth.canine.dev/dimensions/X3"},{"id":"X30","name":"Support guard that admits what it rejects","shortDescription":{"text":"Support guard that admits what it rejects"},"helpUri":"https://codehealth.canine.dev/dimensions/X30"},{"id":"X32","name":"Type resolved by simple name across every loaded assembly","shortDescription":{"text":"Type resolved by simple name across every loaded assembly"},"helpUri":"https://codehealth.canine.dev/dimensions/X32"},{"id":"X4","name":"Structured logging","shortDescription":{"text":"Structured logging"},"helpUri":"https://codehealth.canine.dev/dimensions/X4"},{"id":"X6","name":"Hand-rolled structured-format parsing","shortDescription":{"text":"Hand-rolled structured-format parsing"},"helpUri":"https://codehealth.canine.dev/dimensions/X6"},{"id":"X7","name":"Silent fallback defaults","shortDescription":{"text":"Silent fallback defaults"},"helpUri":"https://codehealth.canine.dev/dimensions/X7"},{"id":"X9","name":"Subsumed condition operand","shortDescription":{"text":"Subsumed condition operand"},"helpUri":"https://codehealth.canine.dev/dimensions/X9"}]}},"results":[{"ruleId":"D1","level":"warning","message":{"text":"ReadModelChangeListener.handlePayload (cyclomatic 144): ReadModelChangeListener.handlePayload has cyclomatic complexity 144 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_listener.go"},"region":{"startLine":381}}}],"partialFingerprints":{"codehealthFindingId/v1":"b50ab3569473beac5227683b11f79b5834d85ab69b92708aa0b5786d111122f0"}},{"ruleId":"D1","level":"warning","message":{"text":"main.run (cyclomatic 136): main.run has cyclomatic complexity 136 (threshold 15). Of this number, 134 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"d12105d4cf5d1536db5aaf545b077661ed59cb13fcb44045f0bdf4f7d9db8551"}},{"ruleId":"D1","level":"warning","message":{"text":"config.Load (cyclomatic 109): config.Load has cyclomatic complexity 109 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":958}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d48e9a2bc01ff18f20ea1c695d9f3a3b233bc10075d8d7cdd9e8ce9e0776ffa"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.prepareInboundLayerRPCBatch (cyclomatic 109): Server.prepareInboundLayerRPCBatch has cyclomatic complexity 109 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"0efd7547793df834173b4e69437de7e664df9e8aec9f9abbc05caac1c22c945f"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.registerMessages (cyclomatic 105): Router.registerMessages has cyclomatic complexity 105 (threshold 15). Most of this is not in the body itself: 1 of the 105 points is its own statement and the rest belongs to 7 function literals inside it that branch (lines 713, 493, 416, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_register.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb3d2f6577909a7004f99cc896ec9d34f18ebc1d7f14efda24d3065ad2ffae4b"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginRequest.Validate (cyclomatic 100): TelegramLoginRequest.Validate has cyclomatic complexity 100 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/telegram_login.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"962dd68337587dd3c76819466815fda4cf7f098d93de6ebba99086a3a998c5ef"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgOtherUpdateFromEvent (cyclomatic 98): rpc.tgOtherUpdateFromEvent has cyclomatic complexity 98 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"38b2685c28c94e0df5bb831d05e098d1cffee3647dc02bb2d0d0fbdd80cae50a"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.sendPrivateTextOnce (cyclomatic 96): MessageStore.sendPrivateTextOnce has cyclomatic complexity 96 (threshold 15). Of this number, 95 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cc0cfd794bf153c505c76a84e1cde5dab46fc7290b97e9c9e6ba3230d792e4e"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesForwardMessages (cyclomatic 82): Router.onMessagesForwardMessages has cyclomatic complexity 82 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f0fb2201c0c50b9c26e56a176b67d2dc412a097789ebf8f2d381614ae281f20"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.CraftStarGift (cyclomatic 80): StarGiftLifecycleStore.CraftStarGift has cyclomatic complexity 80 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 52 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"333771d45c54db43ebd9cbd8eaa084e51bac4dc0d0ac8422bfd69510e6baee14"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelHistory (cyclomatic 78): ChannelStore.ListChannelHistory has cyclomatic complexity 78 (threshold 15). Of this number, 63 points are the body\u0027s own statements and 15 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"5970d3e7d066963d4b62edba750f59151948330d57f12ad24b628684401f239c"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.sendChannelMessageOnce (cyclomatic 78): ChannelStore.sendChannelMessageOnce has cyclomatic complexity 78 (threshold 15). Of this number, 77 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"c670ad866f2537543440f81488da46ed3f955633dbc86fc600399826019f3e7a"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.resolveInputMedia (cyclomatic 76): Router.resolveInputMedia has cyclomatic complexity 76 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":630}}}],"partialFingerprints":{"codehealthFindingId/v1":"6144fdc23b93de318d684e1af3f970af06bff753a5292e7f3fc5f9e885578f20"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditChannelMessage (cyclomatic 76): ChannelStore.EditChannelMessage has cyclomatic complexity 76 (threshold 15). Of this number, 75 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa03135d621fe60ca08f7c31da7f37aa59679d2299d174e8c16f6d52a2de16bd"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.EditMessage (cyclomatic 74): MessageStore.EditMessage has cyclomatic complexity 74 (threshold 15). Of this number, 73 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5ddc45acd625de289fab114bf814ed8145f4f8f010a34e153f723d65ff6a57e"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.parseBotAPIMarkdownV2 (cyclomatic 70): botapi.parseBotAPIMarkdownV2 has cyclomatic complexity 70 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":645}}}],"partialFingerprints":{"codehealthFindingId/v1":"411cf7d38d8af45b3460e8aa23d6c87e007a6652c33d8a52ce22bf24a6135e20"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftUpgradeStore.UpgradeStarGift (cyclomatic 70): StarGiftUpgradeStore.UpgradeStarGift has cyclomatic complexity 70 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 42 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fe2873ef921c29686468f2bf02f89d4281f10755422e8644d294a3784f028e6"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelHistory (cyclomatic 67): ChannelStore.ListChannelHistory has cyclomatic complexity 67 (threshold 15). Of this number, 51 points are the body\u0027s own statements and 16 belong to 6 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e4955c8db7ba6b4b0cda22cf775e777fc953395ed0e7c042f4aec61500afe6a"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.validateMarkupButton (cyclomatic 65): domain.validateMarkupButton has cyclomatic complexity 65 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_markup.go"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d25d288c8b2b2981611524403b6f1a908c786cd0ed36618f0adef10f5e0413b"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetDiscussionGroup (cyclomatic 64): ChannelStore.SetDiscussionGroup has cyclomatic complexity 64 (threshold 15). Of this number, 58 points are the body\u0027s own statements and 6 belong to 4 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":1121}}}],"partialFingerprints":{"codehealthFindingId/v1":"35573b1ee721dbc674c59168806d7c60cb21c28e829fa9d5b59892ed7bcbda6d"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ToggleSuggestedPostApproval (cyclomatic 64): ChannelStore.ToggleSuggestedPostApproval has cyclomatic complexity 64 (threshold 15). Of this number, 63 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ace4766e52e34abf62f9a19a80dee687ed063ff400b448836d5c7b410b5f8c0"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.PurchaseResaleStarGift (cyclomatic 64): StarGiftLifecycleStore.PurchaseResaleStarGift has cyclomatic complexity 64 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 39 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"0618affaf3be118a77ce58dc9a450d04197a03751bd556845c846cc7e9ca6b00"}},{"ruleId":"D1","level":"warning","message":{"text":"main.doFetch (cyclomatic 63): main.doFetch has cyclomatic complexity 63 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 38 belong to 7 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/appearancefetch/main.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c563065794fb657ef5057298a5ccbbf6083f699fdb2e28b003ad1aeea883587"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.sendFromBot (cyclomatic 61): Service.sendFromBot has cyclomatic complexity 61 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"cef84494dffc175dde190c9d5f3a5691c797f19b7401ced5b3bc7adc4eff201c"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.StartupRun (cyclomatic 61): loadharness.StartupRun has cyclomatic complexity 61 (threshold 15). Of this number, 55 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"6af8495725a314662d50c99772447a9023171f5e7b8c765878c35ee44c290c1c"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditChannelMessage (cyclomatic 60): ChannelStore.EditChannelMessage has cyclomatic complexity 60 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6d93926eec2fa0e70db9575337d16cd3af6477af71731c6196289fcf404d499"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.finishDeleteMessagesTx (cyclomatic 59): MessageStore.finishDeleteMessagesTx has cyclomatic complexity 59 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b25038c0811be9498c0b38f4b07aa49759d6f563ed06379cd31e6cc87d85e58"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelStats (cyclomatic 57): ChannelStore.GetChannelStats has cyclomatic complexity 57 (threshold 15). Of this number, 55 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"829a04538934336b249f8e5b565e586e46ba104eea74405430ec76d348f008a4"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CreateAuthorization (cyclomatic 55): Service.CreateAuthorization has cyclomatic complexity 55 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"52129771491ae6b3971efb0208dd47ba7350a745b0650d3345aea5c5f066b808"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SendMonoforumMessage (cyclomatic 55): ChannelStore.SendMonoforumMessage has cyclomatic complexity 55 (threshold 15). Of this number, 54 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_monoforum.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7bccc003b2eb378f746d17438b2355ecd6473ed59fa86b845535b759c3ec5b3"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.Run (cyclomatic 54): loadharness.Run has cyclomatic complexity 54 (threshold 15). Of this number, 52 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":738}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ebedbf9e42259e4a0c07c37f621934e9846dfa7c18299ef48f641db0d42aaa2"}},{"ruleId":"D1","level":"warning","message":{"text":"UserStore.claimOfficialUsernameOnce (cyclomatic 54): UserStore.claimOfficialUsernameOnce has cyclomatic complexity 54 (threshold 15). Of this number, 51 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"31261d899aca7c8c7bf2c23f49c2b06dd1d3f204a5f524af23cc409d59260efa"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.domainPollFromInputMedia (cyclomatic 53): Router.domainPollFromInputMedia has cyclomatic complexity 53 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_polls.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"506f6be58f349a9d8d5933f1fd20251902532baa6d0e90af4c4ba36c6f353493"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SendChannelMessage (cyclomatic 53): ChannelStore.SendChannelMessage has cyclomatic complexity 53 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff300e7126b574ebfcd78ac20ab4bf9484db90ef8abb7b4f5c3570381b2dca93"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.listChannelDialogs (cyclomatic 52): ChannelStore.listChannelDialogs has cyclomatic complexity 52 (threshold 15). Of this number, 48 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"13fb1f89d052e2e38a8713df7ac215ec873e9778f0539582d8d816772c34c957"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelStats (cyclomatic 52): ChannelStore.GetChannelStats has cyclomatic complexity 52 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"c176555356579aca84c6c075c1126c9850cee42ca4c3cb67b57b6e938b382682"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftUpgradeStore.GrantUniqueStarGift (cyclomatic 52): StarGiftUpgradeStore.GrantUniqueStarGift has cyclomatic complexity 52 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 27 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"efb9e27f1d1ca01d4803d3d096e1ea8542a5fa7b3cdfe79bfaff1bbb6e4bf89d"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftUpgradeStore.markPrivateStarGiftSourceUpgradedTx (cyclomatic 52): StarGiftUpgradeStore.markPrivateStarGiftSourceUpgradedTx has cyclomatic complexity 52 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":703}}}],"partialFingerprints":{"codehealthFindingId/v1":"b579ad4e5fe35c2c1e97edf3be69af4d15d2d27b27f04951707046f6a4594776"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.scanBotAPIHTMLTag (cyclomatic 50): botapi.scanBotAPIHTMLTag has cyclomatic complexity 50 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7d851352232c8cd470baa385c8f8179d50edc159b45e3da9f09974d2351357c"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.collectRichMessageBlockMetrics (cyclomatic 50): rpc.collectRichMessageBlockMetrics has cyclomatic complexity 50 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/rich_message_limits.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"849c2e5478ff05c0c064f694e0ae568bd2350b79c74171e62db1714a9d41437c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesEditMessage (cyclomatic 50): Router.onMessagesEditMessage has cyclomatic complexity 50 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2ab37768d8bbaab8d074f5287f46ab58bb344bc6109a3d23e614feae41c7d11"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SearchJoinedMessages (cyclomatic 50): ChannelStore.SearchJoinedMessages has cyclomatic complexity 50 (threshold 15). Of this number, 48 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f8c8894133706d3b1bb95cb793c16400b8e127606285de2e3a8fa6c534efa8e"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ReadMessageContents (cyclomatic 50): MessageStore.ReadMessageContents has cyclomatic complexity 50 (threshold 15). Of this number, 49 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_read.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5712b287e7a4ab66ebcd16c6044880910d956aabbb05c952d5444325e21daba"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SignUp (cyclomatic 49): Service.SignUp has cyclomatic complexity 49 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1281}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f263fac37b6dcd418bb384c8bb8c8b2b3930d2e26a6f7b30dc588629d4436c9"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSendMedia (cyclomatic 49): Router.onMessagesSendMedia has cyclomatic complexity 49 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"a278d7cb938e2b6dbd7de33af74a52a9c8ac4958357e876408ac13be047c6ce8"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetChannelMessageReactions (cyclomatic 49): ChannelStore.SetChannelMessageReactions has cyclomatic complexity 49 (threshold 15). Of this number, 48 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b574dddd9c8bf5e8a52128f4762d1de3db6f2d9b3d9b1dfaae3647d244efd7f"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.retireUserStarGiftMessagesTx (cyclomatic 49): StarGiftLifecycleStore.retireUserStarGiftMessagesTx has cyclomatic complexity 49 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle_projection.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"f821dcd94e17eb7663c00f61adfd3db2cd8f3e92fce29b594139a26878ca508b"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.VerifyLoginEmail (cyclomatic 48): Service.VerifyLoginEmail has cyclomatic complexity 48 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":870}}}],"partialFingerprints":{"codehealthFindingId/v1":"8726a649591675daa1c33286e0307db653ab5d31e107a0f2628df41a46cf6aa2"}},{"ruleId":"D1","level":"warning","message":{"text":"ActionExecutor.Execute (cyclomatic 48): ActionExecutor.Execute has cyclomatic complexity 48 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/actions.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"74efc87e4228319c18bbb19073478727675bef0b6a6421216b00b5f2e086b8ea"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.evaluateReport (cyclomatic 48): loadharness.evaluateReport has cyclomatic complexity 48 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1201}}}],"partialFingerprints":{"codehealthFindingId/v1":"75c20e31a91afc528e9a2f3f38a04c6d71514c60173fd6c673526a36e6c3ef43"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.sendSingleSendMessage (cyclomatic 48): Router.sendSingleSendMessage has cyclomatic complexity 48 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ddc1e0090a74d74a75be13254c1d4dbb3975d600d08e702c17eabc7de68858c"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgChannelMessage (cyclomatic 47): rpc.tgChannelMessage has cyclomatic complexity 47 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"72a19199e6e574c2974b6c5ce84e9bff373eeef826df40b4e83c47794bea6757"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.PublishAdmittedLayerProfileEvidence (cyclomatic 47): Router.PublishAdmittedLayerProfileEvidence has cyclomatic complexity 47 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_inheritance.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f93ad21d6c85ed3b0b6ce8fbcbc2be5bf7ebf8e8c520b17da6f62ede3fc0062"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReport.Validate (cyclomatic 46): ModerationReport.Validate has cyclomatic complexity 46 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fd593b8a8be455e90a5543073bd531c260cc3cfa98749afd4a920b29e51d11e"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.handleEncrypted (cyclomatic 46): Server.handleEncrypted has cyclomatic complexity 46 (threshold 15). Of this number, 45 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"2662bb7c175759af72cb77ac61ef4c63edc60794c6727eb9c87047a4900e7031"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.listChannelDifferenceAttempt (cyclomatic 46): ChannelStore.listChannelDifferenceAttempt has cyclomatic complexity 46 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"21d162f358cca1b1417a8e85657ffe169f4ce4edf3edd97c8385bbe44905b85c"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.sweep (cyclomatic 45): Service.sweep has cyclomatic complexity 45 (threshold 15). Of this number, 38 points are the body\u0027s own statements and 7 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/sweep.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd2a5399722b0999a8383b128f711383679e29280ac175154668d3bde41fe4fa"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.botAPIRichBlock (cyclomatic 45): rpc.botAPIRichBlock has cyclomatic complexity 45 (threshold 15). Of this number, 43 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"93997600e02814020d62ae5cb1251fcbb0b26e83c164c157e80f986db3742beb"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSendMultiMedia (cyclomatic 44): Router.onMessagesSendMultiMedia has cyclomatic complexity 44 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":464}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b8003dfedeacd3604ca1e12157459bebbe9738d9bca6eca60d73a641020ff86"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CanSeeForViewerUserIDs (cyclomatic 43): Service.CanSeeForViewerUserIDs has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service_sparse.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"28b25ee4bba31f2a3d5fa79ea72e6ada465f61b596cee2abacd65da28f8052e0"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionManager.pushToUserWithSender (cyclomatic 43): SessionManager.pushToUserWithSender has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1874}}}],"partialFingerprints":{"codehealthFindingId/v1":"e09eef8fd2be0553c61e1717b38d0bc74dd126170db73f2538a5f77d491d31b9"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.claimAuthLayerDefaultEvidenceLocked (cyclomatic 43): Router.claimAuthLayerDefaultEvidenceLocked has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_inheritance.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6147d30d50a6cfbb63e85379706af0f8d2b6b2b9a8ded4e7efefd1e376bc5b8"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPaymentsSendStarsForm (cyclomatic 43): Router.onPaymentsSendStarsForm has cyclomatic complexity 43 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"f75deea576f5e618f451f4bc123d833dc3b56a43a1af2789c5ac335ffbba5df7"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelDialogs (cyclomatic 43): ChannelStore.GetChannelDialogs has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":755}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c2eca24b575e1e4956f22ee92f2e333acd61d75d96d000eb3c205bdc69900ba"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.walkInbound (cyclomatic 42): Server.walkInbound has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c4a86d8cb36f8192005944e769cda9ab0b9a078a6dd54cf0f8100790a44e33f"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.peerIdentityMaps (cyclomatic 42): Router.peerIdentityMaps has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/peer_identity_cache.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"42367f9884fbea93bd25f515525eddcf7276cd10e843e54e6096dac96e21cdbd"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.dispatch (cyclomatic 42): Router.dispatch has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":675}}}],"partialFingerprints":{"codehealthFindingId/v1":"59905606e2e5999bfa6729d29097e986bade4efaceb41720b7340e8307b75ffd"}},{"ruleId":"D1","level":"warning","message":{"text":"memory.validateBotAPIUpdateRequest (cyclomatic 42): memory.validateBotAPIUpdateRequest has cyclomatic complexity 42 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ff7740b37b9a568f52b16e97c4bef6e88dd3bc47cfc7a8455189ae15fd14c86"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftStore.ListByOwnerFiltered (cyclomatic 42): StarGiftStore.ListByOwnerFiltered has cyclomatic complexity 42 (threshold 15). Of this number, 38 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"22c3dfb012bea9597c5d058a99e697ff144856b786a9e58beef3ab8ee61910d2"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.reconcileSeedWith (cyclomatic 42): postgres.reconcileSeedWith has cyclomatic complexity 42 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/langpack.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"06c5e7f637181f6b95e17da89aa02de877d90efea62ffe8caf2a6c5e148fb336"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.PrepayStarGiftUpgrade (cyclomatic 42): StarGiftLifecycleStore.PrepayStarGiftUpgrade has cyclomatic complexity 42 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 19 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_entitlements.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"148e7c6d9eadab17f1bdcbe1e8270e57808a62ab5ae8eedaefc0ebb5499adf47"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.ListResaleStarGifts (cyclomatic 42): StarGiftLifecycleStore.ListResaleStarGifts has cyclomatic complexity 42 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"7979fabf600d24a70b918a8bb3f224306b1e73635b99ea07c1bdfe156e9735fe"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.ResolveStarGiftOffer (cyclomatic 42): StarGiftLifecycleStore.ResolveStarGiftOffer has cyclomatic complexity 42 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 26 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":916}}}],"partialFingerprints":{"codehealthFindingId/v1":"dba5245887bb1246b7945641eba261dcbe2b0f53952268a6e26c155989f90259"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.executeInboundPlan (cyclomatic 41): Server.executeInboundPlan has cyclomatic complexity 41 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":935}}}],"partialFingerprints":{"codehealthFindingId/v1":"94408b20dc2f687e699b8b528a6152f10a62f9cfce175dace845ad61a58e51e0"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetChannelMessageReactions (cyclomatic 41): ChannelStore.SetChannelMessageReactions has cyclomatic complexity 41 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"07ae0e814af7e9f78b6e9e20663506a946ecd80a6ef60c302359e11ced8765d0"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.EditMessage (cyclomatic 41): MessageStore.EditMessage has cyclomatic complexity 41 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_edit.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d4ce890ea2b9022105d76aae8c9daf1611369cb6f7da6444aab0bd62dd691b8"}},{"ruleId":"D1","level":"warning","message":{"text":"PremiumStore.settlePremiumPayment (cyclomatic 41): PremiumStore.settlePremiumPayment has cyclomatic complexity 41 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c018619191263b664836cbd7716402a9608fa79ef49fd7b2d192a3ff3c87278"}},{"ruleId":"D1","level":"warning","message":{"text":"RunConfig.validate (cyclomatic 40): RunConfig.validate has cyclomatic complexity 40 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"1168ffdee53c7873d5f7e53bc84792fcec80cc5234a0745627bdf8b240930932"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgMessageServiceAction (cyclomatic 40): rpc.tgMessageServiceAction has cyclomatic complexity 40 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"f82ea02ffb8b583a1b61df493f06c5c4f2afc49db1269c3b23620d7f7ac420c8"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesToggleNoForwards (cyclomatic 40): Router.onMessagesToggleNoForwards has cyclomatic complexity 40 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_no_forwards.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"da303880bc54593d0cabc3834c95f890d117b8e048b3500f994179ce3adc25a8"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.domainInlineResultFromTG (cyclomatic 39): Router.domainInlineResultFromTG has cyclomatic complexity 39 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"490acdb44a01e85f04ec76a97f0ecc76a569480c29a78a0034f9ef130a2084f3"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.buildUserFullProjection (cyclomatic 39): Router.buildUserFullProjection has cyclomatic complexity 39 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8f270ff3246856ba461aab0b7b1cea737979c2ff8462a5ce709f478e2fcaddc"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetDiscussionGroup (cyclomatic 39): ChannelStore.SetDiscussionGroup has cyclomatic complexity 39 (threshold 15). Of this number, 35 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdfe24eed0d51fe1d249901c6d47d4a1d195c12d6c884109a9532c4de3b20e9f"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditChannelAdmin (cyclomatic 39): ChannelStore.EditChannelAdmin has cyclomatic complexity 39 (threshold 15). Of this number, 38 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"79ce786f5b337997e07eb3698b6d962e55278c6b279d3be875f031469822faf7"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteChannelHistory (cyclomatic 39): ChannelStore.DeleteChannelHistory has cyclomatic complexity 39 (threshold 15). Of this number, 38 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"90f5a9b75f2dd34c7830a7f354186ee852fb06c46f2f0a9fef27a50bdde89eeb"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.DeleteHistory (cyclomatic 39): MessageStore.DeleteHistory has cyclomatic complexity 39 (threshold 15). Of this number, 38 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":497}}}],"partialFingerprints":{"codehealthFindingId/v1":"e92be506fb7e652b6443eb38c8dfa2b4d8d171ae810ee053e3441108da27bcc7"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.settleStarGiftAuction (cyclomatic 39): StarGiftLifecycleStore.settleStarGiftAuction has cyclomatic complexity 39 (threshold 15). Most of this is not in the body itself: 3 of the 39 points are its own statements and the rest belongs to one function literal inside it that branches (line 617). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"92f5b931afd6389e77a8574f449ffe0b54615c9af59d28c9140b6e31b9fffdc1"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.ApproveTelegramLoginRequest (cyclomatic 39): TelegramLoginStore.ApproveTelegramLoginRequest has cyclomatic complexity 39 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":523}}}],"partialFingerprints":{"codehealthFindingId/v1":"cba3c7adb5cb82bb247399056bc0bf3a6eab7c80eae3af1f3cad56b945cc7a54"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ImportContacts (cyclomatic 38): Service.ImportContacts has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d83291d926194ad0023cdaf1e4c35fc0009b0e686391442983d9b30c38da2f5"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CanSeeMatrix (cyclomatic 38): Service.CanSeeMatrix has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"44573681bbfa960f58935216f470e9d2aa1aac46d5e0a9645fb8e968c77bd4e4"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.validateStarGiftAttributes (cyclomatic 38): domain.validateStarGiftAttributes has cyclomatic complexity 38 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1285}}}],"partialFingerprints":{"codehealthFindingId/v1":"097bb8ca8f5390dac5fa7a55ab0bb3b7e612de0edb6850fbbeb5bffd04d47da5"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.publishRPCResult (cyclomatic 38): Server.publishRPCResult has cyclomatic complexity 38 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 21 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":880}}}],"partialFingerprints":{"codehealthFindingId/v1":"955ca73cc346708aeb6872d77d6ea917a03afe484b5643449dc703d9a395eb8c"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.prepareInboundRPCBatch (cyclomatic 38): Server.prepareInboundRPCBatch has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"83bbde66a4067d35d57bc3dfdf0a575654153a9918f473e9add00f330afc21b7"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.botAPIRichText (cyclomatic 38): rpc.botAPIRichText has cyclomatic complexity 38 (threshold 15). Of this number, 36 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd60c6545c3538b010c2cf1afc91cf4e0e65af7d8087a6fff2463d56df8ebcbc"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgChannelMessageAction (cyclomatic 38): rpc.tgChannelMessageAction has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7d886c4a2c842b949389b330a8e9bcaa6ecfd84134a2d29ffc58adfd7d6eae7"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgMessageMedia (cyclomatic 38): rpc.tgMessageMedia has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_media.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"272aa7b83ae2ee52b50b11c6643d16ee4a3e83bb3b40b0aabbda92642493f949"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSearchGlobal (cyclomatic 38): Router.onMessagesSearchGlobal has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":589}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfcb6fb780985d7b409bac5e6d8d18de76a624ef82820ee56c7ab4038dc0b4b9"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.InviteToChannel (cyclomatic 38): ChannelStore.InviteToChannel has cyclomatic complexity 38 (threshold 15). Of this number, 37 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_members.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"eca0e2a276b5ba9929e15033fe98a1d2244d657f7d39408c7b8c7c9abfeddcff"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.readHistoryOnce (cyclomatic 38): MessageStore.readHistoryOnce has cyclomatic complexity 38 (threshold 15). Of this number, 37 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"591741b49d1fea864ccf03b84e19a3574782c585165c56d817d0327b6ea03480"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.SendStarGiftOffer (cyclomatic 38): StarGiftLifecycleStore.SendStarGiftOffer has cyclomatic complexity 38 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 17 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":778}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdd275c6322c08e502e436a7be052f1cc3ee499be77f2fa8bd388a45948b2f23"}},{"ruleId":"D1","level":"warning","message":{"text":"apiKeyboardButton.UnmarshalJSON (cyclomatic 37): apiKeyboardButton.UnmarshalJSON has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"2446c4f29bd8d679734c4713735a2feee3b9289c18882fc097932efeeb88a15a"}},{"ruleId":"D1","level":"warning","message":{"text":"config.validateLoginEmailConfig (cyclomatic 37): config.validateLoginEmailConfig has cyclomatic complexity 37 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":2023}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc2fe0d5701e40932ea22b7e0d4f8978b7d300193bb496315ea8c9f146624c47"}},{"ruleId":"D1","level":"warning","message":{"text":"EphemeralMessage.ValidateStored (cyclomatic 37): EphemeralMessage.ValidateStored has cyclomatic complexity 37 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators. This is NOT this file\u0027s highest cyclomatic complexity: domain.validEphemeralMedia (cyclomatic 39) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/ephemeral.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"a407978d37e526a5aaaf087a40f23723850914d5841ae19c80fc105b3f207ca1"}},{"ruleId":"D1","level":"warning","message":{"text":"rpcRewrapAlias.activate (cyclomatic 37): rpcRewrapAlias.activate has cyclomatic complexity 37 (threshold 15). Most of this is not in the body itself: 13 of the 37 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 872, 865). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_rewrap.go"},"region":{"startLine":855}}}],"partialFingerprints":{"codehealthFindingId/v1":"52273bd02440ec694fcbed3e17de986ac782db80ad58371173a141f70fa071d0"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.resolveBotCallbackQuery (cyclomatic 37): Router.resolveBotCallbackQuery has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b3fcaee0fa5b15823e920ac92c0c717a043b130e564e9e97fdf3ca38e137df5"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SendMonoforumMessage (cyclomatic 37): ChannelStore.SendMonoforumMessage has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a21e057f7e2aba3a23075ff39735f6761d46531fbea072f5bdedb318126ff42"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ReadHistory (cyclomatic 37): MessageStore.ReadHistory has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"223545f12d5eaeffce09e824bb0bc682ed49cff3daa4439b8a43abc85204f7af"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.resolveChannelReply (cyclomatic 37): ChannelStore.resolveChannelReply has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":808}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1cf4288ea6a303bd05eafe9baa7279cb25d13ad2cb27dd09c6af84506c324b1"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.populateChannelMessagesReactionsWhere (cyclomatic 37): ChannelStore.populateChannelMessagesReactionsWhere has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_helpers.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"cade714033c14b8de24d826db8df4db267edb3f22b1fcae32aa2455baf9a0db6"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.SweepStarGiftLifecycle (cyclomatic 37): StarGiftLifecycleStore.SweepStarGiftLifecycle has cyclomatic complexity 37 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"70507095b1a5f45efcf566a71ec696ad3d6777f94c994df9f8b8437dba913ca0"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.BidStarGiftAuction (cyclomatic 37): StarGiftLifecycleStore.BidStarGiftAuction has cyclomatic complexity 37 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 16 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":994}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce75e2039584399026f3ed8a4394548ae4a7c77b650c60aa4b23399ec1d00c61"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SendFromClient (cyclomatic 36): Service.SendFromClient has cyclomatic complexity 36 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9b840fd3460aa15cab1f3fe81a9782e6abf84bfcf49c330ebcac881a68183b1"}},{"ruleId":"D1","level":"warning","message":{"text":"RetentionWorker.runRetentionOnce (cyclomatic 36): RetentionWorker.runRetentionOnce has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/maintenance/retention.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f9737142e46e39198c7db3af978af12b5cf252d2165f9d5b70fe07fe0d2d1c8"}},{"ruleId":"D1","level":"warning","message":{"text":"Conn.handleOutboundSend (cyclomatic 36): Conn.handleOutboundSend has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":2260}}}],"partialFingerprints":{"codehealthFindingId/v1":"9338f1b347434213d704481d67061e68958d937d5072c520897605295759cdef"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgSavedStarGifts (cyclomatic 36): rpc.tgSavedStarGifts has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1721}}}],"partialFingerprints":{"codehealthFindingId/v1":"54956fd78eec78987857aabe8b672a40fab3114040720e641f7ea8058050cda9"}},{"ruleId":"D1","level":"warning","message":{"text":"richMessageMediaRefs.collectBlocks (cyclomatic 36): richMessageMediaRefs.collectBlocks has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_rich_message.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"ceb78efe220ecf9946690d268c64103fd96c23b3ed84241bc09186247e469f02"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelDifference (cyclomatic 36): ChannelStore.ListChannelDifference has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"c74e13018b09bb659b141a5dcf446f0134e5cc8f53cfc348b2841c3404d61781"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannels (cyclomatic 36): ChannelStore.GetChannels has cyclomatic complexity 36 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fa374f064ef85462e27b7aa1b9f9fa3563dc03d5dfcde06c9eaa9aa9ba3faa2"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditChannelBanned (cyclomatic 36): ChannelStore.EditChannelBanned has cyclomatic complexity 36 (threshold 15). Of this number, 35 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"65978a02f4b32695668b0e74a8d4a65f1e5aabc7eefea17b4a25e7a62f40da67"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.GiveStarGift (cyclomatic 35): Service.GiveStarGift has cyclomatic complexity 35 (threshold 15). Most of this is not in the body itself: 15 of the 35 points are its own statements and the rest belongs to one function literal inside it that branches (line 489). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/star_gift_catalog.go"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"6815e04c57fd647a8fe4a8a0e24e8fac52fab75976efa16645b3535c02204666"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.applyTelegramLoginConfiguration (cyclomatic 35): Service.applyTelegramLoginConfiguration has cyclomatic complexity 35 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0c585c1804759bc1f29c7a243de9d2c9c386d3c44fb109f8f423c6396a9dc6f"}},{"ruleId":"D1","level":"warning","message":{"text":"Projector.ForViewerUserIDs (cyclomatic 35): Projector.ForViewerUserIDs has cyclomatic complexity 35 (threshold 15). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection_sparse.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cca30005338defc2470571f6167392654ddabdc5a7038ca83abdcdea32bab12"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.messageReplyFromInput (cyclomatic 35): Router.messageReplyFromInput has cyclomatic complexity 35 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":632}}}],"partialFingerprints":{"codehealthFindingId/v1":"b23cb324a14a89239779d6d567d210f252ee34650a9e7d6755fc28304dfd2318"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.persistPlainPrivateSendProjectionBatch (cyclomatic 35): postgres.persistPlainPrivateSendProjectionBatch has cyclomatic complexity 35 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_sql.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"81692d86d1d15a0733ab6ce4be362f464b8e6e787ccc52bd452b09835495e01f"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditExportedInvite (cyclomatic 35): ChannelStore.EditExportedInvite has cyclomatic complexity 35 (threshold 15). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"319a4b2c6c79d4af4ec5a8d7c25834c7ba8e77924b2a75320c7d752eb84451e2"}},{"ruleId":"D1","level":"warning","message":{"text":"GroupCallStore.RemoveConferenceCallParticipants (cyclomatic 35): GroupCallStore.RemoveConferenceCallParticipants has cyclomatic complexity 35 (threshold 15). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ae16e4c91872e92cd1aab36311e0ecb34aac2db77774f0fb7718a053a9063da"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.SetStarGiftListing (cyclomatic 35): StarGiftLifecycleStore.SetStarGiftListing has cyclomatic complexity 35 (threshold 15). Most of this is not in the body itself: 9 of the 35 points are its own statements and the rest belongs to one function literal inside it that branches (line 325). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"d13f0ecac8ef7b66d09bb975e645e49b35fdeb6dd084784a918a92211a089cf1"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.ValidateReplyMarkup (cyclomatic 34): domain.ValidateReplyMarkup has cyclomatic complexity 34 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_markup.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b0b0f5afce9b5a4fb1a3da0e2e5fd81bce33d0cd17b9ac66aae5f795e5a75e7"}},{"ruleId":"D1","level":"warning","message":{"text":"serverExchangeCompat.run (cyclomatic 34): serverExchangeCompat.run has cyclomatic complexity 34 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/exchange_compat.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"448a6442aa5d6feb2e58fa1238c5005c66d9abc622db4cead5e8ccaca456e4e3"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.seedInitialLayerProfile (cyclomatic 34): Server.seedInitialLayerProfile has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn_layer_profile.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"082efac05d2acb2073af03a34a060b94ec221303e8c0d182cab3bedebf8154d3"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.serveConn (cyclomatic 34): Server.serveConn has cyclomatic complexity 34 (threshold 15). Of this number, 32 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":997}}}],"partialFingerprints":{"codehealthFindingId/v1":"5608be7aa2640eab25520d0fbff3c2c1286b8de8579fdfdebb2ca8547ff7c494"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.domainMessageEntitiesForViewer (cyclomatic 34): rpc.domainMessageEntitiesForViewer has cyclomatic complexity 34 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":673}}}],"partialFingerprints":{"codehealthFindingId/v1":"bba44fb883a0d1c061e3f49a5d9d77a424b8876398265ff8a45c3fc1d5393884"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.channelMemberHasRequestRights (cyclomatic 34): rpc.channelMemberHasRequestRights has cyclomatic complexity 34 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":392}}}],"partialFingerprints":{"codehealthFindingId/v1":"23c01b0a4f9c9e64e68ee93144c9c59dcd5caaaa87d94d0696564419ef5c4e68"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.prepareTelegramLoginMarkup (cyclomatic 34): Router.prepareTelegramLoginMarkup has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"19d240f0c582366c6dce5c682152165c81056f98caaf0ce92f27ae19e4747d54"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.validateStarsGiveawayPurpose (cyclomatic 34): Router.validateStarsGiveawayPurpose has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"4176aa016c41355a47a259e57fd6a1a4fd569ede7d9f4ad01363130834ebd693"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.domainStoryMediaAreasFromTL (cyclomatic 34): Router.domainStoryMediaAreasFromTL has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1671}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ece63d8192babfc1a4f08d44e3afb783bbc006fb04a0ed78d33096f530c11da"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.finishMemoryDeleteLocked (cyclomatic 34): MessageStore.finishMemoryDeleteLocked has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_delete.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e424777fc5465ac5e092d25f408e7b4533ddce07d90873aa992f616341403d1"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.PinPrivateMessage (cyclomatic 34): MessageStore.PinPrivateMessage has cyclomatic complexity 34 (threshold 15). Of this number, 33 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"02a402523925b83640ed27976ebac41a5633320e46155ac5f258dfce05e3d5fc"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.loadCraftReplay (cyclomatic 34): StarGiftLifecycleStore.loadCraftReplay has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":514}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a79f0ce09b96b4a8277865528c8fb13e9eac329c0d048b35fea54b2de63a8c3"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CanSeeBatch (cyclomatic 33): Service.CanSeeBatch has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"90334ff6ad8132407044a32b50e40a849f345b9ed2f7337351d599705451138d"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationDecisionRequest.Validate (cyclomatic 33): ModerationDecisionRequest.Validate has cyclomatic complexity 33 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation_case.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"5397c56987edc19bab5d5a2aef8f6412cdbfe44528e38fcae722f32449eca7fe"}},{"ruleId":"D1","level":"warning","message":{"text":"Options.setDefaults (cyclomatic 33): Options.setDefaults has cyclomatic complexity 33 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"23688cfb039e6fdb1227bb6dab6d592acf4360512ba86026250093dd7fc11d6b"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.commitLayerProfileEvidence (cyclomatic 33): Server.commitLayerProfileEvidence has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":1097}}}],"partialFingerprints":{"codehealthFindingId/v1":"47cb22033bb6cc41957b6141d00a74d1fde05d8c8763b316d66b3c1e2ed24c36"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgChannelFull (cyclomatic 33): rpc.tgChannelFull has cyclomatic complexity 33 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddaf71574b075d61c26c6a8b380af53351a2b2672c8e50a2bce1a1b19f957f5f"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.sendPrivateTextLocked (cyclomatic 33): MessageStore.sendPrivateTextLocked has cyclomatic complexity 33 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_send.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"c53ad221cf55f1451881467101378fdae8d0f1a5f2f9f64d67fd8ca15bbd8f62"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.ApproveTelegramLoginRequest (cyclomatic 33): TelegramLoginStore.ApproveTelegramLoginRequest has cyclomatic complexity 33 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":346}}}],"partialFingerprints":{"codehealthFindingId/v1":"807e69eead234aec7749de16091a737b035803394ac0e39660ae50fd57666b62"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.JoinChannel (cyclomatic 33): ChannelStore.JoinChannel has cyclomatic complexity 33 (threshold 15). Of this number, 32 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f0acfe3370643d592e6d206aa41cdefb70309c983080d3189848329b6a7e7a3"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetPaidMessagesPrice (cyclomatic 33): ChannelStore.SetPaidMessagesPrice has cyclomatic complexity 33 (threshold 15). Most of this is not in the body itself: 6 of the 33 points are its own statements and the rest belongs to one function literal inside it that branches (line 84). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_settings.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"6edf97681ce490c5583680db4b08d4b80ba1eaf2368e22e6838333df5ab4a819"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.DeliverLoginCodeMessage (cyclomatic 33): MessageStore.DeliverLoginCodeMessage has cyclomatic complexity 33 (threshold 15). Of this number, 32 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/login_code_delivery.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bad2e2382a9a924ce96379e50d67e5293231b93af8b5de1227b151e90bd2942"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.ConsumeTelegramLoginAuthorizationCode (cyclomatic 33): TelegramLoginStore.ConsumeTelegramLoginAuthorizationCode has cyclomatic complexity 33 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":866}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b361306f3d054e8fc66161784e9d92e6144a38e930c29fe0b105fa2c8706fdd"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.Configure (cyclomatic 32): Service.Configure has cyclomatic complexity 32 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":662}}}],"partialFingerprints":{"codehealthFindingId/v1":"9dec766dd0662822151b00b17186c44cb71cbbc1cb7cc0fb6042483ca56dc13b"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.verifyLoginCode (cyclomatic 32): Service.verifyLoginCode has cyclomatic complexity 32 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1157}}}],"partialFingerprints":{"codehealthFindingId/v1":"7abf65605c97420aff2425ef68fe4726a9fab99a20f880ef13083ddb4d09d09d"}},{"ruleId":"D1","level":"warning","message":{"text":"stargifts.normalizeAndValidateLottie (cyclomatic 32): stargifts.normalizeAndValidateLottie has cyclomatic complexity 32 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/animation.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"c89431fec20f6c539f38f008aa28f8d783f08634dae23b75e8716c1c5dd2a5cf"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.publicVerificationIP (cyclomatic 32): domain.publicVerificationIP has cyclomatic complexity 32 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/verification.go"},"region":{"startLine":502}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcf4c28fd211d6e74ba402a66237e651034ef0e39a071d16ede9dd04ceb21ecd"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.domainRichMessageFromInput (cyclomatic 32): Router.domainRichMessageFromInput has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_rich_message.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"31d2fc776def50df33b274ceb05172afe6d77f9d9730c60e77af0bc55c765127"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.requestedPeerMatches (cyclomatic 32): Router.requestedPeerMatches has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"6caf6cf673a2627aa6632d0b930f23321896f5d667fe2ce5670e6ab389c17800"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesToggleDialogPin (cyclomatic 32): Router.onMessagesToggleDialogPin has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"575f3c657bb08ce84bf03c51422518c84b7e424aacb8302427dddbbf18008186"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.forwardMessagesToMonoforum (cyclomatic 32): Router.forwardMessagesToMonoforum has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"70d6f65d376f9b563d7fef7645016e855939b488a6ac363c2b527cb834bab814"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.fanoutStoryPrivacyChange (cyclomatic 32): Router.fanoutStoryPrivacyChange has cyclomatic complexity 32 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 9 belong to 3 function literals inside it that branch. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2089}}}],"partialFingerprints":{"codehealthFindingId/v1":"12c207ca6b151bc72b4263dc0b507d6daf98df8652bdc71c7aa4ce3b767ff85b"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.fanoutDeletedUserStory (cyclomatic 32): Router.fanoutDeletedUserStory has cyclomatic complexity 32 (threshold 15). Of this number, 24 points are the body\u0027s own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2178}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a5d62e7633cf57274d2641c00f3c3b284e0490b2e370887666816e8b984741b"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onUsersGetRequirementsToContact (cyclomatic 32): Router.onUsersGetRequirementsToContact has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbdd1fe10421c327180f08839c0f90b833928f1cdd265723556c665d429aa53d"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.viewLocked (cyclomatic 32): CommunityStore.viewLocked has cyclomatic complexity 32 (threshold 15). Of this number, 30 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f9cd50eabefcbb0aa938c57090f498fc23a18539e0f3e96089c507924c9df2c"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.validateBotAPIUpdateRequest (cyclomatic 32): postgres.validateBotAPIUpdateRequest has cyclomatic complexity 32 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":684}}}],"partialFingerprints":{"codehealthFindingId/v1":"95476dcbe1447d286a3549da2b66c1c4e5323182ad24947ecda833ece944ede5"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.TransferChannelOwnership (cyclomatic 32): ChannelStore.TransferChannelOwnership has cyclomatic complexity 32 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"51b8f64371e11ee9d8dc6a0c2b2685ad073e65c54e9603cd6b97c89f752f2d12"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.SetMessageReactions (cyclomatic 32): MessageStore.SetMessageReactions has cyclomatic complexity 32 (threshold 15). Of this number, 31 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"6af5ddeb2c9023ede4d580fd12c0a739a2f0d8669b16214ee764c57fa32da89e"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.ReviewModerationAppeal (cyclomatic 32): ModerationReportStore.ReviewModerationAppeal has cyclomatic complexity 32 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"b15c2184e02bdf0af3949982fabc421d85a9c2f0f32a92ac2b5d51daea6bf138"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.prepareStarGiftPurchase (cyclomatic 32): StarGiftLifecycleStore.prepareStarGiftPurchase has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fe250b916e5124290756ffee9529a8f03947f70e36e67f71fdaef8784d6b9cf"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.createStickerSet (cyclomatic 31): Service.createStickerSet has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"24a1d8f8dc6a01072ccc4170b975668363cbea9600eb1cf397b4aa3bfea31240"}},{"ruleId":"D1","level":"warning","message":{"text":"apiInlineKeyboardButton.UnmarshalJSON (cyclomatic 31): apiInlineKeyboardButton.UnmarshalJSON has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":726}}}],"partialFingerprints":{"codehealthFindingId/v1":"5db92d1f3301d1c5f2686ccd2dc3590bff86add5ad5a1109d87098abc5649ca3"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.MutateOffline (cyclomatic 31): loadharness.MutateOffline has cyclomatic complexity 31 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aeb7c34674cc3b8f2234f2260eaf96bdfa25181ca9a5dc7981ae814f8ab086d"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.mergeDialogPageKnownOverlap (cyclomatic 31): loadharness.mergeDialogPageKnownOverlap has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":401}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2ebbe3dcd3a6cbfd71c27b8100f7d30891ca37627e5fd2ffa43996a9e1076e1"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.decodeInboundLayerRPCWithOptions (cyclomatic 31): Server.decodeInboundLayerRPCWithOptions has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":994}}}],"partialFingerprints":{"codehealthFindingId/v1":"f09a34589abfc12d1c6dcb4aa686c93f9a87367436b5e7248104f846daf6a93e"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.requestedPeerDetails (cyclomatic 31): Router.requestedPeerDetails has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ad510781045f9a2a1955f129211437611024f564804d77d65e8c958f6f201a3"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetMessageReactionsList (cyclomatic 31): Router.onMessagesGetMessageReactionsList has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_lists.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b2fd417b8e79a08353c164e9c7230d00a9f6878a75b5e87feacf93dcd838f23"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPaymentsGetPaymentForm (cyclomatic 31): Router.onPaymentsGetPaymentForm has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"f951e0ea946617d589ed0b31a30ab5eea9c58a03d2e08d0a4e17dd4976d0f112"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.sendOutgoing (cyclomatic 31): Router.sendOutgoing has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"25e8d3f26066ff2ecf691efc42455009cf8eeba6bce65e4a289674feae4db55b"}},{"ruleId":"D1","level":"warning","message":{"text":"memory.filterMessageList (cyclomatic 31): memory.filterMessageList has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d1b7582ff649a4c2dec1f37f15d06b9a5a4bda90436c140bd0251045a40ece9"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.DeleteHistory (cyclomatic 31): MessageStore.DeleteHistory has cyclomatic complexity 31 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 12 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"5efc9450d6177bc17ca857bd4cb7ef0ae7b6ddeb182842f8fdd23692ed79b5fb"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.PutTelegramLoginAuthorizationCode (cyclomatic 31): TelegramLoginStore.PutTelegramLoginAuthorizationCode has cyclomatic complexity 31 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":742}}}],"partialFingerprints":{"codehealthFindingId/v1":"2aed18d4803eda3e6b433cd4bde35c6e1c39ef2a8065a78b2ae438ed067b585d"}},{"ruleId":"D1","level":"warning","message":{"text":"main.main (cyclomatic 30): main.main has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 6 of the 30 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 142, 122). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"38fe8cf15012904ea43fa37d75ea85e516356c31f654bd181ffe68452500e29b"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ChangePhone (cyclomatic 30): Service.ChangePhone has cyclomatic complexity 30 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/phone_change.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"35a8d70a10a24c32c48a2434b94c5a5cec8ef8a5b42fcf33fe848c6f3eb90ba5"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.handleChooseBot (cyclomatic 30): Service.handleChooseBot has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"9dcaa4e5e82dbeb0420be5e130f81719882544852b8ae7fd2c102cfc9ed75136"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.validateDecisionActions (cyclomatic 30): Service.validateDecisionActions has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/actions.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a3d5f1da6a520584b3ce73437fb9a390036feea36ceafb7ec45c3f81752badb"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CreateCatalogBundle (cyclomatic 30): Service.CreateCatalogBundle has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"12be44637d786c0e74c358979d4f4f318e34b5eea89eab0116e9f0c48e3bf260"}},{"ruleId":"D1","level":"warning","message":{"text":"CachedContactStore.ContactProjectionForViewers (cyclomatic 30): CachedContactStore.ContactProjectionForViewers has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"621dd1fb00db962c20168edeb4a2e966c6a0f11bb23ce0d281fa6311a89bd5ce"}},{"ruleId":"D1","level":"warning","message":{"text":"config.validateTelegramLoginConfig (cyclomatic 30): config.validateTelegramLoginConfig has cyclomatic complexity 30 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1680}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad203f456a1a5bcd20c8490a3efb66f7a3ef1c84fd225028bf9d603d133effa7"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.botAPIQueuedUpdateKind (cyclomatic 30): rpc.botAPIQueuedUpdateKind has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf20b9ed1222efbf94401a86c8905dcac2c75c1fb653f0e3e54d4e68ef1ca855"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetInlineBotResults (cyclomatic 30): Router.onMessagesGetInlineBotResults has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"a869140841a2dee3e0b6ced33dde88580ce3ddb91357223fd21cd654be11830c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSendReaction (cyclomatic 30): Router.onMessagesSendReaction has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_send.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"8401b3d5d061f75ced51cc519e9a1299ac200447c80515210f80e6a162b2b0bd"}},{"ruleId":"D1","level":"warning","message":{"text":"memory.adminRightsSubset (cyclomatic 30): memory.adminRightsSubset has cyclomatic complexity 30 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"da8788b78999ea691b9bf463d03f58bccfcc347b1b5f86d98d9da9713bc75140"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelDialogs (cyclomatic 30): ChannelStore.ListChannelDialogs has cyclomatic complexity 30 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"10436e08e82fc8dec0249e6dd99598a964136a242891175e99e8e82542b8a880"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelMessageViews (cyclomatic 30): ChannelStore.GetChannelMessageViews has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_views.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b81c2e706bc826c42e5ed7de6b164a96950b210978ef3cb1e6061ca22d85f10"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.toggleSuggestedPostApprovalLocked (cyclomatic 30): ChannelStore.toggleSuggestedPostApprovalLocked has cyclomatic complexity 30 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_suggested_post.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4362799924a762763db71cd5df76bc7d3d58fac83aa28dc3d1a746f554b5634"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.TogglePrivateNoForwards (cyclomatic 30): MessageStore.TogglePrivateNoForwards has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_no_forwards.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"73d69083095e0c7f4cd889df7d28d894aa27cb75c39181a02c414902e9041291"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.adminRightsSubset (cyclomatic 30): postgres.adminRightsSubset has cyclomatic complexity 30 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":959}}}],"partialFingerprints":{"codehealthFindingId/v1":"18669e60cc54e0d36643303d14a9a826adbd55a4d49556953314b70e7acca711"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SendLoginEmailCode (cyclomatic 29): Service.SendLoginEmailCode has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":765}}}],"partialFingerprints":{"codehealthFindingId/v1":"3063cca87693d573f561ea9b0d00041e9fb7905176ebe80fa2a4311db91f1184"}},{"ruleId":"D1","level":"warning","message":{"text":"files.parsePremiumPromoSeed (cyclomatic 29): files.parsePremiumPromoSeed has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/premium_promo_seed.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad83c7107be76177d474a6334001d70e7ffd7ebd4197bd18d5746907e75534a1"}},{"ruleId":"D1","level":"warning","message":{"text":"files.parseWebPageMeta (cyclomatic 29): files.parseWebPageMeta has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/webpage.go"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"38ad83627657b363b934ad560868bbb312ed4e8f280e5b7704ff59b874d34511"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.parseBotAPIHTML (cyclomatic 29): botapi.parseBotAPIHTML has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e13f0700b7d62c626df8d63a94e3e41fa6d29c0ca8502a174edecba7d9d01cc"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.apiUpdate (cyclomatic 29): botapi.apiUpdate has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f88b502ebd333f623cf3de313aabde791e043367eb31d43cd8685e46f134a64"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.apiRequestedPeer (cyclomatic 29): botapi.apiRequestedPeer has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":856}}}],"partialFingerprints":{"codehealthFindingId/v1":"267eb72d265a32c565ce3b629a968180abbd573858bfdb6ca52f03ac173b02d1"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ReadMessageContents (cyclomatic 29): MessageStore.ReadMessageContents has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_read.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d1042d79078d60d58bee775f2b856b820ca00bcba5f769d63f3845576900bc6"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.executePlainPrivateSendBatch (cyclomatic 29): postgres.executePlainPrivateSendBatch has cyclomatic complexity 29 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_actor.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c20f43163872584fc97d4c08dd12fcfebfe669b9735832b6ea2e5f09c667c5d"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetParticipants (cyclomatic 29): ChannelStore.GetParticipants has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_list.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"2aa44723dc7d73ce8446a810be85accdadf0806173f6d77e093a44e2b1e21d62"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SearchJoinedMessages (cyclomatic 29): ChannelStore.SearchJoinedMessages has cyclomatic complexity 29 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"47aa5e28a62e2edff2b5ecc425af55aec4c1bf98b42dbc928c52f6a2f64b4669"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.TogglePrivateNoForwards (cyclomatic 29): MessageStore.TogglePrivateNoForwards has cyclomatic complexity 29 (threshold 15). Most of this is not in the body itself: 11 of the 29 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 85, 183). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_no_forwards.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb550b80d148eb36d39c599101b29788990277c3681c92058c0aca9095ef6cd9"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.CreateScheduledMessage (cyclomatic 29): MessageStore.CreateScheduledMessage has cyclomatic complexity 29 (threshold 15). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f85eac847fbe369385d06e252bc192baeb9060ad58cf6af5e336cf9fc3163a9"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.markCraftInputMessageTx (cyclomatic 29): StarGiftLifecycleStore.markCraftInputMessageTx has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_projection.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"555d87055a7374a2c3cebbb12af73f265dbe41af500c26f19ab2c7e439ea686b"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.CompleteStarGiftWithdrawal (cyclomatic 29): StarGiftLifecycleStore.CompleteStarGiftWithdrawal has cyclomatic complexity 29 (threshold 15). Most of this is not in the body itself: 8 of the 29 points are its own statements and the rest belongs to one function literal inside it that branches (line 1602). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1596}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ea8fcd1722ce2a193f33831e734ddc82049eeb3b3896cb5c8d4de01ea756efa"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.ConsumeTelegramLoginDirectToken (cyclomatic 29): TelegramLoginStore.ConsumeTelegramLoginDirectToken has cyclomatic complexity 29 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":936}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c0665a68012c6c92e81d8fe9807e86fb479d4a8f8f38f5c3056407ed3d3a7e6"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SetAccountFrozen (cyclomatic 28): Service.SetAccountFrozen has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 12 of the 28 points are its own statements and the rest belongs to one function literal inside it that branches (line 1494). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1473}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecfcc38627904e5014cacb1534ccfe09588c1cc2bf43328acf027eb5c1e2c7d2"}},{"ruleId":"D1","level":"warning","message":{"text":"telegramlogin.NormalizeNativeCallbackURI (cyclomatic 28): telegramlogin.NormalizeNativeCallbackURI has cyclomatic complexity 28 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/native.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"4335ed6980e5bac09dd28b4d8c76435f915d935b0575270836c1665ad51df1e2"}},{"ruleId":"D1","level":"warning","message":{"text":"userprojection.projectBatch (cyclomatic 28): userprojection.projectBatch has cyclomatic complexity 28 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 7 belong to 7 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eafb1d8a4aafb12ee2841a39e549d3d0f107172109c99aa33557f5a37cba615"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.parseBotAPIMarkdown (cyclomatic 28): botapi.parseBotAPIMarkdown has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"a67a0ee8420c1b59d21abba0e20ac14d35a3aff091dcbd1d88b5d028c500170a"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.apiMessageMedia (cyclomatic 28): botapi.apiMessageMedia has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d24504bd25b6c4c872d636be8d91fd950a6d3e934b7b1e8110719eb8f1978a3"}},{"ruleId":"D1","level":"warning","message":{"text":"config.validateVerificationConfig (cyclomatic 28): config.validateVerificationConfig has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1730}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5854e105336f9d549134641ea2c112626290934a89178fe5027443274056749"}},{"ruleId":"D1","level":"warning","message":{"text":"channelFanoutDispatcher.Run (cyclomatic 28): channelFanoutDispatcher.Run has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 8 of the 28 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 512, 482). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"83da111cf58238a77ac73990d5c3d00145398e376fb7b42ebdbe21e5b8ee1178"}},{"ruleId":"D1","level":"warning","message":{"text":"OutboxDispatcher.dispatchBatch (cyclomatic 28): OutboxDispatcher.dispatchBatch has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/outbox_dispatcher.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"749b8972bd9395e18500e7ace0691952e533b6e3cd66237e50e1768fe5e4ee4e"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSendBotRequestedPeer (cyclomatic 28): Router.onMessagesSendBotRequestedPeer has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"efbcb5cf876c5916480f55971d4603ff373e993369a93a4156bfad39207ea856"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onEditMessageLiveLocation (cyclomatic 28): Router.onEditMessageLiveLocation has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"c87c24dcea02b911124606f6d8d526cf43c7977d9ad9d83bc3469b1ffc62b27e"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.approveInviteImporterLocked (cyclomatic 28): ChannelStore.approveInviteImporterLocked has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":732}}}],"partialFingerprints":{"codehealthFindingId/v1":"cca8af03458a398cd20ca5d4a27c06c226c73cbe82d75185bacc89b1481530d6"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ReadChannelMessageContents (cyclomatic 28): ChannelStore.ReadChannelMessageContents has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"d814a4b26f2d632acf0499701a4185e1f282dee4268ed51cc39aa08fd0b2311d"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ProcessSuggestedPostLifecycle (cyclomatic 28): ChannelStore.ProcessSuggestedPostLifecycle has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_suggested_post.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"04cddaaa123653d6e75e1af14877c5e47336c58daff921870ec32c5beddd9d96"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelReplies (cyclomatic 28): ChannelStore.ListChannelReplies has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e3ce6087ac597096bef32fd9913eda678598aa8b7cfd327d81c70e313fb80ea"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.ToggleCommunityParticipantBanned (cyclomatic 28): CommunityStore.ToggleCommunityParticipantBanned has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":697}}}],"partialFingerprints":{"codehealthFindingId/v1":"f204ba00c3855f815c25283101447fa0f8bc29f96fa553b410cba006932b0b0f"}},{"ruleId":"D1","level":"warning","message":{"text":"AccountLifecycleStore.ExecuteAccountDeletion (cyclomatic 28): AccountLifecycleStore.ExecuteAccountDeletion has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_lifecycle.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d36627d984fdf63e1151393c4d1e69d5e78caa302057873a0a9faa785baef46"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelDialogSnapshotHeaders (cyclomatic 28): ChannelStore.ListChannelDialogSnapshotHeaders has cyclomatic complexity 28 (threshold 15). Of this number, 24 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":293}}}],"partialFingerprints":{"codehealthFindingId/v1":"8329eab183f3c5e9e50a69143db9b4d4e3ba1250953414f13bb4efbf5d5e06d8"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.LeaveChannel (cyclomatic 28): ChannelStore.LeaveChannel has cyclomatic complexity 28 (threshold 15). Of this number, 27 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"a38f04a87701b82c70d6e0df38f92f02bad17e4a6ab58d7e84c6975415e0ec36"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.resolvePrivateSendReply (cyclomatic 28): MessageStore.resolvePrivateSendReply has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":808}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d25c679750525d49e8aa65cc3c5ea8c26d58d0cf4f23b2c86ca752b2cc04e61"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.SubmitModerationAppealByLink (cyclomatic 28): ModerationReportStore.SubmitModerationAppealByLink has cyclomatic complexity 28 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":533}}}],"partialFingerprints":{"codehealthFindingId/v1":"0346341a14efaebf55d6175153811e0199dc5fb33ab211f2f573fa913842c601"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftStore.CreateCatalogRevision (cyclomatic 28): StarGiftStore.CreateCatalogRevision has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 10 of the 28 points are its own statements and the rest belongs to one function literal inside it that branches (line 211). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"883a21045cfe6177cfb1d4dd4c0ffee47d41bd44a880aad6df7ca8f374be054e"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.ConvertStarGift (cyclomatic 28): StarGiftLifecycleStore.ConvertStarGift has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 10 of the 28 points are its own statements and the rest belongs to one function literal inside it that branches (line 79). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c85b80f58f7a2d378df195014b6f4c270b491da86cbacb32330aec0ed52dac7"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.TransferStarGift (cyclomatic 28): StarGiftLifecycleStore.TransferStarGift has cyclomatic complexity 28 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 12 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e57ac0474076c05a15c2a9db2647ba5d790667ada5804ba1b8a25b648c2c1c7"}},{"ruleId":"D1","level":"warning","message":{"text":"CachedReadModelVersionStore.ReadModelHashes (cyclomatic 28): CachedReadModelVersionStore.ReadModelHashes has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/read_model_cache.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2da5f565dd741e68ceb7f749c8e5829534560958ff39ff358ea77ec988a98f6"}},{"ruleId":"D1","level":"warning","message":{"text":"main.pythonBytesLiteralToHex (cyclomatic 27): main.pythonBytesLiteralToHex has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerseeddeploy/main.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8e332f933481f5e0c7dadf380e566e92430fac55961c901c9208f50e6b7ce3f"}},{"ruleId":"D1","level":"warning","message":{"text":"main.documentMedia (cyclomatic 27): main.documentMedia has cyclomatic complexity 27 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":781}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a64b37e60818829f24b3040923ff8e281c03e454848e8e822e459bbcc90b4ca"}},{"ruleId":"D1","level":"warning","message":{"text":"server.runOperatorCommand (cyclomatic 27): server.runOperatorCommand has cyclomatic complexity 27 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/admin_command_runner.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcf433a8226bfdb333868ad4676984f8c2941493d205b387dfd68e4302eb1074"}},{"ruleId":"D1","level":"warning","message":{"text":"main.run (cyclomatic 27): main.run has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"632b3c84f29057252c825cb2ff304d4752154a7217bb04c900f68fbd9b0d4a24"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.appendMissingChannelPeerPreviews (cyclomatic 27): Service.appendMissingChannelPeerPreviews has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"1566cf8621d4f18899fe4f63b94ded663aecf29c6995c4c16cfddc2b04b5fd5c"}},{"ruleId":"D1","level":"warning","message":{"text":"stars.validPurchaseCommand (cyclomatic 27): stars.validPurchaseCommand has cyclomatic complexity 27 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stars/service.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"347d335072cd6a9495a4969f374b68b55aad42def749c6fc92225bbfeb18233b"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.deepLinkToken (cyclomatic 27): Service.deepLinkToken has cyclomatic complexity 27 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":914}}}],"partialFingerprints":{"codehealthFindingId/v1":"7baa24d322ebd12a927a09816573aeae8936d3a12ae1834d8f53d12b544c37b9"}},{"ruleId":"D1","level":"warning","message":{"text":"Projector.ForViewers (cyclomatic 27): Projector.ForViewers has cyclomatic complexity 27 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8f6a6465460d67bf1a405cb0a1f30285b0bc8428ef3b07a1eacb3eb98e22876"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.getUpdates (cyclomatic 27): handler.getUpdates has cyclomatic complexity 27 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: handler.handle (cyclomatic 41) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"edeca423f458d59d3218b56eed4eab44021866e2751a5f0f02c1a8f5bae70fee"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.applyOfflineChannelActions (cyclomatic 27): loadharness.applyOfflineChannelActions has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"25e778245cdef2beff6f2e549f8462d71c6f2bfcc7f5af03cec33e3bd28794fa"}},{"ruleId":"D1","level":"warning","message":{"text":"DatasetSeedState.Validate (cyclomatic 27): DatasetSeedState.Validate has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bb25f587a1b52cf0a9900781586fdd5dfa8d733575d1bb572fc74f5d4af912e"}},{"ruleId":"D1","level":"warning","message":{"text":"loadWorker.runClient (cyclomatic 27): loadWorker.runClient has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 2 of the 27 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 333, 299). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":290}}}],"partialFingerprints":{"codehealthFindingId/v1":"08920f9b317438e567254d6590b7b76ac5f8558a1cc0f7355f8bed8026f909e9"}},{"ruleId":"D1","level":"warning","message":{"text":"rpcResultWaiter.subscribe (cyclomatic 27): rpcResultWaiter.subscribe has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_flight.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"745640cb04b4436370d5bbba2d9b136d8f209eb664655184e94c6b7673a92638"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgChannelAdminLogEvent (cyclomatic 27): rpc.tgChannelAdminLogEvent has cyclomatic complexity 27 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":785}}}],"partialFingerprints":{"codehealthFindingId/v1":"aed84da119cf0c8111a930af90880c35ec8c8e1870138f8173059706d8e228a6"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgMessage (cyclomatic 27): rpc.tgMessage has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"69ebfe57cb17568e872b150b4b55e130d7a6f88c4661a1a3d7431a33f9b7142c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onChannelsGetSendAs (cyclomatic 27): Router.onChannelsGetSendAs has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2fdc801c6c5233c8986978c9f204ebd88d28315ce34583e829464d10c90ca6b"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onChannelsGetParticipants (cyclomatic 27): Router.onChannelsGetParticipants has cyclomatic complexity 27 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"823deaf2185874aface9ff49267d215c763eab3f7f0ff5ba9f778cfc277ebb71"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPaymentsGetResaleStarGifts (cyclomatic 27): Router.onPaymentsGetResaleStarGifts has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3743633eacec49e4523ceb90a148fb924932c49d1c07bac10473dcf716a61b2"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.rememberClientLayerAt (cyclomatic 27): Router.rememberClientLayerAt has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":992}}}],"partialFingerprints":{"codehealthFindingId/v1":"37338ee0874267d7e62707810781b2b934eed854ab2b265cfde61e471365b166"}},{"ruleId":"D1","level":"warning","message":{"text":"LangPackStore.ReconcileSeed (cyclomatic 27): LangPackStore.ReconcileSeed has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"61d43bfd0111cce95654580155427f9f4bade18506bbad14228204850907577e"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.approveInviteImporterTx (cyclomatic 27): ChannelStore.approveInviteImporterTx has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"eecd444b00aceba0f39282c25f51330dc7c0620c3157e62014b8b1abace40e44"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.ToggleCommunityParticipantBanned (cyclomatic 27): CommunityStore.ToggleCommunityParticipantBanned has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 1 of the 27 points is its own statement and the rest belongs to one function literal inside it that branches (line 919). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":918}}}],"partialFingerprints":{"codehealthFindingId/v1":"2abdcaafecf760d3607fba00c1a9e47132de67100f86a8a8630dd1d83599defa"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.UnpinAllPrivateMessages (cyclomatic 27): MessageStore.UnpinAllPrivateMessages has cyclomatic complexity 27 (threshold 15). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"0af3699632ec221e1125c4ec6211d87bf310de87780311f1104bc557c4dd008c"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.duplicateSendResult (cyclomatic 27): MessageStore.duplicateSendResult has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":713}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c5b8111f768fae371422af0c0de7fc32ff71e3a77271facf151ee58eaef1fd4"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.DropStarGiftOriginalDetails (cyclomatic 27): StarGiftLifecycleStore.DropStarGiftOriginalDetails has cyclomatic complexity 27 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_entitlements.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f054608d4f62940f51b15c8cd0bc0023e5f452efd5e8f61f0c4aea56870d49c"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.token (cyclomatic 27): Handler.token has cyclomatic complexity 27 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":587}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a74beadbb5c1a5ac0c6f93e2fa442ded5cf6e762ce6e0abeb4ffae1d88c1d14"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.DeleteAccount (cyclomatic 26): Service.DeleteAccount has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"99ecf0d8b58140296e11ab69a94d5d318635741101d996615234f5eddc267e75"}},{"ruleId":"D1","level":"warning","message":{"text":"HTTPProvider.composeOpenAIChatStream (cyclomatic 26): HTTPProvider.composeOpenAIChatStream has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b39cf7e97219b590dd5b4139f1e457e8d4eaa3eb83c719f08b051efdee1f8c3"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.Search (cyclomatic 26): Service.Search has cyclomatic complexity 26 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"072a46067afefe60bf19f4484d272dbccbd2cb9dcd2a6e05d6bfa0d1eb4083df"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.importDocument (cyclomatic 26): Service.importDocument has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"482d941c5efa41d2d0523517b5b004d4a0b865535194e8a63e301fcfe571f7e9"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ensureStickerMaterialShape (cyclomatic 26): Service.ensureStickerMaterialShape has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"afac046ca13e909c752c342dc979abe314f0366d6b990c120985ba0bedc5838a"}},{"ruleId":"D1","level":"warning","message":{"text":"telegramlogin.parseWebURL (cyclomatic 26): telegramlogin.parseWebURL has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/url.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"9166745580f5c67e62f428c85d62361e942cbf323310ffa4e40fddbdd4d09389"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.AuthorizeMessageButton (cyclomatic 26): Service.AuthorizeMessageButton has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"132ebe2ed42c0bb688eb7b1336532ceb3830493aed34255c7e45e092b13f08e9"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.resolveTexts (cyclomatic 26): Service.resolveTexts has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/service.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"4950c85accb7c9324e76d99212faed5554f340332218ebedef93450bb505571d"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.apiMessage (cyclomatic 26): botapi.apiMessage has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3b2c4ecbd1048ca2e5745a36ab6fbc9be7cb0643bf9b767130dddfef0b5894c"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.apiReplyMarkup (cyclomatic 26): botapi.apiReplyMarkup has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":486}}}],"partialFingerprints":{"codehealthFindingId/v1":"60249177f03ccfc574dc77d2a992d71760f3864bc9a8310d8f17823ef3724f7b"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.sendEphemeralLocation (cyclomatic 26): handler.sendEphemeralLocation has cyclomatic complexity 26 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"40f5be87fcda8a3d1b3e64a2ac1669a48a839171a0329b76d591e5b48e3890ba"}},{"ruleId":"D1","level":"warning","message":{"text":"webhookDispatcher.deliver (cyclomatic 26): webhookDispatcher.deliver has cyclomatic complexity 26 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/webhook.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"602e209967a83a0b37c093d8f109182eb59f0181b8c98aea2fcfb509acb7c6a8"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.seedRichAccountState (cyclomatic 26): loadharness.seedRichAccountState has cyclomatic complexity 26 (threshold 15). Most of this is not in the body itself: 3 of the 26 points are its own statements and the rest belongs to one function literal inside it that branches (line 66). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/rich_state.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"3538729d19a061f4a053fbaa59aacb5444fde314003a63a7554d44c0e1171c1b"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.SnapshotClientState (cyclomatic 26): loadharness.SnapshotClientState has cyclomatic complexity 26 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcecf58aab9abbc0611b4319b4b008308817b40eac36f76287586230a52b56e4"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.catchUpStartupChannel (cyclomatic 26): loadharness.catchUpStartupChannel has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":745}}}],"partialFingerprints":{"codehealthFindingId/v1":"358dfc3ad6894802dfbb71984f066d6fa256068500e02ca8306fbb26aa953afa"}},{"ruleId":"D1","level":"warning","message":{"text":"mtprotoedge.preflightInboundItem (cyclomatic 26): mtprotoedge.preflightInboundItem has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":648}}}],"partialFingerprints":{"codehealthFindingId/v1":"049c9db6ba5ee2473994f088aea0abd1f594af2996dcf6367b1ba8ee609fc93c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.cacheBoundAuthKeyLayerResolution (cyclomatic 26): Router.cacheBoundAuthKeyLayerResolution has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"032bd901f50d3f2bb840d92b6efcb17185cfa23716decac151acc4a4fe645d21"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.cacheResolvedDurableSessionLayer (cyclomatic 26): Router.cacheResolvedDurableSessionLayer has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/durable_layer_evidence.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"133ef48823d4eae9f02d56307756aab4dec707ea79c483e7ebd3ced9bded1161"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.DispatchAdmitted (cyclomatic 26): Router.DispatchAdmitted has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_dispatch.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"5967ec1c291e01079486092fb047e00f6a56bb15fdfe0cee5d54ac2e86b99557"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.messageFilterFromSearchRequest (cyclomatic 26): Router.messageFilterFromSearchRequest has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":834}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5fc1ba8c7056a0bc6a07e95c0c97070cd662e5de808ecdd654dca3d668c9732"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesAcceptURLAuth (cyclomatic 26): Router.onMessagesAcceptURLAuth has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"c98fb0cc9210d569d45e93cc2a234424467154fe8f4e75692afc0e5723e8b5d3"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onUsersGetUsers (cyclomatic 26): Router.onUsersGetUsers has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"46ff926f47e3a9395244d9558910ca39c4fa9324973bc9b40501a892e9d74dda"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListDirtyActiveChannelsForUser (cyclomatic 26): ChannelStore.ListDirtyActiveChannelsForUser has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"e03594ec88ba7e1b97b9598c2c3e7fad72d3fc277ae3210cd5199f1de26be5ac"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.resolveChannelReplyLocked (cyclomatic 26): ChannelStore.resolveChannelReplyLocked has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"648f5689bc17e73973212073808190a95016affb4ef181336882cb6323d1b2e0"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteChannelParticipantReactions (cyclomatic 26): ChannelStore.DeleteChannelParticipantReactions has cyclomatic complexity 26 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"68f53a7e25ce222c456cf3cc654574a64238b7a35e0b461c27e6353b2d179e71"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.pruneConfirmedUserPrefixTx (cyclomatic 26): postgres.pruneConfirmedUserPrefixTx has cyclomatic complexity 26 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event_retention.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e5bfc3653d992d4de207040591b86d5b03ab8f95f41cdd6957a3c350ecbb1d9"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.CreateChannel (cyclomatic 26): ChannelStore.CreateChannel has cyclomatic complexity 26 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"672157f2234ef330e9d90703a11c2916e3b63f5561326039a359b316da031fc4"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.processSuggestedPostLifecycleOne (cyclomatic 26): ChannelStore.processSuggestedPostLifecycleOne has cyclomatic complexity 26 (threshold 15). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"174278fbb9a14167fb04eec7e9585767b1f47e5ddf73757636e2f1601ab5ada5"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.loadChannelDifferenceBase (cyclomatic 26): ChannelStore.loadChannelDifferenceBase has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa80009084237e6f0956e538d72b582cbb6e2459f9c95105b854213c2f8177f1"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.PurchaseStarGift (cyclomatic 26): StarGiftLifecycleStore.PurchaseStarGift has cyclomatic complexity 26 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 5 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf7e6a2627fb0f3132df975e37bb13f3e5f9eef2828a38054aee929783f21875"}},{"ruleId":"D1","level":"warning","message":{"text":"main.main (cyclomatic 25): main.main has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 5 of the 25 points are its own statements and the rest belongs to one function literal inside it that branches (line 111). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/catalogfetch/main.go"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"97aa3d39a845d27017f2f496d22b1dcf34b8958cc95de59ff64a8eacaf6229b8"}},{"ruleId":"D1","level":"warning","message":{"text":"bots.validStickersBotEmoji (cyclomatic 25): bots.validStickersBotEmoji has cyclomatic complexity 25 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":779}}}],"partialFingerprints":{"codehealthFindingId/v1":"54c1db50baf5813538d0162dd87780ddea7dde635a7c48e3af57af0cc8141b95"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SeedPremiumPromo (cyclomatic 25): Service.SeedPremiumPromo has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/premium_promo_seed.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"197edad137a34ca80bd4190b979d98cd78128f7808f93f5c1851f972b7801e98"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SeedMedia (cyclomatic 25): Service.SeedMedia has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"18869af9fcbad89f168cf5d9980885638f6e4cab4df60c97365921cede3637fd"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.sendMedia (cyclomatic 25): handler.sendMedia has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: handler.handle (cyclomatic 41) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":650}}}],"partialFingerprints":{"codehealthFindingId/v1":"846ea5a9de8f6c295b0a384373ad546fc8260607f5493cb4053653084604c1ce"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.handleRPC (cyclomatic 25): Server.handleRPC has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":745}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2c146c8c04279f0e25a85d1e868f1e3192217ad808c797c1cedb911601235e0"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgChannel (cyclomatic 25): rpc.tgChannel has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":449}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6a608e7567e109af945165f1a89edc1a9509b4f8208a2ef793507839ca3413f"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onEphemeralSendMessage (cyclomatic 25): Router.onEphemeralSendMessage has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8532e143e5956e2d80d1555d5dfaf17ec44a8b9b39dca2a75437c129beac471"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.BuildOutboxUpdates (cyclomatic 25): Router.BuildOutboxUpdates has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/outbox_update_builder.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"89847c631b257a9f59ae13a936a48d121a0c4343c50080ca708a002ade3dd913"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.resolvePremiumInvoice (cyclomatic 25): Router.resolvePremiumInvoice has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_premium.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9899025827e7a785a8f55df49fa8bf4ecf2063b69487bc7c7bce1fc94cc2065"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onUpdatesGetDifference (cyclomatic 25): Router.onUpdatesGetDifference has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/updates.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8872a739daea0847d4c3f5d04d49b0d9249209b93945a970f234ef865c36284"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditExportedInvite (cyclomatic 25): ChannelStore.EditExportedInvite has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"385bf536dd8d32effc537498ecb0211edf1a21d39b1f6d6eb9a2e98a310d0ec9"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.channelMessageRepliesLocked (cyclomatic 25): ChannelStore.channelMessageRepliesLocked has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"42cd8b8a878c0d31129521786b6bad4cebaabd4271ec91a181822927e33fa822"}},{"ruleId":"D1","level":"warning","message":{"text":"VerificationStore.ListVerificationApplications (cyclomatic 25): VerificationStore.ListVerificationApplications has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":501}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb790165c549f7297d957add73d0dcf8a545cd17fc7efab96e300cb73a434850"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelMessageReactions (cyclomatic 25): ChannelStore.ListChannelMessageReactions has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":415}}}],"partialFingerprints":{"codehealthFindingId/v1":"96b8ed550563c4e3bafb57ee2d00ceaac3f6b2848f7445a6dc3711734c7565dc"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.populateChannelMessageReplies (cyclomatic 25): ChannelStore.populateChannelMessageReplies has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":722}}}],"partialFingerprints":{"codehealthFindingId/v1":"065d1e6a01ee8b0e93af02e03eadc81cf29357e9c0c7393c334e13f89a463583"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ForwardPrivateMessages (cyclomatic 25): MessageStore.ForwardPrivateMessages has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d5bfae78d81dbd211c701b07487e5d71ef2406a10389b7a499adce341185cd8"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.mutateMessagePoll (cyclomatic 25): MessageStore.mutateMessagePoll has cyclomatic complexity 25 (threshold 15). Of this number, 24 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_polls.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"a374e79506c1c125791da34fbf2765a6ed5a1a010d9b88d4c67dedd708285870"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.DecideModerationCase (cyclomatic 25): ModerationReportStore.DecideModerationCase has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"c00f9677bbc24b53ab4b3a3233a2fb548423d2b42bdab0d4e001ddeca586ceae"}},{"ruleId":"D1","level":"warning","message":{"text":"ReadModelChangeListener.flush (cyclomatic 25): ReadModelChangeListener.flush has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_listener.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8e300e3616a57f106f676e489e6c361d382bfaaf697b2b6af391993816ef3a3"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftStore.ResolveSavedIDs (cyclomatic 25): StarGiftStore.ResolveSavedIDs has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":669}}}],"partialFingerprints":{"codehealthFindingId/v1":"34d64fa0ef05ef1939f72430acb51750d7a7a5c3e49a952b2db6e1c5a737cbe0"}},{"ruleId":"D1","level":"warning","message":{"text":"main.run (cyclomatic 24): main.run has cyclomatic complexity 24 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/blob-migrate/main.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"01b1fb9ba22091d9cb80448abd8327ca989c6a9f44e37e5aac25397de0e8092d"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.verifyPasswordRecoveryCode (cyclomatic 24): Service.verifyPasswordRecoveryCode has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":631}}}],"partialFingerprints":{"codehealthFindingId/v1":"e275b3582393edbc81cd18acd0db7a1b787d38ea29a189ac75687a05808c0ae3"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.WatchChain (cyclomatic 24): Service.WatchChain has cyclomatic complexity 24 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/watcher.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"c27e75e6cb7121f43da5a6220cf178f81e20287c46ce6a0ea5bc0cab526da89a"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.editFieldsFromBot (cyclomatic 24): Service.editFieldsFromBot has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8312cb3653b640ac2135d3f00501a38d45a2b6e698fb891bb77cff23c5dc82d"}},{"ruleId":"D1","level":"warning","message":{"text":"telegramlogin.validateRawSigningKey (cyclomatic 24): telegramlogin.validateRawSigningKey has cyclomatic complexity 24 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/jose.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"7374be185ff45fc9d78356f9a3de8cdb63ea2a17a3fc29dd8df2840baab575fd"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.richMessageInputFromAPI (cyclomatic 24): botapi.richMessageInputFromAPI has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/rich_message.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"622963fc09413ffdb0cf6cfbb39cf5e6f63b83d43e4581fd657a22ee90383767"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.editMessageText (cyclomatic 24): handler.editMessageText has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: handler.handle (cyclomatic 41) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"0360da7afea15bffd35f51856478e837bcded8dfcd003d570ad9a39ea886d5a9"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.setWebhook (cyclomatic 24): handler.setWebhook has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: handler.handle (cyclomatic 41) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"123beb2060e6e39c5401493076ea511f2dd7e83d380884720c16b771f132c80b"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.ApplyPremiumBoostSlot (cyclomatic 24): domain.ApplyPremiumBoostSlot has cyclomatic complexity 24 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/boost.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a26fca692662ca1626dbec55fe65edc4471f7ff4c5ede6e23fe999530c5e505"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationAppeal.Validate (cyclomatic 24): ModerationAppeal.Validate has cyclomatic complexity 24 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation_case.go"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"74915b812906e9345949d2d912788b5d900a577d2691eb95d2284600b8092a4b"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.snapshotDialogsObserved (cyclomatic 24): loadharness.snapshotDialogsObserved has cyclomatic complexity 24 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd8862053653b8aa8c9a8e599beb7c9e65d08f6bdabd6e34b24fff57f40acc5b"}},{"ruleId":"D1","level":"warning","message":{"text":"OfflineMutationState.Validate (cyclomatic 24): OfflineMutationState.Validate has cyclomatic complexity 24 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":584}}}],"partialFingerprints":{"codehealthFindingId/v1":"a156c59cf02058d5f62e4300aa9a2b547ab8200501ae168cc2bfcc0410e30254"}},{"ruleId":"D1","level":"warning","message":{"text":"serverMetricsClient.scrape (cyclomatic 24): serverMetricsClient.scrape has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/server_metrics.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfeeee435eb93ebccf29e7f91211482a367833a72935cfc862b2394a8cb7e28c"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionManager.runFlush (cyclomatic 24): SessionManager.runFlush has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1242}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc5fe74a960a337fb52403dbe4038535e689b3df330a8ce87de003a1bbac27e6"}},{"ruleId":"D1","level":"warning","message":{"text":"Cache.GetOrLoadBatch (cyclomatic 24): Cache.GetOrLoadBatch has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/readmodelcache/cache.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"a75c706cbdfb0c4eea59a4e15e86545db508dd4445106c827608186c72038bc5"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onContactsSetBlocked (cyclomatic 24): Router.onContactsSetBlocked has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"859d26126ef6778f7a6330ee23a00c12210b31bcde7900e43c1e389fa72c4f6f"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.editChannelInlineBotMessage (cyclomatic 24): Router.editChannelInlineBotMessage has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"b340a1a44d10633a5b34fba94a55594e2f1b62f851b2da8d76dbd983d88e0926"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.starGiftRefFromInput (cyclomatic 24): Router.starGiftRefFromInput has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1366}}}],"partialFingerprints":{"codehealthFindingId/v1":"0386589fbf3585f63de2a399d4004c88b234aeafd273369f6bcd8a2b52e341f9"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPhoneDeleteConferenceCallParticipants (cyclomatic 24): Router.onPhoneDeleteConferenceCallParticipants has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_conference.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"74c2b8bdf8fc5712bb5286821bb99db6d7b3d98a2763c1ef67be5c37b8761019"}},{"ruleId":"D1","level":"warning","message":{"text":"memory.channelDialogMatchesFilter (cyclomatic 24): memory.channelDialogMatchesFilter has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8da90f0524ff06e6dfa03e6e12798a3a303c21c6b3ab131dd2498cac2714a44"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditChannelAdmin (cyclomatic 24): ChannelStore.EditChannelAdmin has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"03b38070ff73df4183253c2fa78211e2c2875fb04cc0360de5a19e0c64aea1a3"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteChannelHistory (cyclomatic 24): ChannelStore.DeleteChannelHistory has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"0900c1ba48dd7cebdcf445f845df78c9526c4091b63d56694dc84b258380265b"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ChannelPollFanoutViews (cyclomatic 24): ChannelStore.ChannelPollFanoutViews has cyclomatic complexity 24 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_polls.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8693f62a9a376c2173da555e5972931c5ae216c763dee71d820a6b55817dfaa"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ForwardPrivateMessages (cyclomatic 24): MessageStore.ForwardPrivateMessages has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_forward.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"e452a7728a16eb814833d5babd0cb993e8d4d6adb769d5d06a4c8309ff20ac9e"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.PutTelegramLoginAuthorizationCode (cyclomatic 24): TelegramLoginStore.PutTelegramLoginAuthorizationCode has cyclomatic complexity 24 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"be811c085909dbbb796adc4bc08d78e4f95f23ffc097bb3bd1d3eae50f04d69a"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteChannelParticipantReactions (cyclomatic 24): ChannelStore.DeleteChannelParticipantReactions has cyclomatic complexity 24 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0d1f184040d84c2433b7fee99305a34acd365fa1c55dab66ceedfb560443cd6"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditForumTopic (cyclomatic 24): ChannelStore.EditForumTopic has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8643ddae15615823488ef9c60a25c076fcd8d46742df31344bfcfe85c9ce1db"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelReplies (cyclomatic 24): ChannelStore.ListChannelReplies has cyclomatic complexity 24 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":588}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9f62e9100f0f4909bd1fc93d54af12460e6e6541126429170a1415a3a475ecc"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.pruneChannelUpdateEvents (cyclomatic 24): ChannelStore.pruneChannelUpdateEvents has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 7 of the 24 points are its own statements and the rest belongs to one function literal inside it that branches (line 132). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_update_retention.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"57ce0107770c1ea1b1d7fbc48bab80fd26cca7a988cea84d2293083d04f6b2f3"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ReserveAlbumGroup (cyclomatic 24): MessageStore.ReserveAlbumGroup has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/album_group.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf7f8ab6ef25248c0271bdf77c6ec637260fc2d150ac6480082a12ed9b805d1a"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ListByUser (cyclomatic 24): MessageStore.ListByUser has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"1420e199ca31d5c9d1c8dd515c8d3cca9b04fc08b87f037ed8b6c51ecaa51b60"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.EditScheduledMessage (cyclomatic 24): MessageStore.EditScheduledMessage has cyclomatic complexity 24 (threshold 15). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f228473e098143d254a5e5ce6d4c6ceafc5349ef642be6e9b572cb3d617beab"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.loadStarGiftPurchaseReplay (cyclomatic 24): StarGiftLifecycleStore.loadStarGiftPurchaseReplay has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"9423245e41caa5616dfa30ef1046f8f5b0807fea10d8bdcdf12686261ac29688"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.runCommand (cyclomatic 23): Service.runCommand has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3933}}}],"partialFingerprints":{"codehealthFindingId/v1":"e22bfa92ba211fe9b5c4be96fe9d81a747c5c54ca39e082860affcb37fd96391"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.appearanceSeedReady (cyclomatic 23): Service.appearanceSeedReady has cyclomatic complexity 23 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"18ac0ab2f7fd3a7db78e924498d4b69881b97c816e2793ea94f4572bc0fcbeb4"}},{"ruleId":"D1","level":"warning","message":{"text":"giftpack.ParseManifest (cyclomatic 23): giftpack.ParseManifest has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/giftpack/manifest.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bfec479b44293ca512f807ac0d24ba17a898139792e8eee3151720e2d65f38b"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SendPrivateText (cyclomatic 23): Service.SendPrivateText has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"4646b18103a2f55fc85d62551465974370f83a2857aba623ef8985efe7612b38"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ReportMessages (cyclomatic 23): Service.ReportMessages has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"6726b787c558f10a1f6b928d93f5c4bd61ea45752adda5ee9983f1d64ffca271"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.exchangeAuthorizationCode (cyclomatic 23): Service.exchangeAuthorizationCode has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":1297}}}],"partialFingerprints":{"codehealthFindingId/v1":"482fdc574e348ef272f9eaa70a1b773d6336d68e3e61a305732e156b364e0155"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.candidateStates (cyclomatic 23): Service.candidateStates has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":1080}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb9bfb5e8f8dd275bb5eaabeef4b6a28be9d4c92850a4f079c709d343fba0a00"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.classifyError (cyclomatic 23): loadharness.classifyError has cyclomatic complexity 23 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1345}}}],"partialFingerprints":{"codehealthFindingId/v1":"930421ae640567f1caa80455f2c60b304130c7ef436db061f653828ffa7bfbc1"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.runStartupAccount (cyclomatic 23): loadharness.runStartupAccount has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 7 of the 23 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 461, 447). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c809fd6a13c989097970d4a47465456841fb4b50d19132052786a51026c127f"}},{"ruleId":"D1","level":"warning","message":{"text":"inboundRPCBatchReservation.commit (cyclomatic 23): inboundRPCBatchReservation.commit has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 5 of the 23 points are its own statements and the rest belongs to one function literal inside it that branches (line 689). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_rpc.go"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d5547097bf8404693c15743b8ca6f03be373c7f51341d8974c54c6f5413c5b0"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.postProcessBotAPIRichText (cyclomatic 23): rpc.postProcessBotAPIRichText has cyclomatic complexity 23 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_message.go"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"95f3cd84de3e309b13f77eb791cce2c083b8ef61e07cd102ab7298597592446f"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgUpdatesDifference (cyclomatic 23): rpc.tgUpdatesDifference has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"df745aa83fc9809e49e473b224fb17cc4b17439e412220750817415002461130"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onChannelsGetFullChannel (cyclomatic 23): Router.onChannelsGetFullChannel has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"f73bff316238fb84b2feb5ef2373eb519436487c7e9c70720a46247c88276ac4"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesUnpinAllMessages (cyclomatic 23): Router.onMessagesUnpinAllMessages has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"890719fd0f38635510b7c452390422b242e89dbbfb2461f557a4ade69948d910"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.deliverEphemeralPushLocal (cyclomatic 23): Router.deliverEphemeralPushLocal has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral_push.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbefb76b2bf011e7f1a1ef780cf644ceb7f0f3ab42f9f09ec0d3c0f1413d8f8a"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesReorderPinnedDialogs (cyclomatic 23): Router.onMessagesReorderPinnedDialogs has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":767}}}],"partialFingerprints":{"codehealthFindingId/v1":"e27f5463af8048ce5654134357e30ed6f3577358464a0356ac74ea9af97cc936"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesReadDiscussion (cyclomatic 23): Router.onMessagesReadDiscussion has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"483725380183da70b3e2a8ba438d553a16025fab5954471a7ebfb3640391a30c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetPollVotes (cyclomatic 23): Router.onMessagesGetPollVotes has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d5e669c46d0dbaca10380446fee32b7eef66bf5ab713693f2a9ca76e08299aa"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.savedDialogsProjection (cyclomatic 23): Router.savedDialogsProjection has cyclomatic complexity 23 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_saved_dialogs.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"3746e9f1a0c4956e4785f2130083709b7584880e4b32886757327e3504265f2d"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPhoneJoinGroupCall (cyclomatic 23): Router.onPhoneJoinGroupCall has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"614d1d73d83b400380bb839bd7fa4b4442190606ef8f7eb159d31a3e70c3bf11"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.JoinChannel (cyclomatic 23): ChannelStore.JoinChannel has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"cae9379205997374ddf1d2d1b1f6f4e8c28c95da75aa1854c751ed78c636115c"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ResolveDiscussionReadTarget (cyclomatic 23): ChannelStore.ResolveDiscussionReadTarget has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":529}}}],"partialFingerprints":{"codehealthFindingId/v1":"e964a7efb6ba524e74a61378cf27f62cbb6ea065591c0f0a15b22ba7429ad820"}},{"ruleId":"D1","level":"warning","message":{"text":"GroupCallStore.RemoveConferenceCallParticipants (cyclomatic 23): GroupCallStore.RemoveConferenceCallParticipants has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"a512fec8cf719128f4938f58935df52e0d09996b04df7ae01abe18b4bdb18757"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.PinPrivateMessage (cyclomatic 23): MessageStore.PinPrivateMessage has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1cb5c09e80b9427fc777068c4d4cdb554170b57b787a82b5792271310e70a11"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.resolveMemoryReplyLocked (cyclomatic 23): MessageStore.resolveMemoryReplyLocked has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_send.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"935f7c0c773dfe741baa6ea2a35fbfd0af54095bdbef21957dba6f901dfd58ff"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.ReviewModerationAppeal (cyclomatic 23): ModerationReportStore.ReviewModerationAppeal has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":503}}}],"partialFingerprints":{"codehealthFindingId/v1":"580dfca6dca2f4796ecd0649d3d3c756a0e13ba5ee09acbf9dcfd83d983bd784"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.ConsumeTelegramLoginAuthorizationCode (cyclomatic 23): TelegramLoginStore.ConsumeTelegramLoginAuthorizationCode has cyclomatic complexity 23 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"eaf4d9a88de54990d22180d2742470b889ae267df3c69c67841dc117c600cd99"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.DeleteExpiredTelegramLoginArtifacts (cyclomatic 23): TelegramLoginStore.DeleteExpiredTelegramLoginArtifacts has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":670}}}],"partialFingerprints":{"codehealthFindingId/v1":"0687178eae525c5be158b03bff97f765910cba1b40dfef5c5bfa39a82f85c353"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.channelDialogMatchesFilter (cyclomatic 23): postgres.channelDialogMatchesFilter has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":2128}}}],"partialFingerprints":{"codehealthFindingId/v1":"716e22ae621585abfb83963f84ee2a3bfa8f617c58c9263861e235881fe80516"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.insertChannelMessageWithFingerprintTx (cyclomatic 23): postgres.insertChannelMessageWithFingerprintTx has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":554}}}],"partialFingerprints":{"codehealthFindingId/v1":"c03de316ce2d2d65aade9eddb33cbc8bd1596ca4f11f2fe304964f68cbd76c65"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.persistPlainPrivateSendProjection (cyclomatic 23): postgres.persistPlainPrivateSendProjection has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_hotpath.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"e17ab234b471bd84a0515f99a3b241c6e21ed7975f06f642d74421a87dc62e23"}},{"ruleId":"D1","level":"warning","message":{"text":"PasswordStore.SaveMusic (cyclomatic 23): PasswordStore.SaveMusic has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 4 of the 23 points are its own statements and the rest belongs to one function literal inside it that branches (line 789). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":785}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c9f75ac50369a8feab0b79e106866dc6d5a4a3e9187bfc503a8a815788f0f5a"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.mutateChannelMessagePoll (cyclomatic 23): ChannelStore.mutateChannelMessagePoll has cyclomatic complexity 23 (threshold 15). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_polls.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d2ee9ab47dab1090f4cc76582468f6103bf07d677b4cd28fefc6694da7c509d"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftStore.ListByOwnerFiltered (cyclomatic 23): StarGiftStore.ListByOwnerFiltered has cyclomatic complexity 23 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"2191f9b484515145cde265e73852ec07ac7ee4a83e0baabcb0b960c83522ce5b"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftStore.PublishCollectibleRevision (cyclomatic 23): StarGiftStore.PublishCollectibleRevision has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 2 of the 23 points are its own statements and the rest belongs to one function literal inside it that branches (line 53). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc93c1525bc603d19c536edbdd137075d1d28ed1ea08259a890a1f6798d701b4"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftUpgradeStore.loadAdminStarGiftGrantReplay (cyclomatic 23): StarGiftUpgradeStore.loadAdminStarGiftGrantReplay has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"715d69018589e9df73c501edc6b12416a15fa398a82a5725d6fb5d8236983841"}},{"ruleId":"D1","level":"warning","message":{"text":"main.classify (cyclomatic 22): main.classify has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 9 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 393). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a274c90f9aa751078750e66c0274fb25ea8f85425a07a242905fc21b109da6b"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ConsumeLoginEmailReset (cyclomatic 22): Service.ConsumeLoginEmailReset has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":999}}}],"partialFingerprints":{"codehealthFindingId/v1":"3296318a074ac0f0f00bf7ae7504035abab01284b820f76f96a1255f83fa7ba6"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.seedEmojiGroupIcons (cyclomatic 22): Service.seedEmojiGroupIcons has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/emoji_group_icons_seed.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"289cd178ddbace87c2ce50cf0001c54469d0dcd031abbb635024043c9ceaec9e"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ManualPurge (cyclomatic 22): Service.ManualPurge has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"64a715cc9dba47b20aeec4390e5f1f20f0f4732392188453673257a80658f657"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.seedDocumentJSONsReady (cyclomatic 22): Service.seedDocumentJSONsReady has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed_state.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"08bb2a06fba5d30126731d521d9e7a04ec138bc7cbfefe04a12c332ddbb43392"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.loadMembershipFactsForKeys (cyclomatic 22): Service.loadMembershipFactsForKeys has cyclomatic complexity 22 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service_sparse.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad8e0892d4184a556e76b9cfa56ccbe37b64251cef25e760e17c0b617c810441"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.parseEphemeralSendTarget (cyclomatic 22): botapi.parseEphemeralSendTarget has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce5b93bfba10d52d6b843a1ced6cd6ea6e05403fb85a0c2546127c13f2942cc8"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.validateBotAPIFormattedText (cyclomatic 22): botapi.validateBotAPIFormattedText has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"05e9f318d33ebd20a0fa5472944afe82ec6a9a579ca8ac5ab93c050070e5b835"}},{"ruleId":"D1","level":"warning","message":{"text":"config.validAdminPermission (cyclomatic 22): config.validAdminPermission has cyclomatic complexity 22 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1952}}}],"partialFingerprints":{"codehealthFindingId/v1":"df9412493fe7a3d950bce58b5b380ad04f1ea30749b1051a0df6748b321cb99a"}},{"ruleId":"D1","level":"warning","message":{"text":"ClientTelemetryEvent.Validate (cyclomatic 22): ClientTelemetryEvent.Validate has cyclomatic complexity 22 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/client_telemetry.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d1e6a807ab3a6bacc6c04d3220ac67f363b8cdd7d2a96df690769ca3f720ebb"}},{"ruleId":"D1","level":"warning","message":{"text":"mtprotoedge.closeConnBatch (cyclomatic 22): mtprotoedge.closeConnBatch has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1079}}}],"partialFingerprints":{"codehealthFindingId/v1":"12478f4106c58dd00d0693b97d56bd46036833bd68f5934813dc26c0d43f5ed4"}},{"ruleId":"D1","level":"warning","message":{"text":"outboundTrackedBudget.waitReserveUntil (cyclomatic 22): outboundTrackedBudget.waitReserveUntil has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1269}}}],"partialFingerprints":{"codehealthFindingId/v1":"abbbce05964d3697af5ea9da885522c7eb2385358ee860282739b2dc96fa54cc"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.handleAdmittedLayerRPC (cyclomatic 22): Server.handleAdmittedLayerRPC has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/layer_rpc_execution.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ea14929218ab0daf5fb198856f07e9e63faf4fe202d565a05e302ed660ba632"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.BootstrapEnv (cyclomatic 22): Manager.BootstrapEnv has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/bootstrap.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e3402ba1649029b29ed9d9c6452811ff02ff2e5dbdfe1b350ee69980fc590dd"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.checkBotDownloadFileParams (cyclomatic 22): rpc.checkBotDownloadFileParams has cyclomatic complexity 22 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":826}}}],"partialFingerprints":{"codehealthFindingId/v1":"933ec82c1b542a4f0e8231374c6a0628d64947f6d2eb9cf34cdf6cfbc0efef2e"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.storyViewUserIDs (cyclomatic 22): rpc.storyViewUserIDs has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_peer_projection.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"84599243a6931e898424651874bf4fc4defdde6c57835c5b84664407916b3a9d"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.channelFanoutRecipients (cyclomatic 22): Router.channelFanoutRecipients has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"974396d477b2db5283be228d9db62e706b6310de71fc7ad8f75aa066aed9f044"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetMessageEditData (cyclomatic 22): Router.onMessagesGetMessageEditData has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e00da16f635748c9a2a4fd271b9e852c883097758ee39a4ce10f79564026c1f"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.starGiftAuctionBidTarget (cyclomatic 22): Router.starGiftAuctionBidTarget has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"a471212aa5a5719b5e5f417b79b914276f2936135f3b618bbfcbbd85a8f0ea12"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPaymentsCraftStarGift (cyclomatic 22): Router.onPaymentsCraftStarGift has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":792}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc965df3aa7018f1b56135b876d8b0de654f469bed8de8adf1f1426ea2e6ef99"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.groupCallScopeFrom (cyclomatic 22): Router.groupCallScopeFrom has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"b582e1950584d795c0f6685cf5b4df09b0e5ec4dab361c74e60db7e03ab8df55"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPhoneCreateGroupCall (cyclomatic 22): Router.onPhoneCreateGroupCall has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"17aa0c3315c6ee35d662e413aa41d2e7c83519ac2a0533f48ebe88954c3906b8"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPhotosUploadContactProfilePhoto (cyclomatic 22): Router.onPhotosUploadContactProfilePhoto has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1d9c0703253ac14845bfb229c988eba9be0e2a8bd13039b0a31d9953af4e614"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.rememberClientInfoAt (cyclomatic 22): Router.rememberClientInfoAt has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":898}}}],"partialFingerprints":{"codehealthFindingId/v1":"93848eec895e241bcb12a35c348fcd54989ab99bfe6d0bbc2de252d0cc7c66d2"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onStatsGetPollStats (cyclomatic 22): Router.onStatsGetPollStats has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb968eb8413b18f538ff6d0a5854f99535289096feeae6b2d5996ae6e9f57b88"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onStoriesGetAllStories (cyclomatic 22): Router.onStoriesGetAllStories has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: rpc.messageEntityClassNil (cyclomatic 27) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad4d0d4ceefb37d5bf7369e664ec4521c2b96d4ba909839935788144dd32e67c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.applyStoryMaxIDsToPeerObjects (cyclomatic 22): Router.applyStoryMaxIDsToPeerObjects has cyclomatic complexity 22 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_peer_projection.go"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"17f60d2143161aa2b5a35220a2c15ae7899632673299f99adb3f3959368e1a7c"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListInviteImporters (cyclomatic 22): ChannelStore.ListInviteImporters has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbd2864d23b8b5fc4b9753a3152525e30ff227dce10bd659931ca8eb5460e0fc"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditChannelBanned (cyclomatic 22): ChannelStore.EditChannelBanned has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"37963d7eb41706e58da779ba4614a017987d1cb7596453bf7241f019786c339b"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.CreateForumTopic (cyclomatic 22): ChannelStore.CreateForumTopic has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"7492adc57b60431c3b5aea1b2a2e5fcb8b964b93279c312fc5da5edf55a0e135"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditForumTopic (cyclomatic 22): ChannelStore.EditForumTopic has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"de69420971c03433a0d007b7dc913c7d2b73770ad681b593999d19568dd792b2"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.validatePeerLocked (cyclomatic 22): CommunityStore.validatePeerLocked has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cd63d1884c965e501d5abbab3b79988f6e4a7d7afcb6574702083207ca86110"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.ListCommunityParticipants (cyclomatic 22): CommunityStore.ListCommunityParticipants has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":825}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ee9a5341dc0775205d9acfc961f6e242f780e02704e2e57a6fd9b50d19891ff"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.SetMessageReactions (cyclomatic 22): MessageStore.SetMessageReactions has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7188e119f9aa234a3cf831fc6396ced20e45418ae3a6c9f987c6537c0d7da2f"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ListSavedDialogs (cyclomatic 22): MessageStore.ListSavedDialogs has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"85ee5509abaffcff31778e4b48836add8d5a1f32b6f4bc824e90053f40da54c1"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.DeleteSavedHistory (cyclomatic 22): MessageStore.DeleteSavedHistory has cyclomatic complexity 22 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cb51aab36ad9426de312fc82dee255471184323cbfe4a3a0364eb0ef60de800"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.bindAuthorization (cyclomatic 22): postgres.bindAuthorization has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authorization.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d9e07a64103665a90dc0c523f5a7610448749883e348de0b33e2e2d7937e8b1"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.pollViewerAggregates (cyclomatic 22): postgres.pollViewerAggregates has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/poll.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"51c756f5b86063c6aa2c4649e0c87ec0415094d6ccd7518af6d176b91b496354"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteChannel (cyclomatic 22): ChannelStore.DeleteChannel has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"447e1133f83c5bfbf4c031621f5e3d130e9cfb3a70a3a7aeb4a741c953ffbb0a"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.deleteChannelMessagesTx (cyclomatic 22): ChannelStore.deleteChannelMessagesTx has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":438}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9ed2f0b23c8c99385a23ea63252b7cd9afc3bbd287af2f8c0d68f4204fa75c8"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.reconcileChannelEditMentionsTx (cyclomatic 22): ChannelStore.reconcileChannelEditMentionsTx has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":639}}}],"partialFingerprints":{"codehealthFindingId/v1":"585205463a6be1198b7de0d005b218895bec7f5ad92eee4056c65d5f764895d3"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.channelMessageViewReplies (cyclomatic 22): ChannelStore.channelMessageViewReplies has cyclomatic complexity 22 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_views.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1f413d1bee1eb75d8fd6ab3bd6dfea201afcd1d10ea0025e76c455e75633517"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ReadChannelMessageContents (cyclomatic 22): ChannelStore.ReadChannelMessageContents has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddc96a3b72c474c1e2df4554d938c620d8df5ff7b93c8ea700d51bf3ae189b30"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelMessageStats (cyclomatic 22): ChannelStore.GetChannelMessageStats has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":336}}}],"partialFingerprints":{"codehealthFindingId/v1":"0403c42902963d0acc85ab9231a7347f4aae69f200487f545f0ce79ecdee251f"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteForumTopicHistory (cyclomatic 22): ChannelStore.DeleteForumTopicHistory has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b75dac9b8a9244378349b24ec015c601b1b63f7ddb66aa8d5912485e83becc8"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.CompleteModerationAction (cyclomatic 22): ModerationReportStore.CompleteModerationAction has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":816}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbe36ae5ea9c76f449b082e1d53f079a03aed41e622efec4852f07a655a50c5e"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.RecordStarGiftWithdrawal (cyclomatic 22): StarGiftLifecycleStore.RecordStarGiftWithdrawal has cyclomatic complexity 22 (threshold 15). Of this number, 11 points are the body\u0027s own statements and 11 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1522}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e26f706a5876e5f79c913fa1d842ea1fa4eb6ef903e89b75f005ffe7002a449"}},{"ruleId":"D1","level":"warning","message":{"text":"UpdateEventStore.BatchByCursor (cyclomatic 22): UpdateEventStore.BatchByCursor has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"38a2574cc1b88ec6157e15de38f24a38ae5cc10bf2d19ee4860448275e62bd34"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CheckTmpPassword (cyclomatic 21): Service.CheckTmpPassword has cyclomatic complexity 21 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/tmp_password.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"eddb4a0668525a472318485b36c330342bc1d166713bb3150a46ca680a9c6dce"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.resendCode (cyclomatic 21): Service.resendCode has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":861}}}],"partialFingerprints":{"codehealthFindingId/v1":"d76d697890226bec45d51e703ee73383e4dbaab47fb195eb2a11e947719c25e3"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CreateDocumentFromUpload (cyclomatic 21): Service.CreateDocumentFromUpload has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ab429aa43e2fef20d9c46fc3f99a47d7e6bb767ef45564deea5079dcad29c52"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.documentsNeedSeedRepair (cyclomatic 21): Service.documentsNeedSeedRepair has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: files.seedThumbMimeType (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":1093}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b214e3312daa5b791fd08c7b2b46510339c97004dbdcc2427f5790e7904c792"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SeedDirectory (cyclomatic 21): Service.SeedDirectory has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/seed.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0746df12e9234bd7af2a293c4149563f69e097f57eff033fd8f2df1ba04b9c4"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.Withdraw (cyclomatic 21): Service.Withdraw has cyclomatic complexity 21 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":804}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbcc2ca5c35625eb0bd7a953d4c5d7c4f79dea3bdbc796204f657d73cd45e1c5"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.Translate (cyclomatic 21): Service.Translate has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/service.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e58865ba67f2a1e9319ce23cbfe344eb4307179809b1e5ea7f56db9c4839d05"}},{"ruleId":"D1","level":"warning","message":{"text":"CachedContactStore.ContactProjectionForViewerUserIDs (cyclomatic 21): CachedContactStore.ContactProjectionForViewerUserIDs has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache_sparse.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"829539f6061bf0a12f8e66e7b77164649057856671c591087a6f0d2eb39f1a30"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.requestValuesWithFiles (cyclomatic 21): botapi.requestValuesWithFiles has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: handler.handle (cyclomatic 41) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1280}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d9d3b72d1e40d5068cbd3509d6eda8ba9b09d826d74b5c35927ca2038f76400"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftCatalogWrite.ValidateLifecycleAuthoring (cyclomatic 21): StarGiftCatalogWrite.ValidateLifecycleAuthoring has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":931}}}],"partialFingerprints":{"codehealthFindingId/v1":"37d3c5028fa506c60be5d6b3405d10af4b9c387eda04eb8212807345a74bda18"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.Seed (cyclomatic 21): loadharness.Seed has cyclomatic complexity 21 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe60570af9066dc588105d508496c8915ecf141936927b476ce54818c06d7c7b"}},{"ruleId":"D1","level":"warning","message":{"text":"prop.numbers (cyclomatic 21): prop.numbers has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/lottieraster/lottieraster.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"4684b02cfe052e21249d9416a3ce5eb08aacf08653d1878ac2cbba4a595e55b5"}},{"ruleId":"D1","level":"warning","message":{"text":"Conn.sendOutboundWithTerminalReserved (cyclomatic 21): Conn.sendOutboundWithTerminalReserved has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1779}}}],"partialFingerprints":{"codehealthFindingId/v1":"e653ae30e5e6b96220a301071f8e8434fcc31e467197c4ba2709bbe30c52d7da"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.Run (cyclomatic 21): Manager.Run has cyclomatic complexity 21 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 8 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcd97b9f8f02a8ca2775cf7e004bb772fb846b940c6eaf19371c3b8bdbc6be0b"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgMessageActionStarGift (cyclomatic 21): rpc.tgMessageActionStarGift has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1623}}}],"partialFingerprints":{"codehealthFindingId/v1":"73ab02402d8afac4c2f7ca04be09a9c07e2e8d6a62c2fa6bc8079ada10996908"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.BotAPISendEphemeral (cyclomatic 21): Router.BotAPISendEphemeral has cyclomatic complexity 21 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"c02e0ad9f823a4214c4bea79aba3bbbb308350b30e006ebf6ee4a6d1fb54d437"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSendInlineBotResult (cyclomatic 21): Router.onMessagesSendInlineBotResult has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a59f55cc9899b82bde3928fe0e6424137f03e5d5681fe607c929a18de13eab5"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onChannelsGetChannels (cyclomatic 21): Router.onChannelsGetChannels has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"d809bca6a89b9019815c97f53a12b3078fde58eaf7f210d026f17d01f4fc5e1a"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.editPrivateInlineBotMessage (cyclomatic 21): Router.editPrivateInlineBotMessage has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6f9eae3aa44e0776f041cf6d4f1b49ffc6a3e9e431f1732c60a31947edae67a"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.forwardSources (cyclomatic 21): Router.forwardSources has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":617}}}],"partialFingerprints":{"codehealthFindingId/v1":"7aacce4160acf2bbca9f6293529fdef60913db3107952000fdac13d5eef88c14"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetSearchCounters (cyclomatic 21): Router.onMessagesGetSearchCounters has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"a07d83438c72669863f77c37a411736f665d179e950f5532d1baa6ff79be8def"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSendQuickReplyMessages (cyclomatic 21): Router.onMessagesSendQuickReplyMessages has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_quick_replies.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"86c9c0d92d182ea7053c5b2f7a0601c924eb1bee0708d911a7afac3cbd7890a4"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.usersForMessageUpdatesWithPreloaded (cyclomatic 21): Router.usersForMessageUpdatesWithPreloaded has cyclomatic complexity 21 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: rpc.cloneEntityWithBounds (cyclomatic 26) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1045}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d09d6380f3ba0758e032d6d763d69168541d7e84534352363f0969562e68a0c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.editSelfParticipant (cyclomatic 21): Router.editSelfParticipant has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_edit.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f1076de34cadf3959e838554290352681baa844ca5a32ec9b9e2cbadd9c6aad"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.telegramLoginButtonFromMessage (cyclomatic 21): Router.telegramLoginButtonFromMessage has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e0e2ea5da0bfb7b6980f7b34f5dadf6a1775eedd67212b4f398ee834629be76"}},{"ruleId":"D1","level":"warning","message":{"text":"BotVerificationStore.ListCustomVerificationRequests (cyclomatic 21): BotVerificationStore.ListCustomVerificationRequests has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":705}}}],"partialFingerprints":{"codehealthFindingId/v1":"6975aabb280c3fc5f9e6cb8f6c62d2b18d10990f17314b3242653af69768fcaf"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelDialogs (cyclomatic 21): ChannelStore.GetChannelDialogs has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed2257cf4987e4ef4587ba2c12b2abe704a488156ab6b1df0385aed3e0ceeba8"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListCommonChannels (cyclomatic 21): ChannelStore.ListCommonChannels has cyclomatic complexity 21 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0e871e69971c781203528430019194c482f5ef7ecf6e6e5b2709c6b764a548f"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SearchPublicChannels (cyclomatic 21): ChannelStore.SearchPublicChannels has cyclomatic complexity 21 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0ce90f61a0608b78ba42d6253e69fbb302900621b150ab9fd912c4ba42c3e74"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.InviteToChannel (cyclomatic 21): ChannelStore.InviteToChannel has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6e61543774c4f04e6b1bc894cd90f4b64829e2e6f90397bfd9339fdd72e44c9"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetPaidMessagesPrice (cyclomatic 21): ChannelStore.SetPaidMessagesPrice has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_settings.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffeff0e5c8de873c7abb32d83ed36a7ef92e23a90f3f2a7ee1f78ed2ea441a75"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelMessageReactions (cyclomatic 21): ChannelStore.ListChannelMessageReactions has cyclomatic complexity 21 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"8043178c98b4313775d4457487181169050768b6a04b1984c0c6d57a5f7bc8fd"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ReadChannelReactions (cyclomatic 21): ChannelStore.ReadChannelReactions has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"55fe01ec20602c116d085d6e7b1c06d4baf73624af00e2a3b522aeffaf44c7f0"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListMessageReadParticipants (cyclomatic 21): ChannelStore.ListMessageReadParticipants has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"741782e909bf4301ac480e636bb28452c733b9d6da6606a2b842687e38827f2f"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.lockRawAuthKeyInIdentityOrder (cyclomatic 21): postgres.lockRawAuthKeyInIdentityOrder has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_identity_lock.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f8d580b7e202c468d062e1ad064063d3b4ba5a2a656b587ec5e838afd2cef5a"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.getModerationCase (cyclomatic 21): postgres.getModerationCase has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1046}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ddff7ebc26c3a9419b8b481896a189f3289f8ff0ae4d6ac4ee2c5e9b4a71b2f"}},{"ruleId":"D1","level":"warning","message":{"text":"AccountRatingStore.SaveAccountRating (cyclomatic 21): AccountRatingStore.SaveAccountRating has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_rating.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"54da8f2664d31bcc826f580278f75167ab59eb843dcdf00357e1f2aeaaffeaba"}},{"ruleId":"D1","level":"warning","message":{"text":"BotStore.DeleteBotAccount (cyclomatic 21): BotStore.DeleteBotAccount has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ca038eccfaeda4450967ddadadd2d77a61c1a15c15e3684cb0abd43912a75f5"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.HydrateChannelDialogSnapshot (cyclomatic 21): ChannelStore.HydrateChannelDialogSnapshot has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":953}}}],"partialFingerprints":{"codehealthFindingId/v1":"41a821e2a96ed53f5047023272adbfe3d9494730744de573605f732c2111b0a0"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SearchPublicPosts (cyclomatic 21): ChannelStore.SearchPublicPosts has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dcbf915b82e8e2e58ea635adf00c3df34fb50021224a38717f53b53064267fa"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ChannelPollFanoutViews (cyclomatic 21): ChannelStore.ChannelPollFanoutViews has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_polls.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"26fa3edae2b1747458bffa720fb57d6cc62348dfc2e0487e3d58fea60c3005a7"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.CreateForumTopic (cyclomatic 21): ChannelStore.CreateForumTopic has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd0bd77a3ecc6cf70af426aa49944a76f5fadb39cb9ce4b2e6338d456a34ce35"}},{"ruleId":"D1","level":"warning","message":{"text":"CollectibleUsernameStore.MintCollectibleUsername (cyclomatic 21): CollectibleUsernameStore.MintCollectibleUsername has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 5 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 196). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a4b61221829c5ed159991d06efcf13e219d9658405cdd3a00582c4552f7e225"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.DeleteSavedHistory (cyclomatic 21): MessageStore.DeleteSavedHistory has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eb06d484c8d4e2fa172f12d36cd9c2a59278bbbee221e5d699f04eb38c7745c"}},{"ruleId":"D1","level":"warning","message":{"text":"PremiumStore.UpsertPremiumPlan (cyclomatic 21): PremiumStore.UpsertPremiumPlan has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 6 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 92). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"574a3e0c5ba5c017daf362a51dce07663b54f3e807a0c19959f4f4c348cf80af"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.ListCraftStarGifts (cyclomatic 21): StarGiftLifecycleStore.ListCraftStarGifts has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"22a059efcecfbdfbff14396d34399fb05d370f79cccf54143c0a681f24092532"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.dispatchStarGiftAuctionAwards (cyclomatic 21): StarGiftLifecycleStore.dispatchStarGiftAuctionAwards has cyclomatic complexity 21 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":804}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ad2cbcd3554115d26ac648f9e92da1a781e084b7ec6defe5c5759dfb87370ce"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftUpgradeStore.loadUpgradeSourceReplay (cyclomatic 21): StarGiftUpgradeStore.loadUpgradeSourceReplay has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":1151}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9d78a201f2a32d8ccf1d5bd870851e2b0f172f6e2004c0cbb18d2a9a1351c95"}},{"ruleId":"D1","level":"warning","message":{"text":"UpdateEventStore.ListAfter (cyclomatic 21): UpdateEventStore.ListAfter has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e956945f92f64dd90ebb2ff7fd34379470e740b1d0ffb8771116b542b68558d"}},{"ruleId":"D1","level":"warning","message":{"text":"main.chatMediaFromJSON (cyclomatic 20): main.chatMediaFromJSON has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":689}}}],"partialFingerprints":{"codehealthFindingId/v1":"595b7196ef829e1f2a4825228c9ee9edaa48826535cf6f316cac2d8ab2631d6e"}},{"ruleId":"D1","level":"warning","message":{"text":"server.storageEnvValues (cyclomatic 20): server.storageEnvValues has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/serverstorage.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"652cd1f578182f97785b8ed68465b8a608fd06125bb4aefe6d3821b9af5099cd"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ResendConfirmPhoneCode (cyclomatic 20): Service.ResendConfirmPhoneCode has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"02e79104a51001e58a510d3b3de620d9545e39e5c67e302342aef0853cb6fc6d"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.IssueTmpPassword (cyclomatic 20): Service.IssueTmpPassword has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/tmp_password.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b4febf43ad0fd3293a2c47084b9b77c5b956ec1980ab31f6df8864aa7a954ea"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.resolveTone (cyclomatic 20): Service.resolveTone has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":574}}}],"partialFingerprints":{"codehealthFindingId/v1":"58dff55dab00b1ee50059f1fd7d298d0d54e23620d756c0d9d4d098b4138e991"}},{"ruleId":"D1","level":"warning","message":{"text":"dialogs.dialogListForPeer (cyclomatic 20): dialogs.dialogListForPeer has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a111c0ef44c2ec57f1af97e4c2e69a0750f5d7546eec25b31bf1f522f4f32ca"}},{"ruleId":"D1","level":"warning","message":{"text":"files.inspectMP4Layout (cyclomatic 20): files.inspectMP4Layout has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/mp4faststart.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"563c80fc473c12f9792a4889c4c9e47bb426e3edfd93ee158f9c27e0eeb25949"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CreateDocumentFromBytes (cyclomatic 20): Service.CreateDocumentFromBytes has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":642}}}],"partialFingerprints":{"codehealthFindingId/v1":"8108ee1a820d91814aff37177b708ea59f8537052842d6fdbc1f291a4de90283"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.GetFile (cyclomatic 20): Service.GetFile has cyclomatic complexity 20 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 7 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":498}}}],"partialFingerprints":{"codehealthFindingId/v1":"0544c6e8c2505b2faf7da5050e6a3ef9956a9aff23b89b6de3be4fb537547cbd"}},{"ruleId":"D1","level":"warning","message":{"text":"langpack.scanSeedCandidates (cyclomatic 20): langpack.scanSeedCandidates has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 6 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 129). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/seed.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"c526de31c14ef08f0cda2819f64172810842650e1505f91d1e0b5e9f6cd92fbd"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.deliverConnectedBusinessBotAutomation (cyclomatic 20): Service.deliverConnectedBusinessBotAutomation has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e48f604769d9e7117c7e01480f4ca102dec81f7879e8511590a806b7f0d7e4c"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ReportReaction (cyclomatic 20): Service.ReportReaction has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d2229d5d7df7a4aaf4335b7c0a8c87033e4506c79940073e208127f3ab959c3"}},{"ruleId":"D1","level":"warning","message":{"text":"telegramlogin.LoadSigningKeyRing (cyclomatic 20): telegramlogin.LoadSigningKeyRing has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/keyfiles.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"1183da02108ae8ce91fa00380a365ca8e64ab792380d3b7b77738550c0058779"}},{"ruleId":"D1","level":"warning","message":{"text":"userprojection.applyPrivacy (cyclomatic 20): userprojection.applyPrivacy has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":634}}}],"partialFingerprints":{"codehealthFindingId/v1":"10f6e76e8ee67de83df89ae3936820373251f2f4c07ed8eb47b96e067746e343"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.botAPIHTMLFrame (cyclomatic 20): botapi.botAPIHTMLFrame has cyclomatic complexity 20 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform \u2014 the same kind of value, with no behaviour of its own \u2014 a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c8be2a8d809c3466e3389e429ea993191d408dfcca44ae776936778c2951f1b"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.validateStoryInteractionOffset (cyclomatic 20): domain.validateStoryInteractionOffset has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/story.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"b88428764d3fc5ea3594b4ae29b552901e95070f28c51ccd35fe33dd2ad21e82"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.validateVerificationHost (cyclomatic 20): domain.validateVerificationHost has cyclomatic complexity 20 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/verification.go"},"region":{"startLine":465}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e9d4f383efb2e47d8736f2cc472e543b9b17da8a42ac843f6ac1f409a4346f6"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.validateClientAccountState (cyclomatic 20): loadharness.validateClientAccountState has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"1853ae4bfb1f44febd4fdeba8fa2d19885f529f544cfad901a74b78dd8051587"}},{"ruleId":"D1","level":"warning","message":{"text":"Dataset.Validate (cyclomatic 20): Dataset.Validate has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0519643c7b63ccce61830ee24d1e13e1f4ece46d3d3a6dc9fcfa4dabcc0f33c"}},{"ruleId":"D1","level":"warning","message":{"text":"Conn.enqueueEncodedDeliveryReserved (cyclomatic 20): Conn.enqueueEncodedDeliveryReserved has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1678}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbf729e064122f461e7b5a6a76de6aabfd5af5e0d5620f3d504ceba8b0908a7f"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.postProcessBotAPIRichHTML (cyclomatic 20): rpc.postProcessBotAPIRichHTML has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 1 of the 20 points is its own statement and the rest belongs to one function literal inside it that branches (line 144). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_message.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a2b6eb4e7e20a3d8b0b2e0cd80d6e77cf5ce2d1ea9c26d4f2607bbce0281a64"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.botAPIRequestedPeerProjectable (cyclomatic 20): rpc.botAPIRequestedPeerProjectable has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":576}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6b24ff8ccff634fd1fcffa8441f30865b9db2e87e70850cd82d374f93f24fa7"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgBotInlineResult (cyclomatic 20): rpc.tgBotInlineResult has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":1088}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa2cdfe1c84d02605fad7875e934e2b4f7ae300894710320665d7c0b213d0de4"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.contactNote (cyclomatic 20): rpc.contactNote has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"9bdb957939c7368946664564a1827d31f96751d649a203ad2776839cf85c4622"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.normalizeOrderedListForClients (cyclomatic 20): rpc.normalizeOrderedListForClients has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_rich_message.go"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0be53bd502f7500ea4a8d7a133e0b40ca22670223a7a46106d69e659cc361ba"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgUniqueStarGift (cyclomatic 20): rpc.tgUniqueStarGift has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_unique.go"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"1718f27568e0c6efe6cbf16bda1d83861bc4a2ea86be65a5070c0fab5887de31"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.fileLocationKey (cyclomatic 20): rpc.fileLocationKey has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: rpc.sniffImageType (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/upload.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"dde4f7e3c35f006b399c7c8a82e79e697755acd046b06f2b5e2f07dab154f7e9"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.safeExternalIP (cyclomatic 20): rpc.safeExternalIP has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/upload_webfile.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b5b17b27bc74ee7092fd8d1fb96a6cbfbbba2bdb9385a9593042a5f721a3e01"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onAccountGetNotifyExceptions (cyclomatic 20): Router.onAccountGetNotifyExceptions has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_notify.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"17bee8c076ea29bb3a7f489796546289d9a74dca7fdf074dbd4631db044597c3"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.BotAPISendRichMessage (cyclomatic 20): Router.BotAPISendRichMessage has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e91d65ce391c0da5c63e12d712ac699aa58f75f7bfe5a70e8d57a0bbc801656"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.botAPIQueuedUpdates (cyclomatic 20): Router.botAPIQueuedUpdates has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"da31633d2c93e0e9992bdc69140eb67ca7890c4254bcc9c32fae47d7f92ad106"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.nudgeBeyondCapChannelMessageAudience (cyclomatic 20): Router.nudgeBeyondCapChannelMessageAudience has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1270}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c37c5cbc791aa092a227575f147e516bdcd1111e37cd302ebbd7674e729ee4e"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.channelMessagesUpdatesWithPeerCacheAndUsernames (cyclomatic 20): Router.channelMessagesUpdatesWithPeerCacheAndUsernames has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_updates.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6f9addc895727815d8fb02967e8cff52cfb4bf3dc7e6836f7eee5b3abf1d141"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onContactsGetStatuses (cyclomatic 20): Router.onContactsGetStatuses has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"3984506c9aa741799997924a9654ea49f495a3626dfe83feafe4f6b7cfc2bb64"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.dialogFolderFromTG (cyclomatic 20): Router.dialogFolderFromTG has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":1047}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dc00b89a136e263c12369ad13f965c09d0f97924b7f98aade9526a486866fa1"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.forumTopicsResponse (cyclomatic 20): Router.forumTopicsResponse has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb60956a0fb54992f2d4d41d82702479b3b0cdd7f4f58e4a06045b650328f844"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.channelMessagesReactionsUpdates (cyclomatic 20): Router.channelMessagesReactionsUpdates has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_send.go"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2011d3c97bee288e7ef1809e5628e88f235061f1abc321959db881c706a8e8f"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesReportReadMetrics (cyclomatic 20): Router.onMessagesReportReadMetrics has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reports.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce553c3017fafa68f7b08af741f5fb75232565f35ba0542002b66371e29507e0"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.webViewBotAppFromInput (cyclomatic 20): Router.webViewBotAppFromInput has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"5709001dccd2181eb8a8bd3838f6eab737a48a85d7bbdba8712b4c46f478d359"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.FreezeNegotiatedSessionLayerAt (cyclomatic 20): Router.FreezeNegotiatedSessionLayerAt has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1179}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1ad505008b46274bbcd7ce07aff26046c00f707106134d9c816ecf598aabb7e"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onStoriesSendReaction (cyclomatic 20): Router.onStoriesSendReaction has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: rpc.messageEntityClassNil (cyclomatic 27) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2762}}}],"partialFingerprints":{"codehealthFindingId/v1":"e831a069595d5847f240ec8fbb40bae4023e84bf285bd92373c2bc28258cb33e"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.enrichPreparedUpdateEvents (cyclomatic 20): Router.enrichPreparedUpdateEvents has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ca16a671d7c0337447b0314db67a83228583c16030a96acf413f49c1bc22a1b"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onUsersGetFullUser (cyclomatic 20): Router.onUsersGetFullUser has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a42316e02c84cf3e0c5bf30c3d2cedf27ef51be210dfd068cc8b926875f4cc7"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.fillUserFullPhotos (cyclomatic 20): Router.fillUserFullPhotos has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":812}}}],"partialFingerprints":{"codehealthFindingId/v1":"c13d2287ea89c89c04fc86d10802450085bfedae60622dadec8d1de173897884"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SearchPublicPosts (cyclomatic 20): ChannelStore.SearchPublicPosts has cyclomatic complexity 20 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4ad928c2afee15e1c31e260678a2fe8b190ae9c83c351639c8e49aa2242bd71"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.channelForViewerLocked (cyclomatic 20): ChannelStore.channelForViewerLocked has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6089653934e228767f742adf98ec802ea1f524d9da37a95db85862afdcac845"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListAdminLog (cyclomatic 20): ChannelStore.ListAdminLog has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"f41d58208b00f674695add2849a85dffbec2eec48c36d6b4d281e9371be7fc09"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListExportedInvites (cyclomatic 20): ChannelStore.ListExportedInvites has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"455d1307424776d4b68fe48b30ffe5290c853a4ffaada5ebb5dcc6c86dc54c75"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.HideAllChatJoinRequests (cyclomatic 20): ChannelStore.HideAllChatJoinRequests has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":666}}}],"partialFingerprints":{"codehealthFindingId/v1":"5af88b0e22f32f8f5c2943fdb231de1dd817ef6884b8bf41101fb4ab97d243d0"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteChannelMessages (cyclomatic 20): ChannelStore.DeleteChannelMessages has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":8}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbf6a1ffc2643ce763752af053a86e366b04b443aad841d6f60bfde6686f86ee"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelMessagePublicForwards (cyclomatic 20): ChannelStore.ListChannelMessagePublicForwards has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1085c9bcc60e825c98921e4b62456734a45a14b0458fda30c75cb2379a1ef8c"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.ListCommunityPeerLinkRequests (cyclomatic 20): CommunityStore.ListCommunityPeerLinkRequests has cyclomatic complexity 20 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a1a3016f86b27e71b6c73119c5c95440019c94e8c5ca0e3a9d1efd562be67dc"}},{"ruleId":"D1","level":"warning","message":{"text":"BotVerificationStore.DecideCustomVerificationRequest (cyclomatic 20): BotVerificationStore.DecideCustomVerificationRequest has cyclomatic complexity 20 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 10 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":855}}}],"partialFingerprints":{"codehealthFindingId/v1":"5440b89a9dbdff3277252fd9a5fb0e546dda1a0c73af244a80c4ff114eed35bb"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EnsurePermanentInvite (cyclomatic 20): ChannelStore.EnsurePermanentInvite has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"16043546432020386a10e811edb968924b7faafea5846bac27d2192ae7ff4824"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.getChannelMessagesForMember (cyclomatic 20): ChannelStore.getChannelMessagesForMember has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"91d1ffe94db8c65e70bfa359f1461e260e49655392ebe172b1cb7ea455c37845"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.readChannelHistoryOnce (cyclomatic 20): ChannelStore.readChannelHistoryOnce has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":916}}}],"partialFingerprints":{"codehealthFindingId/v1":"04afe6d29f2dc781cf99d89cef84a18cd68738e9cf387fe82b825d6e13204283"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelMessageViews (cyclomatic 20): ChannelStore.GetChannelMessageViews has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_views.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"1afc9bf65aed1d10d73504c47770f313ecf2e1ed831be5c9fde3c9f5f3209061"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListMonoforumDialogs (cyclomatic 20): ChannelStore.ListMonoforumDialogs has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_monoforum.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9f9f04978f5176fe2093e6bdc13e1c06138dccb4122693e0ba37d1cdc0808d3"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteChannelParticipantReaction (cyclomatic 20): ChannelStore.DeleteChannelParticipantReaction has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a11cc56bbfc08340d51fc65a4e67f6e99cf66a0130fbb2fd125bf8280293394"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelMessagePublicForwards (cyclomatic 20): ChannelStore.ListChannelMessagePublicForwards has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"702580c82fbfcef9818f97e6b4da726dfc468c901211d4b8abb401f58d36b3e2"}},{"ruleId":"D1","level":"warning","message":{"text":"EphemeralReportStore.ListUnmigratedEphemeralReports (cyclomatic 20): EphemeralReportStore.ListUnmigratedEphemeralReports has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ephemeral_report.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"e71f47c960fac9b5fdb2ff3f58e3e05f85b4636f21f1858cff3bdd5833df5d4e"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.enrichPrivateMessageReactions (cyclomatic 20): MessageStore.enrichPrivateMessageReactions has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"be2ba03374fb698ad211d6def8338a137ba6ea4db6f1c2eb002fb5b016786985"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.ImportLegacyEphemeralReport (cyclomatic 20): ModerationReportStore.ImportLegacyEphemeralReport has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"82e716e21cf0583c9d6158b6d62bdc0b3fbf3f490985c6b973d53453836a34bc"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.IssueModerationAppealLink (cyclomatic 20): ModerationReportStore.IssueModerationAppealLink has cyclomatic complexity 20 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"90e83e8f415843185e48953be01303a2b1d5aa7db549c9739ee263094502d276"}},{"ruleId":"D1","level":"warning","message":{"text":"PremiumStore.RefundPremiumPayment (cyclomatic 20): PremiumStore.RefundPremiumPayment has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 7 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 633). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"acb23dfa23a419d826b8d1f88c49b510067b532c92b6bb52e95d9b2baf57b217"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.creditPeerLifecycleAmount (cyclomatic 20): StarGiftLifecycleStore.creditPeerLifecycleAmount has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1387}}}],"partialFingerprints":{"codehealthFindingId/v1":"b57d4c62c65421df67241d0b2900dc8c1bfaef696232c00669a301294db12365"}},{"ruleId":"D1","level":"warning","message":{"text":"StoryStore.populateStoryViewState (cyclomatic 20): StoryStore.populateStoryViewState has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1906}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ee22b8c3cf4964092f3396d2b08c10fc935894d6909a0c64fb1bd0aeddb25c9"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.DeletePrivateHistory (cyclomatic 19): Service.DeletePrivateHistory has cyclomatic complexity 19 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3233}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fd56284d701acf936d77af063499f3856719a83735ff7ac2b7f9231b2e5bd92"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.composeStreamWithProviders (cyclomatic 19): Service.composeStreamWithProviders has cyclomatic complexity 19 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9f67cd9db3ab340a79eee49542cd437df1e84f69fe4cfdce1656487ae426e88"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.handleStickers (cyclomatic 19): Service.handleStickers has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"4aab47351c3996f51eb4c8a74fe895014a4abbd0096628d169107e0c96637e1c"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.dialogDraftsReadModel (cyclomatic 19): Service.dialogDraftsReadModel has cyclomatic complexity 19 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 7 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/draft_read_model_cache.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"afc5cd1d34fabec0e8bbefaa0c482d5b9626bdb34a7f561fe80fc5321fc3ef49"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.attachArchiveSummary (cyclomatic 19): Service.attachArchiveSummary has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":605}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0e9d29097f2558a5db48aa58b435c1706c41817afe721ff821281624f3d4899"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ChainBalance (cyclomatic 19): Service.ChainBalance has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/balance.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"64ebdbf11cd00c4d960aee4b5aa845a0f1896afcdacfb30a463210540439c482"}},{"ruleId":"D1","level":"warning","message":{"text":"FFmpegGIFTranscoder.Transcode (cyclomatic 19): FFmpegGIFTranscoder.Transcode has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_transcoder.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"d54d89e48dd5f5ac4c735101e1bee0f5f31a6f7bc4319f1a2a9fee2bc29320d6"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.DeleteBlobBytesForMediaOlderThan (cyclomatic 19): Service.DeleteBlobBytesForMediaOlderThan has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4aeccd377daa82cf0e086bc3cdf8a2f9dde4f3268c92e3474b22eb6cdb969ab"}},{"ruleId":"D1","level":"warning","message":{"text":"telegramlogin.importSigningKey (cyclomatic 19): telegramlogin.importSigningKey has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/jose.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3b2821cb2d59121e9682093b673ccb483169f7f3f6db0bf1b256884f5628585"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.messageEntitiesFromAPI (cyclomatic 19): botapi.messageEntitiesFromAPI has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: botapi.apiEntityType (cyclomatic 22) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"417f3d24a729af68d8bbbedd1d3bce2528f3b92c5297d6fa50c5a9eb4dbe3eb0"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.apiPoll (cyclomatic 19): botapi.apiPoll has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: botapi.botAPIEntityType (cyclomatic 21) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":760}}}],"partialFingerprints":{"codehealthFindingId/v1":"6aa8b5e4620b548d3468e62aa46c460adf9a0b74dd544f47e63ef65a929cbb0f"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.ValidateEphemeralContent (cyclomatic 19): domain.ValidateEphemeralContent has cyclomatic complexity 19 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators. This is NOT this file\u0027s highest cyclomatic complexity: domain.validEphemeralMedia (cyclomatic 39) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/ephemeral.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5dc2ae324ac441be319589181cec8528f043bbf52895f2f12141c3539ddb78d"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.detectBotCommandMessageEntities (cyclomatic 19): domain.detectBotCommandMessageEntities has cyclomatic complexity 19 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"180d221cab04ad8df83d411e88c7dc02aa5b368c513e2144d2bcc4055289b6c4"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.prepareDownloadFixture (cyclomatic 19): loadharness.prepareDownloadFixture has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 6 of the 19 points are its own statements and the rest belongs to one function literal inside it that branches (line 607). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":592}}}],"partialFingerprints":{"codehealthFindingId/v1":"b012df42610bb641fce7794703024f4c246185655232dc8176d7552e5a0919db"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.seedGroup (cyclomatic 19): loadharness.seedGroup has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"53aeb119c1b75ee5fa9e9b3941fddd4fbb2af2b1537372b994a6f020731dc0cd"}},{"ruleId":"D1","level":"warning","message":{"text":"Sender.send (cyclomatic 19): Sender.send has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/otpdelivery/smtp/sender.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa06fd0959cc0fd03515057e205a8847a960fda299578ed0a070fa209112b9ee"}},{"ruleId":"D1","level":"warning","message":{"text":"Sender.Deliver (cyclomatic 19): Sender.Deliver has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/otpdelivery/webhook/sender.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d5a9ca2adf080d1d59e0a01d2d6a733e68526a667f5443915a90b06eacba9fb"}},{"ruleId":"D1","level":"warning","message":{"text":"Manager.ReadEnvGroups (cyclomatic 19): Manager.ReadEnvGroups has cyclomatic complexity 19 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/procctl.go"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6ff9631a883addb2647b4ee4f7b6cc898ce2f1d33ab400692e1a742f10ab7df"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgMessageReplyHeader (cyclomatic 19): rpc.tgMessageReplyHeader has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: rpc.tgMessageEntities (cyclomatic 26) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"54754efa64c2ca0ed9f3b59bc24bcda78678271ecac27d260934e070fea71db8"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgStoryMediaAreas (cyclomatic 19): rpc.tgStoryMediaAreas has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_stories.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"7748022d1e3d3620addcde76c67d1727dceb6efa857853cd93867e0c02754f56"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.collectChannelMessagePeerRefs (cyclomatic 19): rpc.collectChannelMessagePeerRefs has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":416}}}],"partialFingerprints":{"codehealthFindingId/v1":"525103aae795115caaae563f34e6828d95c406500c76850e8802683ed9264182"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.registerAccount (cyclomatic 19): Router.registerAccount has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to 10 function literals inside it that branch (lines 281, 298, 311, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9b6919a306f6d32c814cfe0b356b314c3985d42ccae486c5f6cd15571152e66"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetBotCallbackAnswer (cyclomatic 19): Router.onMessagesGetBotCallbackAnswer has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"82fbb7de8f56d15cbb2566931e7d7d14d978a0803ea5ec51e81262e67cf2ef90"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetChatInviteImporters (cyclomatic 19): Router.onMessagesGetChatInviteImporters has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"10cefbdcc66784256aed3c8b66b4bff587f0bba79f1aa8ca5712e22ab5b525d8"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.applyLayerRPCWrapperEffects (cyclomatic 19): Router.applyLayerRPCWrapperEffects has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_dispatch.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec786642c162d388d3626f53e96332f23db0d9f8aff91712fa6f89080fc29a08"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.checkedMessageReadPeer (cyclomatic 19): Router.checkedMessageReadPeer has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read_filter.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"93c4a0cfada2d67cc34afdc73725281524a4fcea380377b3717ff9f774aa5544"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPhoneInviteConferenceCallParticipant (cyclomatic 19): Router.onPhoneInviteConferenceCallParticipant has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_conference.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"0507f008ce0570b241b1bcb3baac1d54092f81097dd01c2b65e82ff021f1895c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPhotosGetUserPhotos (cyclomatic 19): Router.onPhotosGetUserPhotos has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":426}}}],"partialFingerprints":{"codehealthFindingId/v1":"58fff732c709d8fec1e1be3bb669f7f9a4e7a3879f30aa57b7795c2c7bd230b4"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.withBotProfileFlagsForUsers (cyclomatic 19): Router.withBotProfileFlagsForUsers has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":819}}}],"partialFingerprints":{"codehealthFindingId/v1":"807d844bb400aab8e37ec2a49ad419181b6e577b23ec6cb86742302a2094bdd5"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.accountChannelDifferenceNudges (cyclomatic 19): Router.accountChannelDifferenceNudges has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/updates.go"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"304ebac9bac08abb8b98978af302311a309bca7cdb87d1352234e63ccbb675bd"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onUsersGetSavedMusicByID (cyclomatic 19): Router.onUsersGetSavedMusicByID has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":733}}}],"partialFingerprints":{"codehealthFindingId/v1":"f96bf3ce1e3702cbaea8ee80ded960438e0b0fcce28a7dbb92ab96cac0d65cb9"}},{"ruleId":"D1","level":"warning","message":{"text":"storySparseProjectionCache.activePeers (cyclomatic 19): storySparseProjectionCache.activePeers has cyclomatic complexity 19 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_sparse_projection_cache.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"774d3f96b85c96000774d596d21ce9c74ffcbfe478e7320b7cd74fc7838d3621"}},{"ruleId":"D1","level":"warning","message":{"text":"endpoint.run (cyclomatic 19): endpoint.run has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"8eca5032a83096044e83aeb1cc2e0ae876748dd50c114d5a16ff915dd5c5d57b"}},{"ruleId":"D1","level":"warning","message":{"text":"memory.upsertMemoryDialog (cyclomatic 19): memory.upsertMemoryDialog has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":681}}}],"partialFingerprints":{"codehealthFindingId/v1":"5874709e84661e580cc5b6f7df5fc9950b26ba6370b358a2d8a2eb5d46aad3bc"}},{"ruleId":"D1","level":"warning","message":{"text":"memory.dialogMatchesFolder (cyclomatic 19): memory.dialogMatchesFolder has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f2c90bd472f2e49915b5f89823f6538972f6d59c624d275dfd05b2a06864add"}},{"ruleId":"D1","level":"warning","message":{"text":"BotStore.UpsertBotApp (cyclomatic 19): BotStore.UpsertBotApp has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c8d639cf1439a53f61d6f6a74eff6c829e9668ab9453768c2747b4169af635a"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetParticipants (cyclomatic 19): ChannelStore.GetParticipants has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a7811357d3b6cf507b45fd7477b141938e4e8f002662526b1227a3eb2511f9c"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.deleteChannelMessagesLocked (cyclomatic 19): ChannelStore.deleteChannelMessagesLocked has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"d23578a6087e5ce5d7078cb7d62dbedfd567a28a0154c16f20aed529c1043fe9"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.advanceChannelReadOutboxLocked (cyclomatic 19): ChannelStore.advanceChannelReadOutboxLocked has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7defe6967be137d7ff78688223a4866dfe518d924f000e2bebf97fd159ea61e"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelMessageStats (cyclomatic 19): ChannelStore.GetChannelMessageStats has cyclomatic complexity 19 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"14e267b8b6d983a00e56e3f036559780535583593a07bf11854ace7fe878ea5e"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SearchChannelMedia (cyclomatic 19): ChannelStore.SearchChannelMedia has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"151a5cc514d2e0e06796dfd04784f166aaec6d80de2decaf5926c631f61564cb"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.MigrateAndStatus (cyclomatic 19): postgres.MigrateAndStatus has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/postgres.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"85257a6c825298bfe73b1d3e7bad606454355540820075b91e2ba55cbd13c11d"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListAdminLog (cyclomatic 19): ChannelStore.ListAdminLog has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_admin_log.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"e89eeece03f8a18631afdacee22321ead5d35b4593a055844b6547e48303830c"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.UpdatePinnedMessage (cyclomatic 19): ChannelStore.UpdatePinnedMessage has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"baa30958f3b1c2682f98722b4aefd92410c456a9b3a8af44cdf400168206c88d"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.channelHistoryClearAnchor (cyclomatic 19): ChannelStore.channelHistoryClearAnchor has cyclomatic complexity 19 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb16c17b7c75b1b3da3f393a28cc18d79a3e62d431d42c7f415d64c747decf6a"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetChannelPhoto (cyclomatic 19): ChannelStore.SetChannelPhoto has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"a92a137588d27adf09820d1547920849080b46c81fe198d44a7eb86dd61ea6d9"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetForum (cyclomatic 19): ChannelStore.SetForum has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"5dbaa7fa6e9ed5785a1e3520b0753f9614b921b677df5dcd104edcdba27314f9"}},{"ruleId":"D1","level":"warning","message":{"text":"DialogStore.listByUser (cyclomatic 19): DialogStore.listByUser has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b3c31f6ef6511dd40594e94644c4ad541f1ea4d24fae6fd62f27f0ddf669d0d"}},{"ruleId":"D1","level":"warning","message":{"text":"GroupCallStore.JoinGroupCall (cyclomatic 19): GroupCallStore.JoinGroupCall has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":273}}}],"partialFingerprints":{"codehealthFindingId/v1":"a81d75593e3eb9b45406ae67b30ae7b3ecd8341860f37db7ddff6e2b4ea0cd39"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.ListSavedDialogs (cyclomatic 19): MessageStore.ListSavedDialogs has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc172dc63418c58acc13f1698643d8504db47d94b810974aad1885452f81d8db"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.CreateModerationAppeal (cyclomatic 19): ModerationReportStore.CreateModerationAppeal has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"bae29318ef92eb5b964b477e6235076c89e95c6c12ba5f96f28b19d3f513b249"}},{"ruleId":"D1","level":"warning","message":{"text":"PhoneChangeStore.ChangePhone (cyclomatic 19): PhoneChangeStore.ChangePhone has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/phone_change.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f75fe3e1e1c135f6555f95f6d0b83d9147056ea740b75fbdc90cf6c8d6d48da"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftStore.UpdateCollection (cyclomatic 19): StarGiftStore.UpdateCollection has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to one function literal inside it that branches (line 664). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":662}}}],"partialFingerprints":{"codehealthFindingId/v1":"01a0c223f4a9ced81dc399121cb7a76c41de980ad95072cc44d05e378fb5111c"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.publicUserPeer (cyclomatic 19): handler.publicUserPeer has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":746}}}],"partialFingerprints":{"codehealthFindingId/v1":"247b6277c4aae196ae7b0487e5eab1d3cd534a4301813b86170340abc024a30f"}},{"ruleId":"D1","level":"warning","message":{"text":"main.rotateSigning (cyclomatic 18): main.rotateSigning has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telegramloginkeygen/main.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"8937a0bcdc839352d9dfda2854d3ee38aa73122041bf09d81bc3b29cad6a1bb7"}},{"ruleId":"D1","level":"warning","message":{"text":"main.evidenceToChat (cyclomatic 18): main.evidenceToChat has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/report_evidence.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7ef33cb33033db263c1f16994ab8043d9b59a95456e61f1592f7b8dd97911c4"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.RevokeSessions (cyclomatic 18): Service.RevokeSessions has cyclomatic complexity 18 (threshold 15). Of this number, 9 points are the body\u0027s own statements and 9 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3120}}}],"partialFingerprints":{"codehealthFindingId/v1":"b10f3f27a618deccf65b178e864d9f7f985d301738215bd2506a93bac84dfe1e"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ConfirmPhone (cyclomatic 18): Service.ConfirmPhone has cyclomatic complexity 18 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cbebc8cdb4e67c1b1ae2d457aa29ef7c04c4bb2838d92838ca7fd24682efb9a"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SendChangePhoneCode (cyclomatic 18): Service.SendChangePhoneCode has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/phone_change.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"927b0a5fd259300aef725aea41f2d2dcb30a868ccf900272b693b934c3f14aa1"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SignInBot (cyclomatic 18): Service.SignInBot has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1437}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7934f14840d07ab609e584b84c11a272de9d6edf3044f9c8f9c6de79fe0e8d3"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.handleBotFatherCommand (cyclomatic 18): Service.handleBotFatherCommand has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f9c36555e411ea8453bbf74924cddce4cc52d2e01e45f802a8a7a405c4b291a"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.chatBotPromptText (cyclomatic 18): Service.chatBotPromptText has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/chatbot.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"d04970e2101bdc5a5cf47d31f26225ca63b8f82e89fd3396d6835ebd1646f1fd"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.getDialogs (cyclomatic 18): Service.getDialogs has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab3fb1f146dbd2165a4fc6d11c3cedba38f2aface02021257841210816596560"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.TogglePinned (cyclomatic 18): Service.TogglePinned has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":950}}}],"partialFingerprints":{"codehealthFindingId/v1":"be7b171ea61db313e96edc5a6b2addeb7eb79a99107350648883ba7ee1fc1316"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.refreshConfirmationsAndCredit (cyclomatic 18): Service.refreshConfirmationsAndCredit has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/watcher.go"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffa45155bbe03cb400db54df5d6c0c028707526719c61d5ccf2f6086e7c391a2"}},{"ruleId":"D1","level":"warning","message":{"text":"files.faststartMP4 (cyclomatic 18): files.faststartMP4 has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/mp4faststart.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"5874578063a35e6a7ce054cf3eb97e2978600a5009e64ab0eada96344091bbc3"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SeedAppearance (cyclomatic 18): Service.SeedAppearance has cyclomatic complexity 18 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d9128b5b895051897dd885840aee77a350f9e32e61a31de92cab1b207ff51fc"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.maybeFaststartVideoBlob (cyclomatic 18): Service.maybeFaststartVideoBlob has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3aa0395a7715722fb73b3dcf448b9665ab22e3bd2532f759a55ed3fd9133230"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.seedStickerSets (cyclomatic 18): Service.seedStickerSets has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: files.seedThumbMimeType (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"c360355399c207e62c512b920da94d914113cac8128a97c2539e3ededc00d63f"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.WarmCaches (cyclomatic 18): Service.WarmCaches has cyclomatic complexity 18 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/warm.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"e90b935bf611af3d7cbd5ad545d63a19a7361ad954545297594b73fa5b99b7b4"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.RequestEncryption (cyclomatic 18): Service.RequestEncryption has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/secretchat/service.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8e5b1bc23d9e370706ebb80e5da0308dfe6432f43a9f79db5b5a22eb769ab61"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ExchangeInAppTokenAndIssue (cyclomatic 18): Service.ExchangeInAppTokenAndIssue has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":1106}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bf81ff4c79169380b776dd492186986e01b8f6088ea908fe6c5bc78effbb846"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.targetState (cyclomatic 18): Service.targetState has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":976}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf8c6a5579213231014603fb04915b05dc66b9f197d01810f02c44659015ec07"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.markupButtonFromAPI (cyclomatic 18): botapi.markupButtonFromAPI has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: botapi.apiEntityType (cyclomatic 22) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"024fe63f82e423bf558de21f7650cea56dcc9c73fc99471f570fb01a2fbc7414"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.apiEphemeralMessageDepth (cyclomatic 18): botapi.apiEphemeralMessageDepth has cyclomatic complexity 18 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators. This is NOT this file\u0027s highest cyclomatic complexity: botapi.botAPIEntityType (cyclomatic 21) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"9851b403199ee965727e2a30f1bec875e6c1d362288d35a3d24dcd4192d232fb"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.sendMessage (cyclomatic 18): handler.sendMessage has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: handler.handle (cyclomatic 41) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"d85b7c2e598c192b9b5e2badee1713cbd14a64a2498b0498a0cd5dd55ec02557"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.sendRichMessage (cyclomatic 18): handler.sendRichMessage has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: handler.handle (cyclomatic 41) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e9e9a515f1f85610fb74bcaa66f2616173f938e917d63152a8f313122827135"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.ValidateExternalReplyQuote (cyclomatic 18): domain.ValidateExternalReplyQuote has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_reply_external.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad22677b22bfe1b0f22a530d5c67faa7e9deda1cf9686cb0b620f310fa4371ed"}},{"ruleId":"D1","level":"warning","message":{"text":"Conn.writeFrame (cyclomatic 18): Conn.writeFrame has cyclomatic complexity 18 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":2866}}}],"partialFingerprints":{"codehealthFindingId/v1":"83128f72445b5efc6b4e6f9b0f43a6f91a97d47d537a765d6f4bda2b4c54bc70"}},{"ruleId":"D1","level":"warning","message":{"text":"rpcExecutionLedger.acquire (cyclomatic 18): rpcExecutionLedger.acquire has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_flight.go"},"region":{"startLine":538}}}],"partialFingerprints":{"codehealthFindingId/v1":"da91989799d77db833643b108a2e2e2727bc1a46a59e89d96bae8decc75d723b"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgChannelUpdate (cyclomatic 18): rpc.tgChannelUpdate has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"0789a57b968fb8f24d3b36f2ca85b03bcba862cc536d6834c756ac9997a1758b"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.augmentAutoEntities (cyclomatic 18): rpc.augmentAutoEntities has cyclomatic complexity 18 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/message_entities_autodetect.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"60c7e06eafbecd483edba07144169f53dacba8776a2f11400b7da40470648b84"}},{"ruleId":"D1","level":"warning","message":{"text":"viewerPeerCache.channelsForIDs (cyclomatic 18): viewerPeerCache.channelsForIDs has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/peer_projection_cache.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"07dd50132922f8b5cfbec04f8db319aedf7c93ee74f80911aa3588bb0d3aae47"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.BotAPIEditEphemeral (cyclomatic 18): Router.BotAPIEditEphemeral has cyclomatic complexity 18 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":404}}}],"partialFingerprints":{"codehealthFindingId/v1":"f95689027f5b7cfdca20fb909dd17f4ec247ad80bb1eaa94e577b79d15c407c8"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.fanoutCloseFriendStoryChanges (cyclomatic 18): Router.fanoutCloseFriendStoryChanges has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"78afd7d47d8a701bfc3a1c87cee50b19ac77d07535c8a43b8e67eca6eb35c8ea"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.prepareRPCDispatchContext (cyclomatic 18): Router.prepareRPCDispatchContext has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/dispatch_context.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"e859385b0de2b2a2889e464c7fd2b378b65459862a0640f0d4839bc36cddc84d"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.loadLiveLocationMessage (cyclomatic 18): Router.loadLiveLocationMessage has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"775c202df6609d7c2debf3bb28760043ed2f6277ddc93f3c8e2bc2bea37980ee"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.loadMessagePoll (cyclomatic 18): Router.loadMessagePoll has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls_updates.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"35aa4b062c66853f74f6ceab8b8a995764a8c5a72b866ee30ace8c150224df06"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.privateMessagesReactionsUpdates (cyclomatic 18): Router.privateMessagesReactionsUpdates has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_send.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"c94f1b1042ea36c5a5a07e335137bfa23cfaf0b97703ed33b56fec211af45806"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.loadTodoMessage (cyclomatic 18): Router.loadTodoMessage has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_todos.go"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"672d2e80856072d865817d76468d988598fa72f6951db8e90dd0322e760e8834"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onStoriesEditStory (cyclomatic 18): Router.onStoriesEditStory has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: rpc.messageEntityClassNil (cyclomatic 27) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1366}}}],"partialFingerprints":{"codehealthFindingId/v1":"68824dacf494630a2811853b8e8e22c6926fca61d5d6966641aa10eac5d32944"}},{"ruleId":"D1","level":"warning","message":{"text":"BotVerificationStore.ListCustomVerifications (cyclomatic 18): BotVerificationStore.ListCustomVerifications has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b76c9d6a80d0474a90af7a7802fcca0199bb863a58b417d138eb5078cc7d79c"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EnsurePermanentInvite (cyclomatic 18): ChannelStore.EnsurePermanentInvite has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"16a6a9324d6e8bfe61a5baddb2aa97c33c0f005e74a4ea9302b30ff0c689783b"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelUnreadMentions (cyclomatic 18): ChannelStore.ListChannelUnreadMentions has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c2c41d6c1ef81738eeafc0b149bf5d8f9ddf00bad427d10e7b809e647abaa44"}},{"ruleId":"D1","level":"warning","message":{"text":"LoginCodeDeliveryStore.DeliverLoginCodeMessage (cyclomatic 18): LoginCodeDeliveryStore.DeliverLoginCodeMessage has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code_delivery.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"a166cdfcbf31e9ae0af85da774c0b7981d3bc05b05ca19cd13cf7093808573ff"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.SearchPrivateMedia (cyclomatic 18): MessageStore.SearchPrivateMedia has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"f77b4d48875599fdac1dea8e0048f5a72edbc72cdf76163ccc760773f63ae38e"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.SubmitModerationAppealByLink (cyclomatic 18): ModerationReportStore.SubmitModerationAppealByLink has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":690}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3560a40a87e54847e9565262ebdc000f269e09eff1d629b10fa03bc0137f32f"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.ConsumeTelegramLoginDirectToken (cyclomatic 18): TelegramLoginStore.ConsumeTelegramLoginDirectToken has cyclomatic complexity 18 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"25afa637aa09ef81198df2e258f725252ae2b04ce7035036605a31b519860288"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.revokeByUserExceptTx (cyclomatic 18): postgres.revokeByUserExceptTx has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authorization.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"dff043919c8c4effb049dd2ee42ca54f05c1f1ebaa88692217ced78404da6d75"}},{"ruleId":"D1","level":"warning","message":{"text":"AccountLifecycleStore.ScheduleAccountDeletion (cyclomatic 18): AccountLifecycleStore.ScheduleAccountDeletion has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_lifecycle.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"34b83acffc16a2299116c862c30f9ad9c8252f6a09a653b92635ba8118dc04c7"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.listActiveChannelIDPages (cyclomatic 18): ChannelStore.listActiveChannelIDPages has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e29ae9748a9db7f90f3bdff0329e044b62fe49085be037dd0b2163a1267696a"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ApplyPremiumBoost (cyclomatic 18): ChannelStore.ApplyPremiumBoost has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"45e66810e1a791a53aa7db7e645a7dfc50ea4d67402745930950bb05f5281ada"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListAllBuiltinChannelDialogSnapshot (cyclomatic 18): ChannelStore.ListAllBuiltinChannelDialogSnapshot has cyclomatic complexity 18 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"28e817c0eb460b5146a8fe7d7b2cfa8370831f55378f1c9c37ce0bdff0759802"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ExportInvite (cyclomatic 18): ChannelStore.ExportInvite has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"b22265d5d1d1c665825931e36246c4f05b3614d4bd1dc44af2915ea228a4c3d6"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.getLinkedDiscussionGuest (cyclomatic 18): ChannelStore.getLinkedDiscussionGuest has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_helpers.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca82f1290363c0061036c6bf7563aac581a0dee62489fb2c916437c63ea86108"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.UnpinAllChannelMessages (cyclomatic 18): ChannelStore.UnpinAllChannelMessages has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"5185543a64e79a8fa5a1f882ff5d475bdd007823a81fa579de0f76ff6a0034d3"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListMessageReadParticipants (cyclomatic 18): ChannelStore.ListMessageReadParticipants has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":413}}}],"partialFingerprints":{"codehealthFindingId/v1":"2abed8d5c17a083045a604c1fcebfe7666be4fd969490bbedd4d81b0ffb89422"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetChannelWallpaper (cyclomatic 18): ChannelStore.SetChannelWallpaper has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"196bb0b16f48f4b0e9efe96afcba22dec1a28baef3e62ffe1441a0dbd2eecac1"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.SetChannelScamFake (cyclomatic 18): ChannelStore.SetChannelScamFake has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":294}}}],"partialFingerprints":{"codehealthFindingId/v1":"35f422725d303b684d96aa26987ad7a34a0d99e191d4138d7cee2139dd2ce75f"}},{"ruleId":"D1","level":"warning","message":{"text":"CollectibleUsernameStore.TransferCollectibleUsername (cyclomatic 18): CollectibleUsernameStore.TransferCollectibleUsername has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 5 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 308). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":294}}}],"partialFingerprints":{"codehealthFindingId/v1":"24c6f63fb732614e27d06a0e731f64f348ab16e9bad4adfe1e1a11d8a3cb69c5"}},{"ruleId":"D1","level":"warning","message":{"text":"plainPrivateSendBatchActor.run (cyclomatic 18): plainPrivateSendBatchActor.run has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 8 of the 18 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 171, 163). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_actor.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3f588d1a90fb7cd4ecc92c8de7d28b828d272728228a8b1510dcc4600bf63b8"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.DeleteMessages (cyclomatic 18): MessageStore.DeleteMessages has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"90932da0db2f4b5c9b02c4e65b3d9009598794a30f45bad38d715d6651e423a7"}},{"ruleId":"D1","level":"warning","message":{"text":"PremiumStore.PurchasePremium (cyclomatic 18): PremiumStore.PurchasePremium has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"0727d230f3ca2153a09b0484ec5adf64d5f31d0a7f6aaf65504e5e09bf9c079e"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.IssueStarGiftPurchaseForm (cyclomatic 18): StarGiftLifecycleStore.IssueStarGiftPurchaseForm has cyclomatic complexity 18 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"dca31997b9c3835df61eaf94f3d369f22c270587d64e4946427ec142443d6952"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftUpgradeStore.loadUpgradeReplay (cyclomatic 18): StarGiftUpgradeStore.loadUpgradeReplay has cyclomatic complexity 18 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":1115}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d2f59717daeba3a799da8e07c3c5bdaf60af6bdf58ec8537e93c9799827044b"}},{"ruleId":"D1","level":"warning","message":{"text":"VerificationStore.DecideVerificationApplication (cyclomatic 18): VerificationStore.DecideVerificationApplication has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 8 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 502). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":479}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8f7cdbbc345a0f95177bf525265397f7691ea9ba77958fe9fab731b524f4980"}},{"ruleId":"D1","level":"warning","message":{"text":"echo.parse_args (cyclomatic 18): echo.parse_args has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"c21d1442e2f8908bd0be205dae89f2c1a5a9cc7a9df8c01c7c4a812817585eee"}},{"ruleId":"D1","level":"warning","message":{"text":"main.fetchSet (cyclomatic 17): main.fetchSet has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerfetch/main.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9da73b5933d99843261da82e1b98d9692084597cbbe6392df84f5cae71be02c"}},{"ruleId":"D1","level":"warning","message":{"text":"readStore.PeerProfileContent (cyclomatic 17): readStore.PeerProfileContent has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"e588f8e1f141c1549adb6e7bf7df95d1f16cfdf94499f81532ec75fcde4d7412"}},{"ruleId":"D1","level":"warning","message":{"text":"main.analyzeHandlers (cyclomatic 17): main.analyzeHandlers has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 8 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 261). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b0ef042e92c1430c17397e67cd30fdd06c97852d13f1666cd6b109cc313d042"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SetChannelAvatar (cyclomatic 17): Service.SetChannelAvatar has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 8 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 2288). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2277}}}],"partialFingerprints":{"codehealthFindingId/v1":"43ad75607de2e5e8abc7254dde8cdd6e67c47c0a63c69bced0109eb4156935e1"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.RevokeVerification (cyclomatic 17): Service.RevokeVerification has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 8 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 272). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/verification.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ae599d9e72b6d3d7ce814d18a7178728e031b9c05e54103f49e3d91a8351bbc"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.controls (cyclomatic 17): Service.controls has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1376}}}],"partialFingerprints":{"codehealthFindingId/v1":"d352512b285a90d97f830096bd7c22fced501474834a18ad518e4988ce682e72"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SearchJoinedMessages (cyclomatic 17): Service.SearchJoinedMessages has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1996}}}],"partialFingerprints":{"codehealthFindingId/v1":"3751bf147446a4be466f253173816aebbc73090d12534723e02c2dcbe60099e9"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.JoinInvite (cyclomatic 17): Service.JoinInvite has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecf16472ba18c82496c19bae9b45051c24d5fd7bb6b62f02d8cf1fb1614aeec2"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.AddContact (cyclomatic 17): Service.AddContact has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"a02d02f3e345483d336e6b9ba9012e64b4673e5bdaf1a111b7d6f36507b3bdef"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.AcceptContact (cyclomatic 17): Service.AcceptContact has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fb85317fa2b540d148a861fe9d682733d2cf9ee6d5f23f06485bd3feada781c"}},{"ruleId":"D1","level":"warning","message":{"text":"files.stickerSetShortNameBase (cyclomatic 17): files.stickerSetShortNameBase has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"890499b741404240956c0aa4cd7f6ea0f3c05d968bd04a80d3b9e62f3e5fbd0c"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.EnsureDefaultEmojiStatusSet (cyclomatic 17): Service.EnsureDefaultEmojiStatusSet has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/default_statuses.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"c95384ec689e00e2a559f3f3dfb34b9e39159ca0dbe73dde6e632e8ac917bf5a"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.importStickerSetDir (cyclomatic 17): Service.importStickerSetDir has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: files.seedThumbMimeType (cyclomatic 23) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"47d13b4a537239bb9a3289d4ab967eb259dc00b034a81731d02ec148458621e3"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.loadBaseUsersByIDs (cyclomatic 17): Service.loadBaseUsersByIDs has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":851}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b2411e7cab35345ec16418a779fb2191bdf9e503520d7ae1c799ca99495dfd0"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftCatalogWrite.PreserveCatalogInventory (cyclomatic 17): StarGiftCatalogWrite.PreserveCatalogInventory has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1010}}}],"partialFingerprints":{"codehealthFindingId/v1":"49178b08d408d49c6486eb0be596475e4c0a96ec1d254224203e31184505caa9"}},{"ruleId":"D1","level":"warning","message":{"text":"Manifest.Validate (cyclomatic 17): Manifest.Validate has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/types.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"44697dc659e75a9c7cf642ba8334f5a05a3e00a32a7820f3646604a7e64c85ad"}},{"ruleId":"D1","level":"warning","message":{"text":"Conn.sendBestEffort (cyclomatic 17): Conn.sendBestEffort has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1565}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed16008301dac6142b3031c6d24dfb92de22a2e24e0595ef2c3b50e94ab68a6c"}},{"ruleId":"D1","level":"warning","message":{"text":"encodedOutboundMessage.materializeRPCResultBodyInto (cyclomatic 17): encodedOutboundMessage.materializeRPCResultBodyInto has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b149c36ba5057ac5aa81ca498c9c639238bad1e155f82b102673e22d7a395bf"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.decodeMessageContainerViews (cyclomatic 17): Server.decodeMessageContainerViews has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"d401ee7463c64464f4f8cf384c83960d1125534ca0f151297efa115b3f5c785e"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.parseBotAPIRichHTML (cyclomatic 17): rpc.parseBotAPIRichHTML has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 5 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 60). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_message.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d6a880625bba270300aa4051b8c0f6d7b9a27c3e69985feae25be6d4ff4df8f"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.domainChannelReactionPolicy (cyclomatic 17): rpc.domainChannelReactionPolicy has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_read_reactions.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"62f5649d8bff8362f791b56a81d312073ae2678fff6fbb9222473bbdab863d4a"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.validChannelManagementUsername (cyclomatic 17): rpc.validChannelManagementUsername has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"74144da6a4844704b6fd0ae9fc4837d16ebd25d7c9b738c942ce06d13587206f"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.domainRequestPeerFilter (cyclomatic 17): rpc.domainRequestPeerFilter has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"477b8894202620e0df6da6de80732a6887a2bc953bbef4d8f6183aaea05b8b9e"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.tgChannelDifference (cyclomatic 17): rpc.tgChannelDifference has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6f8706a8e15bfae678a6da247fd72a82e1e3f4ed548c5aa2801aa5c1747070e"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.ephemeralReplyFromInput (cyclomatic 17): rpc.ephemeralReplyFromInput has cyclomatic complexity 17 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c8b4e8e3414ddab99b3f93eb4bc7bdaf72a3ec46bdb5de5849fac10fbf25fee"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.extractMentionUsernames (cyclomatic 17): rpc.extractMentionUsernames has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: rpc.cloneEntityWithBounds (cyclomatic 26) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":828}}}],"partialFingerprints":{"codehealthFindingId/v1":"2455e5888bb60fa4593202f87c2a1b953fea23203b24e20e33b837d7e6e6d148"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.domainWallpaperSettings (cyclomatic 17): rpc.domainWallpaperSettings has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/wallpaper.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"b36126e96ebeca84a361d7fdf0953a2c38c9f4694d333c94833f8573d8c8748a"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.rawURLByteSpans (cyclomatic 17): rpc.rawURLByteSpans has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/webpage_url_extract.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b8e4fabd46b60352ed128ff533e9a50feb7e1177d6b1730d90c1b0cf88cde64"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.bareDomainHostValid (cyclomatic 17): rpc.bareDomainHostValid has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/webpage_url_extract.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7e9ebbb1cbd7f3edb3dd7a999331a25e9e56096abc3893dc96ba30e695d0048"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.domainPrivacyRulesFromInput (cyclomatic 17): Router.domainPrivacyRulesFromInput has cyclomatic complexity 17 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case\u0027s concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases \u2014 they stay explicit and reviewable."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1187}}}],"partialFingerprints":{"codehealthFindingId/v1":"859b46304f5e5906b937c27161bd58f1193018337d6b63780249c2a41b024baa"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.connectedBusinessBotPeerSettings (cyclomatic 17): Router.connectedBusinessBotPeerSettings has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"564ae1c62fc41379012efe4459daddc3d43f3227dd43802663a0e8dd5d3f5f1f"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.BotAPISendMedia (cyclomatic 17): Router.BotAPISendMedia has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":294}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c22d94dc8baa8ad1e66ecb5bb23b058090386331b03d5780fc9ccdfcabf7265"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.botAPIMedia (cyclomatic 17): Router.botAPIMedia has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":721}}}],"partialFingerprints":{"codehealthFindingId/v1":"3dc90c19755385c6d0dcc9877a4f2f95631d0f30a18df1b649b4e9d01f8f5d2a"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.BotAPIEditRichMessage (cyclomatic 17): Router.BotAPIEditRichMessage has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":875}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a8e1b02d959de784d9702710d6ece5125f3073bc211346186a859506b4b1db6"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.runChannelFanoutJob (cyclomatic 17): Router.runChannelFanoutJob has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":877}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fc7e29d5656fcac7a385bb304ae4c7065b09a002a4f66d474ab25c3c2e51b7f"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSetChatTheme (cyclomatic 17): Router.onMessagesSetChatTheme has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fc6f6059ef0fd36fba79b9ddd47f2c6c2d4a1fde8c3c97b323e6418e48dfb48"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onChannelsEditAdmin (cyclomatic 17): Router.onChannelsEditAdmin has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"58ccf6518bc3851a862af789a093c362d498d7678b241273646234b19e197338"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onContactsDeleteContacts (cyclomatic 17): Router.onContactsDeleteContacts has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":792}}}],"partialFingerprints":{"codehealthFindingId/v1":"a87bae0baf231e144175ae32d788a7e76c623c54bc8a6615cd57e847a2a347c3"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onEphemeralGetCallbackAnswer (cyclomatic 17): Router.onEphemeralGetCallbackAnswer has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd7f80b6bce2fa5fa17abb1513ded8b90b4e76024cfa4d2616f9046fc85d3103"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.ResolveInheritedAuthKeyLayer (cyclomatic 17): Router.ResolveInheritedAuthKeyLayer has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_inheritance.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"02b8c4540d8e3e3edce41ea042f9b46c814b9afe6240ed3c91507e24e02cf6b1"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesSetTyping (cyclomatic 17): Router.onMessagesSetTyping has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_helpers.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"a902c5920ebfd02302b1535a5c98e026dfecceb5784a17b533a6086e26220870"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.validateTelemetryMessageIDs (cyclomatic 17): Router.validateTelemetryMessageIDs has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reports.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"7eeacde5c29a96922dde3153f8a5e9e982319d26a38136c666265aba2aacdfdb"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetSavedDialogs (cyclomatic 17): Router.onMessagesGetSavedDialogs has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_saved_dialogs.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6e602de4676c3840e4cc8b2f0b2afd08f6182dd31804aa74a0e9d496f2005a0"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesToggleSuggestedPostApproval (cyclomatic 17): Router.onMessagesToggleSuggestedPostApproval has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_suggested_post.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6c693ac7de53bd083bc95af48d327ba1af24ae8628c9ca615a3216609fc82bc"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesToggleTodoCompleted (cyclomatic 17): Router.onMessagesToggleTodoCompleted has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 6 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 151). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_todos.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"01b1f2c0b061e36e356b628802a65d29d21f7c4da42ad86596ee2674815e78b4"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.mutateTodoMedia (cyclomatic 17): Router.mutateTodoMedia has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_todos.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c92dc612ecbedc9943e398723af100bcee60bad306e2932a938b4415235d74e"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesRequestAppWebView (cyclomatic 17): Router.onMessagesRequestAppWebView has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"27a11866edd4f3ac6e88c254516173aea0ca2d00adefc37f8c172c718a595501"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPaymentsUpdateStarGiftPrice (cyclomatic 17): Router.onPaymentsUpdateStarGiftPrice has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":565}}}],"partialFingerprints":{"codehealthFindingId/v1":"a57a643fedf8fcb3a6cff307443ec4c7c26c701bc4e07ce74b37c6f5ccb5773d"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPaymentsConvertStarGift (cyclomatic 17): Router.onPaymentsConvertStarGift has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1249}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3022d12c72f62bf45f5a8b4d5bd6d673b060df5725ef46d3d6481dc80da7afa"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPhoneRequestCall (cyclomatic 17): Router.onPhoneRequestCall has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_calls.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"44fbbf19672d30e12b093210d9ad89b7dc263e3da4f51c3d482b59456f4153c7"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onStatsGetStoryPublicForwards (cyclomatic 17): Router.onStatsGetStoryPublicForwards has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"c160a78704a91aadf1ad8df7ef4bf0513031590da458d68a3d1cb0bbda571b8b"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.telegramLoginRequestResult (cyclomatic 17): Router.telegramLoginRequestResult has cyclomatic complexity 17 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"79afb9c0e4a73912bf684f9a4d04ede9e8da7decfea6fd15b269dedad980baaa"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.domainWelcomeEditFields (cyclomatic 17): Router.domainWelcomeEditFields has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/welcome_messages.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"48a03f143ab718932f6bb5221b55b01f6144c87a320022f8936a5fba952dd798"}},{"ruleId":"D1","level":"warning","message":{"text":"CodeStore.VerifyLogin (cyclomatic 17): CodeStore.VerifyLogin has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"eab145428551b356dd71839019987e66e74e529391d46fb95c8e4bfaf9238945"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelMessages (cyclomatic 17): ChannelStore.GetChannelMessages has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ff9d1b10bbcb9738b7c854ae49bfb26ed5e2c427e6616c4b31e40594e7fdb64"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListChannelUnreadReactions (cyclomatic 17): ChannelStore.ListChannelUnreadReactions has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"61b96b48e9725d2562e9cdd909483b16e7d15e830edf7f871b3f50e5bf110480"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.channelMessageReactionsLocked (cyclomatic 17): ChannelStore.channelMessageReactionsLocked has cyclomatic complexity 17 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":769}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8ddfbf6fca17104c921ca2b2f0217517b8bf6b4b33d3157997f505993a9e150"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteForumTopicHistory (cyclomatic 17): ChannelStore.DeleteForumTopicHistory has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1301769fb81d3442a9544b0c0de889a53ab39b8316bb15cb8a8464014f920ee"}},{"ruleId":"D1","level":"warning","message":{"text":"ContactStore.ContactProjectionForViewers (cyclomatic 17): ContactStore.ContactProjectionForViewers has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"9553ee37458e8ad5b289d0ac02623e6448e5cf78fc5ad114639f636256350f60"}},{"ruleId":"D1","level":"warning","message":{"text":"GroupCallStore.JoinGroupCall (cyclomatic 17): GroupCallStore.JoinGroupCall has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"b83f54e9899194abe03460324bb16a4b8b1d88302da0caa46c383a8b290fc137"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.getModerationReport (cyclomatic 17): postgres.getModerationReport has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fef41e0d92cd0977eb10c98fd39a94e3bd70470faa623363f328a9ab783bdf6"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.canonicalizeStoredPhoneIdentitiesInTableTx (cyclomatic 17): postgres.canonicalizeStoredPhoneIdentitiesInTableTx has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/phone_identity_migration.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"89ef4d157be4c148c1a57ad8b074467afceed953f74b361c0cea004383690e98"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.validateStarGiftPurchaseForm (cyclomatic 17): postgres.validateStarGiftPurchaseForm has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cc049a2cabfa7373512cde8053d544f68a8e08a8fdccbf41a8d3587678c6e24"}},{"ruleId":"D1","level":"warning","message":{"text":"BotVerificationStore.GrantCustomVerification (cyclomatic 17): BotVerificationStore.GrantCustomVerification has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 8 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 553). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"094c02f1652a62ee4b439a871a69b310e6e305cf94be930c85f9adb9db997f89"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListDirtyActiveChannelsForUser (cyclomatic 17): ChannelStore.ListDirtyActiveChannelsForUser has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":368}}}],"partialFingerprints":{"codehealthFindingId/v1":"f60f9315170a56df10718420d3c03b9796ce4f24af2eaae4644432ab5345b427"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.HideChatJoinRequest (cyclomatic 17): ChannelStore.HideChatJoinRequest has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join_requests.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"07b78999e4e09a724eaeb45e203c3e773e0c0bd1a3cdf100c38723e560d293d8"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.DeleteChannelParticipantHistory (cyclomatic 17): ChannelStore.DeleteChannelParticipantHistory has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"141f52a0c578e24ff4987eaf12506d3039fe0d05fe330e2abcd41efede924b1d"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListStoryMessageForwards (cyclomatic 17): ChannelStore.ListStoryMessageForwards has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":583}}}],"partialFingerprints":{"codehealthFindingId/v1":"217aff08465d09ba30a57a9a2ed1cab215995944c46bc167151e609df23aa5b7"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.GetChannelMessageReactions (cyclomatic 17): ChannelStore.GetChannelMessageReactions has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4c7db39bfc4c46b868d97afa60c2d7ac6c6cb2d1a56b6bbd3299d8bb607a41c"}},{"ruleId":"D1","level":"warning","message":{"text":"DialogStore.ListByPeers (cyclomatic 17): DialogStore.ListByPeers has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"742a01cc665ca86fc50533852e1d6698eaf81db402c528224288f876e8d58ff0"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.GetMessageReactions (cyclomatic 17): MessageStore.GetMessageReactions has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb03e005d70703c2ea2d0e3d4ea2e162f840c24e8a5cc5bfa5c31ead7461f868"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.setSavedMessageTags (cyclomatic 17): MessageStore.setSavedMessageTags has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_saved_reactions.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"10a20f6cba7d322112b7d2e64d19f8355e9b8dbb24a9a4c772cd22866a297f4c"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.CreateSponsoredModerationReport (cyclomatic 17): ModerationReportStore.CreateSponsoredModerationReport has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c1c56c424c744e229d5d6f43259c944a50020cf7028f45a84d249c328522b67"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.loadStarGiftAuction (cyclomatic 17): StarGiftLifecycleStore.loadStarGiftAuction has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":1139}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6f27b001b7f75e3914b67873d9aa53a8fda58cd477351aed227b761d7755106"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.loadCraftInputMessageReplays (cyclomatic 17): StarGiftLifecycleStore.loadCraftInputMessageReplays has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_projection.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"fba63438d700aee1b4107cccca50cd3790f86656fbd4fcc08292c04ced9969b7"}},{"ruleId":"D1","level":"warning","message":{"text":"StoryStore.CreateStory (cyclomatic 17): StoryStore.CreateStory has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"10b910ec6d171ac2ac0df9217b87b2a38c6584db66462f93ea26e5b53dfe4a2d"}},{"ruleId":"D1","level":"warning","message":{"text":"StoryStore.ListStoryViews (cyclomatic 17): StoryStore.ListStoryViews has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1188}}}],"partialFingerprints":{"codehealthFindingId/v1":"0447e8379f337018ffa28dfd0df0423c70776bde822e59a87259b10850b8e357"}},{"ruleId":"D1","level":"warning","message":{"text":"WelcomeMessageStore.CreateWelcomeMessage (cyclomatic 17): WelcomeMessageStore.CreateWelcomeMessage has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 5 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 47). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a7f79c818352a6830364274237e2303a05281e218cec338628e97a754312fc1"}},{"ruleId":"D1","level":"warning","message":{"text":"WelcomeMessageStore.ClaimWelcomeMessageDeliveries (cyclomatic 17): WelcomeMessageStore.ClaimWelcomeMessageDeliveries has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message_delivery.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"d78cc9ea9d87a1972e28825456bac178610fccd1a5f4d43f73a583a23d17f824"}},{"ruleId":"D1","level":"warning","message":{"text":"Catalog.validateApps (cyclomatic 17): Catalog.validateApps has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/updatecdn/catalog.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"967449f7379c89bc33f125a82924ecf77e9466fd83ee7d745e3fbe654f494fa7"}},{"ruleId":"D1","level":"warning","message":{"text":"main.runLoop (cyclomatic 16): main.runLoop has cyclomatic complexity 16 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botdemo/main.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a587ac3e9e4c77b1bad63df4e39bbec8a72367f5ab49c119d5076165a09b5f1"}},{"ruleId":"D1","level":"warning","message":{"text":"main.render (cyclomatic 16): main.render has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"812fb7b79050ad88e0242506e8f1f347f747a48db73beefbf47942a77d766a8e"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SetLoginEmail (cyclomatic 16): Service.SetLoginEmail has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 7 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 2144). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2133}}}],"partialFingerprints":{"codehealthFindingId/v1":"315f161ffb3e4e12c9285f8f45e24639addaedc16083fca6f94c1764633b1362"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.UpdatePasswordSettings (cyclomatic 16): Service.UpdatePasswordSettings has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8dc013b75633e429b58e84ab86b6b26db7a2621bea8ea365ec9bbc67cd69563"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.RecoverPassword (cyclomatic 16): Service.RecoverPassword has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":478}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fe50f8462881196d32ffae27089ec49791e9900df068f47423e49ccdfbbebdd"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.UpdateTone (cyclomatic 16): Service.UpdateTone has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad736dbf6ff9cce505b071d3ffd36012ddaab0dbcdb0bba423e0b97866b31c7c"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SendCode (cyclomatic 16): Service.SendCode has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0b8868166fed33cb41cae373fe3bf7ab5e9f4874b7a432573940b35775beaaf"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.bind (cyclomatic 16): Service.bind has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1625}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1be1506be210be857a4c366fffb688efb6d02d25b99a88bc6200b6596907f60"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.normalizeBotApp (cyclomatic 16): Service.normalizeBotApp has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/miniapp.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"347e983d0363b0ad2908b12b21bd32d46f3ef2a5ab693329e25ed8757f678823"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.CreateBot (cyclomatic 16): Service.CreateBot has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":628}}}],"partialFingerprints":{"codehealthFindingId/v1":"e843a60f31887ed5bffec1e70b78a14d4a9f439f4d3af11c0a19e8c25e9347ed"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.handleStickersCommand (cyclomatic 16): Service.handleStickersCommand has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"81726e4066f390e9b0ec1e959b1bdc1662c7238083f24434e81ad8ef9d45c841"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.handleVerify (cyclomatic 16): Service.handleVerify has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: bots.verifyPolicyText (cyclomatic 17) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifybot.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"91fabca3d27c7ba3437157c993810a942cacb28a893edaa0a9384ea8593f9b42"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SetCustomVerification (cyclomatic 16): Service.SetCustomVerification has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":511}}}],"partialFingerprints":{"codehealthFindingId/v1":"c85c7ef8d2b8860a5dc0cc1323747bc56ef48547433b848ad28e450c6c2a3c54"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.cachedPeerDialogsReadModel (cyclomatic 16): Service.cachedPeerDialogsReadModel has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"55c30ae7938ace5daacff8315673ef79f9339e8e07bd9753294193c8201f0c3a"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.PrivateDialogPeerIDs (cyclomatic 16): Service.PrivateDialogPeerIDs has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"81b2559e526b02f23771a41b3307386a6212e556c153e74c761e3bcb788bb2a5"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.hydrateDialogSnapshotPage (cyclomatic 16): Service.hydrateDialogSnapshotPage has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"5684cd49bd27ee2b6930b11fdd73a92e6d7fcb532bcea378caee767178c4df73"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.GetPeerDialogs (cyclomatic 16): Service.GetPeerDialogs has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":686}}}],"partialFingerprints":{"codehealthFindingId/v1":"90eade49ba5ae5ea675df700b12c1c2ee7e43762265b605cedbecd9b74321d2f"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.RefreshPrices (cyclomatic 16): Service.RefreshPrices has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/pricefeed.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecfb7c183b7c03ba236a396f8dbc2ef76ae385e9d1fd57f0f36bfa2268e847fe"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.DocumentAnimationJSON (cyclomatic 16): Service.DocumentAnimationJSON has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/emoji_animation.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"f40ed657153d3904a78b83eedaf0237e2ef35df2a650cebf39fdd8f7f506d26f"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.DeleteOrphanedOlderThan (cyclomatic 16): Service.DeleteOrphanedOlderThan has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"e20489cceefaf9a7f598bba3fb866b254d840eb05395e11e62e79460a1218227"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.cloneStickerSetDocument (cyclomatic 16): Service.cloneStickerSetDocument has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_material.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"764e09be0ede6cdfab679725caa91072d5eb66391602c25b3cb0e3521d00d9f3"}},{"ruleId":"D1","level":"warning","message":{"text":"FFmpegVideoThumbnailer.Extract (cyclomatic 16): FFmpegVideoThumbnailer.Extract has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/video_thumbnail.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"eba2614d487557d9eff4d30f4515abbc15d12ba892e883e168b1c107b78bac11"}},{"ruleId":"D1","level":"warning","message":{"text":"giftpack.Import (cyclomatic 16): giftpack.Import has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/giftpack/import.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"72bfe64590410524acc4e0aaff14b2d4a4e7337169a23e7a01db56c7df8fd2f8"}},{"ruleId":"D1","level":"warning","message":{"text":"langpack.packFromFilename (cyclomatic 16): langpack.packFromFilename has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/parser.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"784e223e064a22d2dd021467b3ab5e32343763daed4acef1904e94dc3cabba26"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.SetChatTheme (cyclomatic 16): Service.SetChatTheme has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"f37d13016b9b4ab773e7134cca58f968138e1b176f71ff36a09f3c18042ec720"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ReviewAppeal (cyclomatic 16): Service.ReviewAppeal has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/cases.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"897c3a346f4ece109b78374950c0a89adeb1385e3dd26529f2478367311a69a3"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.ReportProfilePhoto (cyclomatic 16): Service.ReportProfilePhoto has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c82a2fcda7c4ed0025bccf1bc84971ace4fc3b43486b8c63784ba842842e59d"}},{"ruleId":"D1","level":"warning","message":{"text":"BatchCache.UsersForView (cyclomatic 16): BatchCache.UsersForView has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/peerview/cache.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f1ecfa64533145f4a4b5301699b7d5e0700f6fce6710ccdc02423f26d2a75a4"}},{"ruleId":"D1","level":"warning","message":{"text":"telegramlogin.NewService (cyclomatic 16): telegramlogin.NewService has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"51647404389850742d11a3b10aed82d5e9e2d1b57b2fbd8c16dc90788fdf7e92"}},{"ruleId":"D1","level":"warning","message":{"text":"IDTokenIssuer.Issue (cyclomatic 16): IDTokenIssuer.Issue has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/jose.go"},"region":{"startLine":357}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4c1c57ebdb4647d9d21d8a3f52b5027cb62f0864344a866ae52b0c5bcbd568d"}},{"ruleId":"D1","level":"warning","message":{"text":"Service.GetDifference (cyclomatic 16): Service.GetDifference has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7e1b44f73556b7ce5e8ceb13a9c53b3175fee7d7172016b9053fc0d39ed1245"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.replyMarkupFromAPI (cyclomatic 16): botapi.replyMarkupFromAPI has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: botapi.apiEntityType (cyclomatic 22) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1870b952091c17d1db7c3305aee2af1061d6b2724998a19744a17a43782139f"}},{"ruleId":"D1","level":"warning","message":{"text":"botapi.replyKeyboardMarkupFromAPI (cyclomatic 16): botapi.replyKeyboardMarkupFromAPI has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: botapi.apiEntityType (cyclomatic 22) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8dd78aee4fe0d2bf00b75723ca911c88e21938e2a97a0a28e2ff946838866eb"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.editEphemeralMessage (cyclomatic 16): handler.editEphemeralMessage has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"5aaedf613f0840bd1566bbd889a8b7a2ab569ed6ae715e85d4365a965fbed3d3"}},{"ruleId":"D1","level":"warning","message":{"text":"handler.setUserEmojiStatus (cyclomatic 16): handler.setUserEmojiStatus has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This is NOT this file\u0027s highest cyclomatic complexity: handler.handle (cyclomatic 41) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1162}}}],"partialFingerprints":{"codehealthFindingId/v1":"b93efdca73a592c13699ac5d69b6d57dd4e903d348a8adee8f2d9fd1002ad5b0"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.classifyDocumentCategory (cyclomatic 16): domain.classifyDocumentCategory has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/media_category.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"afc74b7caa6e7ce34e6de10efa967fa4661486cef18cf33a3b2c6b4696543bcd"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.DetectAutomaticMessageEntities (cyclomatic 16): domain.DetectAutomaticMessageEntities has cyclomatic complexity 16 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 6 belong to 2 function literals inside it that branch. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"f15ff92233524f3768d6cf3b89376eaf7618fc9d0570182111e2415c8f75da14"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.cloneReplyData (cyclomatic 16): domain.cloneReplyData has cyclomatic complexity 16 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_reply_external.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"23d5e7f68027e514426e42d57a708e6a33992e685729cb4e44725beb68e48188"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.EvaluatePrivacy (cyclomatic 16): domain.EvaluatePrivacy has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/privacy_evaluate.go"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c5a66771f3d0c1e573341396b97fc77a467d77c32e3963c16ab5d12b59baafa"}},{"ruleId":"D1","level":"warning","message":{"text":"domain.validateStarGiftUpgradePreviewPool (cyclomatic 16): domain.validateStarGiftUpgradePreviewPool has cyclomatic complexity 16 (threshold 15). Of this number, 8 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1237}}}],"partialFingerprints":{"codehealthFindingId/v1":"461f077c52b9306aa95fa1c5574a514da8988120d8ed52e010889000731a6872"}},{"ruleId":"D1","level":"warning","message":{"text":"links.ValidateAppLinkBase (cyclomatic 16): links.ValidateAppLinkBase has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"02f5f4237ac4ab88a1de9e1916fb49950476329d4f040b569dae188b2f0e98bb"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.provisionOne (cyclomatic 16): loadharness.provisionOne has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 4 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 210). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/provision.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"db559f1ed797e648a3fff0807e82fbf50463fffce89d31cd97c86c229e834df9"}},{"ruleId":"D1","level":"warning","message":{"text":"loadharness.validateSeededRichDialogs (cyclomatic 16): loadharness.validateSeededRichDialogs has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/rich_state.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d4fd949aaa860b67035cdd2c4192183740676cb830480f13827d2a986b86d0e"}},{"ruleId":"D1","level":"warning","message":{"text":"DatasetConfig.validate (cyclomatic 16): DatasetConfig.validate has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8ac807b0aae31148920978497b55e82243ba5cd9145780a930ab7e7342fa9ca"}},{"ruleId":"D1","level":"warning","message":{"text":"loadWorker.supervise (cyclomatic 16): loadWorker.supervise has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: loadharness.classifyErrorReason (cyclomatic 19) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ffc910bec48da042f5967409248bb63635426c2f96aa850bba737afeea9d355"}},{"ruleId":"D1","level":"warning","message":{"text":"Conn.beginRPCReplayRestore (cyclomatic 16): Conn.beginRPCReplayRestore has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 7 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 882). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_rpc.go"},"region":{"startLine":861}}}],"partialFingerprints":{"codehealthFindingId/v1":"9541b9e5e9566379dc492cff11c5d2831cbb26442e58c2f158f2594e28b331b8"}},{"ruleId":"D1","level":"warning","message":{"text":"connStateOverlay.validateSeq (cyclomatic 16): connStateOverlay.validateSeq has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"997660c2ef97f6bb2065603a8feb0364137565b1c02ec7ec3c5af6c0960c150c"}},{"ruleId":"D1","level":"warning","message":{"text":"Server.refreshActivatedInheritedLayerProfile (cyclomatic 16): Server.refreshActivatedInheritedLayerProfile has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn_layer_profile.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"46196697b79dab8897f01467bca2a062e9bc8c7d2668b9daa0b543010dc321a5"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionManager.ExplicitLayerEvidenceForAuthKey (cyclomatic 16): SessionManager.ExplicitLayerEvidenceForAuthKey has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":516}}}],"partialFingerprints":{"codehealthFindingId/v1":"af0cf20bfb710e0781e7f882d2ea1c278812ff6b1fe36d2abb392491cb60ad4d"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionManager.CloseSessionsForBusinessAuthKey (cyclomatic 16): SessionManager.CloseSessionsForBusinessAuthKey has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":947}}}],"partialFingerprints":{"codehealthFindingId/v1":"bafad05dae033c0cfee39606826031539046e7e21ecc302879a69e2820805d66"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionManager.pushToBusinessAuthKeyBestEffort (cyclomatic 16): SessionManager.pushToBusinessAuthKeyBestEffort has cyclomatic complexity 16 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This shape REPEATS in the file: one other method here (SessionManager.pushToUserBestEffort) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1635}}}],"partialFingerprints":{"codehealthFindingId/v1":"0eeebe0b033e9439b4d7270e6b7d59f0bd0b34f50362172264b2474bce15e470"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionManager.pushToUserBestEffort (cyclomatic 16): SessionManager.pushToUserBestEffort has cyclomatic complexity 16 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages. This shape REPEATS in the file: one other method here (SessionManager.pushToBusinessAuthKeyBestEffort) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1801}}}],"partialFingerprints":{"codehealthFindingId/v1":"44dae5801cfec6316452d37487a279fd267fdcc855d00ce1d2ab705084082861"}},{"ruleId":"D1","level":"warning","message":{"text":"SessionManager.OnlineChannelIDsSnapshot (cyclomatic 16): SessionManager.OnlineChannelIDsSnapshot has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2392}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcbd2a07a73ef58bf0b34a94a8d0717c15887179145dce0600b437b58524e6e2"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.botAPIRichTable (cyclomatic 16): rpc.botAPIRichTable has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: rpc.botAPIRichPlainText (cyclomatic 20) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"d69de863ec89fae04461e80f05cd4efa91042ba9c72738e9886da296a6cdd8d9"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.botAPIQueuedUpdateEventFromMessages (cyclomatic 16): rpc.botAPIQueuedUpdateEventFromMessages has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"d947e508cf3a2bb07d7eca6d02699106b66e866205fccb2376cbcdbdb8684df9"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.validateChannelSearchPostsRequest (cyclomatic 16): rpc.validateChannelSearchPostsRequest has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cce9a246a358e0df6adf529edd532e485c013b31407883917164d43aa2f7e9f"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.domainSuggestedPost (cyclomatic 16): rpc.domainSuggestedPost has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_suggested_post.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"83f43724a95aa15d7e30e8aed9ab40dca0d496905e2d81c6a51e7719a6a84d89"}},{"ruleId":"D1","level":"warning","message":{"text":"rpc.collectMessagePeerRefs (cyclomatic 16): rpc.collectMessagePeerRefs has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"6dac2c1fa413c5f806000b82103b17972f6cf89a406e783a8319cfac557e1b03"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onAccountDeleteAccount (cyclomatic 16): Router.onAccountDeleteAccount has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbb82d3557ec8064fc6331d51429ebc181ea77f57ba31ecf431576afc4a596a4"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onAuthBindTempAuthKey (cyclomatic 16): Router.onAuthBindTempAuthKey has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4aaf62f509e757b84e3812605c8201f89b92282859df008fe5b721204598fe6"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.BotAPISendMessage (cyclomatic 16): Router.BotAPISendMessage has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"197e45a7d66c3c9768294bf7991eda3a50d10bc6ef6729017a2df9c6ae8414da"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesCreateChat (cyclomatic 16): Router.onMessagesCreateChat has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c3983818de19e89168d0de651f47a2187a9166a0faa5bc326d5e251c0349de9"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.fanoutStoryBlocklistChange (cyclomatic 16): Router.fanoutStoryBlocklistChange has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d97d71196284a61172fa3cf07ea078439b26bc92beb56f624578bb11a9b32db"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onContactsImportContacts (cyclomatic 16): Router.onContactsImportContacts has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b670948a9d26cd66f3c225bfe6fb9e316b332072515f23eeaec2d6dfc644aa0"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onContactsAddContact (cyclomatic 16): Router.onContactsAddContact has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":678}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9e89a7df5e3131eaa6c56d8b221e13b01067fab5a63e0079c8e49378a0d42ce"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesRequestEncryption (cyclomatic 16): Router.onMessagesRequestEncryption has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_chats.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"147cd301cabf8dfb6cc8565afdb37554283d76ef0b46a6dae1848525d20342d3"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onEphemeralReportMessage (cyclomatic 16): Router.onEphemeralReportMessage has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"97423430879a7b123465207562c52814d9f70fe90df10f6853c82aa831afbc65"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.checkFrozenChannelParticipants (cyclomatic 16): Router.checkFrozenChannelParticipants has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/frozen_gate.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f4e66bcc03cbb0468204284f0d9672e027435b6f905708754a2d7cd1180c0c1"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesToggleBotInAttachMenu (cyclomatic 16): Router.onMessagesToggleBotInAttachMenu has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_attach_menu.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa29c87b1ff4f093e81c869d99da6c833f8f451ef546fc465e00df3a053542f2"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetSavedHistory (cyclomatic 16): Router.onMessagesGetSavedHistory has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_compat.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"854f99f3da5bb64e83b77dc5a86341de75137b299251a4a36460c93048cf15fd"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesDeleteSavedHistory (cyclomatic 16): Router.onMessagesDeleteSavedHistory has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_compat.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdad342f386b70812f397aa220a03754576b07921ba8c5757eed80cd7f8026c9"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.dialogDraftFromSaveDraft (cyclomatic 16): Router.dialogDraftFromSaveDraft has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"b083c52a96158374ab3624a71c7734d4182c4981ce3c55e79b6322ffacdf6eb8"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.updatePrivatePinnedMessage (cyclomatic 16): Router.updatePrivatePinnedMessage has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_pin.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"c858966eb406d8856ee29daf044bc60bfa38e42aafae7bba140ce338ab8e7aa1"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesGetUnreadMentions (cyclomatic 16): Router.onMessagesGetUnreadMentions has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"2aaf242acc1eac68818fbeb8798681a6609fcc37d399c0af1379ff63903c5828"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onMessagesReport (cyclomatic 16): Router.onMessagesReport has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reports.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"30e5a8b0eadefedbc97dc506110cbde209ccbf433a25e6046f5c111761bc9a15"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.mentionedUserIDsFromMessage (cyclomatic 16): Router.mentionedUserIDsFromMessage has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: rpc.cloneEntityWithBounds (cyclomatic 26) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":770}}}],"partialFingerprints":{"codehealthFindingId/v1":"b224fa7741a12a6576737c3ea1b1476deab41b5f601863285d4aa8ee194c9e6d"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.stickerCollectionDocuments (cyclomatic 16): Router.stickerCollectionDocuments has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_stickers_personal.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"35b991299793dc6117c004b2388c6f30431c8757dbb9be80b9ff635f7e93b080"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPaymentsValidateRequestedInfo (cyclomatic 16): Router.onPaymentsValidateRequestedInfo has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":486}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1935a366b252b932d380cad311b832a58d4b1fafcf6293e8b7f0cc8e4cb0b5e"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onPhoneCheckGroupCall (cyclomatic 16): Router.onPhoneCheckGroupCall has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"1556112029f472f6e6e34f662993466bc1e1203749df4ffe8b5400b2ef607837"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.NotifyUserModerationFlagsChanged (cyclomatic 16): Router.NotifyUserModerationFlagsChanged has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/premium_sweeper.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdcdd5c3e26842634ed723e6b6253079bf61a74faf134a658860c8049018f2a9"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.presenceFanoutCandidates (cyclomatic 16): Router.presenceFanoutCandidates has cyclomatic complexity 16 (threshold 15). Of this number, 13 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":1091}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fae02316d0fbc6dda5da3c87db6ff8405a6a447124ffc0240e741d8db38f857"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.persistAuthKeyClientInfo (cyclomatic 16): Router.persistAuthKeyClientInfo has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1083}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7bbf47f2af295ff7fa4cf043af80f39ef7b77615814f41190101f4ca269690c"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.buildEmojiStickerIndex (cyclomatic 16): Router.buildEmojiStickerIndex has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers_emoji_index.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e28b66344d4c5ba8dd2016972f62a5969e8cfa5ce9548e2b12b76abc13da155"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onUploadGetWebFile (cyclomatic 16): Router.onUploadGetWebFile has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/upload_webfile.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8adb1b38186ec18354751cfc18a345933037c01b6fa27c805e01ae5d8835a59"}},{"ruleId":"D1","level":"warning","message":{"text":"Router.onUsersGetSavedMusic (cyclomatic 16): Router.onUsersGetSavedMusic has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":695}}}],"partialFingerprints":{"codehealthFindingId/v1":"5968d6a4a09556d811571380d9f0f99c912d4793c0de49aabeeb4d4828dd1ed4"}},{"ruleId":"D1","level":"warning","message":{"text":"sfu.buildMediaPlan (cyclomatic 16): sfu.buildMediaPlan has cyclomatic complexity 16 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"33c19321be6dad8041d81b8ce64b253d71628b8b4156f192bb0859e7c63a8b60"}},{"ruleId":"D1","level":"warning","message":{"text":"AuthKeyStore.AdvanceSessionLayer (cyclomatic 16): AuthKeyStore.AdvanceSessionLayer has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/authkey_session_layer.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d6a66b81cbd8c8c34f6e64b566eeb0beaf93ead655b60414bf331c815513a6d"}},{"ruleId":"D1","level":"warning","message":{"text":"CodeStore.VerifyScoped (cyclomatic 16): CodeStore.VerifyScoped has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b9fe8673a2eaae6be3776b93d98f4c173d4b7279159bde44ce964680fccfedf"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListLeftChannels (cyclomatic 16): ChannelStore.ListLeftChannels has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"268bf84d2480b3c791378bd00e3d17d90ccb5373065170c3f2a1e59494200d7e"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListInactiveChannels (cyclomatic 16): ChannelStore.ListInactiveChannels has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"77ba9644ea7d577eb8fb1d8c531d625d3e86b7db6c4e39c18d9503fec517daf2"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListActiveChannelIDsForUser (cyclomatic 16): ChannelStore.ListActiveChannelIDsForUser has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":281}}}],"partialFingerprints":{"codehealthFindingId/v1":"82ca3ac61025b95df4b78c805d21b11d5362abe12f8f95fab22780128781f449"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.linkedDiscussionGuestLocked (cyclomatic 16): ChannelStore.linkedDiscussionGuestLocked has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1052}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8c76200e7431d69664907339c0721861bee58df68e6443ed0cf98a176046dee"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ListMonoforumDialogs (cyclomatic 16): ChannelStore.ListMonoforumDialogs has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a7d9369c7c7d2797164e24fbf7efb564579704cd695c8de3d4480a3beffd5ce"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.pollChannelMessageTarget (cyclomatic 16): ChannelStore.pollChannelMessageTarget has cyclomatic complexity 16 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_polls.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"22dea078bb70db32a60af718dea3be70b1e35a90e348b1a3a850c6f1df811454"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ReadChannelMentions (cyclomatic 16): ChannelStore.ReadChannelMentions has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"42304d3cfe5dc0aa8282aab75ece20e44bad155dd4ffd339f8d6cf1355626df0"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.pruneChannelUpdateEventsLocked (cyclomatic 16): ChannelStore.pruneChannelUpdateEventsLocked has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top. This is NOT this file\u0027s highest cyclomatic complexity: memory.adminLogEventMatchesFilter (cyclomatic 21) is higher and carries no row of its own \u2014 it was excluded as a flat dispatcher (a long switch/match over independent cases: many branches, almost no nesting), which this dimension does not treat as a refactor obligation. It is named here so the ranking you see in this file is not mistaken for the whole of it; the excluded function is counted neither in this dimension\u0027s figures nor in its score."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffcf0479fd7dfbc33ba0dddd19babe1e37ad8c4c75f8332215b7bc692c9648a2"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.DecideAllCommunityPeerLinkRequests (cyclomatic 16): CommunityStore.DecideAllCommunityPeerLinkRequests has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":590}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d11b6c6cf62186c79c031d508b096b9c50f983a36689ef2c150ff9dbef907bb"}},{"ruleId":"D1","level":"warning","message":{"text":"EphemeralMessageStore.PruneExpiredEphemeralMessages (cyclomatic 16): EphemeralMessageStore.PruneExpiredEphemeralMessages has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ephemeral.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b0952f4c63ee8bf7787a3362d9a207be3974d30a35b889d15a0bd5c491df38f"}},{"ruleId":"D1","level":"warning","message":{"text":"MessageStore.UnpinAllPrivateMessages (cyclomatic 16): MessageStore.UnpinAllPrivateMessages has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"86b1db20fcb887fa1f4aedc785e910c5a67b5f48b01335bf7a409f3de5b9dd75"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.ListModerationCases (cyclomatic 16): ModerationReportStore.ListModerationCases has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"22589cc379f00b9c6d69aeb8b719343c1151135134a5bef24d4863d57986302d"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.DecideModerationCase (cyclomatic 16): ModerationReportStore.DecideModerationCase has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":437}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2a1a85f8baaf1a3974bd3cec4ae49c1b681d8650dfa4c446066fdfd13e70780"}},{"ruleId":"D1","level":"warning","message":{"text":"PollStore.ListPollVotes (cyclomatic 16): PollStore.ListPollVotes has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/poll.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca69045908d6016cc6537b7d72106ce2a6c397b3894f648a532a8eae76c67977"}},{"ruleId":"D1","level":"warning","message":{"text":"StarsStore.ListTransactions (cyclomatic 16): StarsStore.ListTransactions has cyclomatic complexity 16 (threshold 15). Of this number, 10 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/stars.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e32ed3f6abb0c5b196540f9bde10d473ec6f22f9a048b1e101be1620537dd42"}},{"ruleId":"D1","level":"warning","message":{"text":"StoryStore.ListPinnedStories (cyclomatic 16): StoryStore.ListPinnedStories has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":359}}}],"partialFingerprints":{"codehealthFindingId/v1":"aacb4b0478f1dc9869c05cac4ba930c6023d1f1dfcbe7c6fc4eb0ca190b83e83"}},{"ruleId":"D1","level":"warning","message":{"text":"StoryStore.ListStoriesArchive (cyclomatic 16): StoryStore.ListStoriesArchive has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b3f59d93ee3ec9fe9ee857cd5649570a2321b013cc1799578a555fa7b67914a"}},{"ruleId":"D1","level":"warning","message":{"text":"StoryStore.ListStoryViewerIDs (cyclomatic 16): StoryStore.ListStoryViewerIDs has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":839}}}],"partialFingerprints":{"codehealthFindingId/v1":"a909cf26be81c1fc51361199d406cef2a7b423bd5f88ddb94b6718b196b24b31"}},{"ruleId":"D1","level":"warning","message":{"text":"TelegramLoginStore.UpsertTelegramLoginNativeApp (cyclomatic 16): TelegramLoginStore.UpsertTelegramLoginNativeApp has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"b911f4b8aa7abb86386c3b278e5e3822ab2174305b7f035a5f6917cf7cdae900"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.validateCommunityPeerForLink (cyclomatic 16): postgres.validateCommunityPeerForLink has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd44f1019605d1b431367f5277e15087ad57cc08717eaf13ea7e1cfe259e2eb8"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.privateMessageReactionsFromRows (cyclomatic 16): postgres.privateMessageReactionsFromRows has cyclomatic complexity 16 (threshold 15). Of this number, 12 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c4c6827fe25e83f2b80cef07bb598985549c42e715732439f7b42ccfe78d9d7"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.selectPlainPrivateSendBatch (cyclomatic 16): postgres.selectPlainPrivateSendBatch has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_actor.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cbb993c560e960e26f430ed18af6084e044225bc02e6dec79f1de1d3456fab0"}},{"ruleId":"D1","level":"warning","message":{"text":"postgres.appendUserUpdateEvent (cyclomatic 16): postgres.appendUserUpdateEvent has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"cee42239c520d1582b77d888b4e92bf80458ca5c1699ab74ca61cf535861f106"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.getChannelForViewer (cyclomatic 16): ChannelStore.getChannelForViewer has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cc7ca871a01a48181683ab9f557d5aabc6b16f5e3da5fb0443cde42693a9df1"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.HideAllChatJoinRequests (cyclomatic 16): ChannelStore.HideAllChatJoinRequests has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_requests.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"e72527ea188a32dc1ef9978dc96e09a80cbcc6dce5c635c0d0f791f62632281f"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditChannelMemberRank (cyclomatic 16): ChannelStore.EditChannelMemberRank has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"42863bba605b259eea7c504346f84ba416fd5bb1938a2e2ffefde49859e28137"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ModerationDeleteChannelMessages (cyclomatic 16): ChannelStore.ModerationDeleteChannelMessages has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c2481c70dc753a8514d26bb94b06438ef543b2e64991c2ef7945940c435089b"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.EditChannelTitle (cyclomatic 16): ChannelStore.EditChannelTitle has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3cd71930f3ff28ff42cbb472276a3912c0788ad62abc007d10845b535c8e6e5"}},{"ruleId":"D1","level":"warning","message":{"text":"ChannelStore.ReorderPinnedForumTopics (cyclomatic 16): ChannelStore.ReorderPinnedForumTopics has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":341}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa5fc447987c6d78ed4f4f7383b40dd09a971483736c5e9c062b01c5cfeb4b39"}},{"ruleId":"D1","level":"warning","message":{"text":"CollectibleUsernameStore.RevokeCollectibleUsername (cyclomatic 16): CollectibleUsernameStore.RevokeCollectibleUsername has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 5 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 399). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b4987c5a9156a9038e6e1a0b2580314d88b4724c0b4a1ae9bb9336af134ec3d"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.DecideAllCommunityPeerLinkRequests (cyclomatic 16): CommunityStore.DecideAllCommunityPeerLinkRequests has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to one function literal inside it that branches (line 749). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"62d79d8c0acba435325acf0f5c5cf1009fef2e9bd33ef2e6f609f7b3da8db1bb"}},{"ruleId":"D1","level":"warning","message":{"text":"CommunityStore.ReorderCommunityPinned (cyclomatic 16): CommunityStore.ReorderCommunityPinned has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to one function literal inside it that branches (line 1310). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1309}}}],"partialFingerprints":{"codehealthFindingId/v1":"80a64f48c5b3278fa8cb7ebbdca25c3f9eafa4fa842b7a4cfafa08b2597a3d64"}},{"ruleId":"D1","level":"warning","message":{"text":"ContactStore.ContactProjectionForViewers (cyclomatic 16): ContactStore.ContactProjectionForViewers has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"e703ce9c397c2ce7ebc87a6d0f5ec5d856de6901f822d5deeab2ef84feae6a11"}},{"ruleId":"D1","level":"warning","message":{"text":"ModerationReportStore.CreateAntiSpamFalsePositiveReport (cyclomatic 16): ModerationReportStore.CreateAntiSpamFalsePositiveReport has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"81a73e1d2630fbcaceb85d94fb5b93a7ec708a8d9ab5b080b6d982530922f155"}},{"ruleId":"D1","level":"warning","message":{"text":"StarGiftLifecycleStore.ensureStarGiftAuction (cyclomatic 16): StarGiftLifecycleStore.ensureStarGiftAuction has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":1093}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe728f609e3d0a2edf4539be8ea028e33c9775ec9c89397bf99978c25fd32f3f"}},{"ruleId":"D1","level":"warning","message":{"text":"VerificationStore.RevokeVerification (cyclomatic 16): VerificationStore.RevokeVerification has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 7 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 603). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":584}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f005d67d0d736dc461048601891f5bacc5efdddc74553b451f7c3f170e3d381"}},{"ruleId":"D1","level":"warning","message":{"text":"storetest.contractConferenceEmptyDiscards (cyclomatic 16): storetest.contractConferenceEmptyDiscards has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/storetest/groupcall.go"},"region":{"startLine":481}}}],"partialFingerprints":{"codehealthFindingId/v1":"444bad2f80d44bf179b6997446611210ef57d138c9590c87056bb5bbee6afaca"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.inApp (cyclomatic 16): Handler.inApp has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"04aea3d29a94d7aca205158147e75e16bedd9067a2a68d5670f1ac3be1d96632"}},{"ruleId":"D1","level":"warning","message":{"text":"Handler.authorizationStatus (cyclomatic 16): Handler.authorizationStatus has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd249525ea42485db0d0b38f28b3e6ccd30167410218a65607784a47eb8b0cf9"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.prepareInboundLayerRPCBatch (cognitive 239): Server.prepareInboundLayerRPCBatch has cognitive complexity 239 (threshold 15). Drivers by points: if/else 70 (193 pts), loops 17 (27 pts), boolean chains 13, match/switch 2 (6 pts) (nesting depth added 137). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc77b8185f0a16e10bd56318c29c6083f566d9a368acebe683285beb2c4e2350"}},{"ruleId":"D2","level":"warning","message":{"text":"ReadModelChangeListener.handlePayload (cognitive 226): ReadModelChangeListener.handlePayload has cognitive complexity 226 (threshold 15). Drivers by points: if/else 76 (193 pts), boolean chains 29, match/switch 2 (4 pts) (nesting depth added 119). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_listener.go"},"region":{"startLine":381}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee7e8a38d58d9606eda2fa5c92e33926a02d48ab0c68453ec533fdf42c6488ee"}},{"ruleId":"D2","level":"warning","message":{"text":"main.run (cognitive 165): main.run has cognitive complexity 165 (threshold 15). Drivers by points: if/else 113 (142 pts), boolean chains 13, match/switch 4 (7 pts), loops 3 (nesting depth added 32). Of this number, 162 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb66752ed3449a3368a8a9d260203169d2ddef4ee124685d36b330897f02afcc"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.registerMessages (cognitive 165): Router.registerMessages has cognitive complexity 165 (threshold 15). Drivers by points: if/else 87 (149 pts), boolean chains 14, loops 2 (nesting depth added 62). None of this is in the body itself: all 165 points belong to 7 function literals inside it that branch (lines 713, 493, 658, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_register.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bc97805f25a2fa3c5551229e977d07c3f83af94b303da2a3b03b89627ecf572"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.sendPrivateTextOnce (cognitive 143): MessageStore.sendPrivateTextOnce has cognitive complexity 143 (threshold 15). Drivers by points: if/else 90 (138 pts), boolean chains 5 (nesting depth added 48). Of this number, 142 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d80e580be27a313bb4ee5dbbbd9db4ba2fbe1f4ceb3d54136395618ac815c3f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesForwardMessages (cognitive 133): Router.onMessagesForwardMessages has cognitive complexity 133 (threshold 15). Drivers by points: if/else 57 (99 pts), loops 12 (21 pts), boolean chains 11, match/switch 1 (2 pts) (nesting depth added 52). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b5b06b667d3f55f72fcf0cc757e678e3a6e00b383248e62391de33842e1018e"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.parseBotAPIMarkdownV2 (cognitive 124): botapi.parseBotAPIMarkdownV2 has cognitive complexity 124 (threshold 15). Drivers by points: if/else 34 (97 pts), boolean chains 16, loops 2 (6 pts), match/switch 2 (5 pts) (nesting depth added 70). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":645}}}],"partialFingerprints":{"codehealthFindingId/v1":"cef07526ec610550f8e8ea2c47cee297a417497cd2b39ac5279acf88c02e8ead"}},{"ruleId":"D2","level":"warning","message":{"text":"config.Load (cognitive 116): config.Load has cognitive complexity 116 (threshold 15). Drivers by points: if/else 72 (79 pts), boolean chains 36, match/switch 1 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":958}}}],"partialFingerprints":{"codehealthFindingId/v1":"723693bacaee35a260aec5925ffdd99beb99544c2a95b5c7d5505a7be7975627"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.finishDeleteMessagesTx (cognitive 116): MessageStore.finishDeleteMessagesTx has cognitive complexity 116 (threshold 15). Drivers by points: if/else 37 (94 pts), loops 11 (15 pts), boolean chains 7 (nesting depth added 61). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"099b68ef155849e4132afcbe4e72dc71417a42f34fe3d27180f2962517674b7a"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.resolveInputMedia (cognitive 111): Router.resolveInputMedia has cognitive complexity 111 (threshold 15). Drivers by points: if/else 44 (94 pts), boolean chains 7, loops 2 (5 pts), match/switch 2 (5 pts) (nesting depth added 56). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":630}}}],"partialFingerprints":{"codehealthFindingId/v1":"411db90abf7d7703af9035d56878b495814c6c25af3c0819ccf632d9ccc0aa7a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.sendChannelMessageOnce (cognitive 107): ChannelStore.sendChannelMessageOnce has cognitive complexity 107 (threshold 15). Drivers by points: if/else 59 (91 pts), boolean chains 13, match/switch 1 (3 pts) (nesting depth added 34). Of this number, 106 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"88ecf0c6a66ff1035f780004ccc2f4a6fdedd876d8f2221a91c1c9fb983eb430"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgOtherUpdateFromEvent (cognitive 104): rpc.tgOtherUpdateFromEvent has cognitive complexity 104 (threshold 15). Drivers by points: if/else 42 (85 pts), boolean chains 18, match/switch 1 (nesting depth added 43). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"34f299bcd2e89a9b673a2ac3ca863eaaa1bb69155679394796ecc4f8c39cd91d"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftUpgradeStore.markPrivateStarGiftSourceUpgradedTx (cognitive 102): StarGiftUpgradeStore.markPrivateStarGiftSourceUpgradedTx has cognitive complexity 102 (threshold 15). Drivers by points: if/else 38 (90 pts), boolean chains 9, loops 2 (3 pts) (nesting depth added 53). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":703}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4b52b3ffc421dd8000fb83c534cb0d1b257acca2fa320db14e63ef4b16de938"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelHistory (cognitive 95): ChannelStore.ListChannelHistory has cognitive complexity 95 (threshold 15). Drivers by points: if/else 59 (84 pts), loops 4 (7 pts), boolean chains 3, match/switch 1 (nesting depth added 28). Of this number, 78 points are the body\u0027s own statements and 17 belong to 6 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"31e9d1ac0abd62159be7da5e67256951b3204965b24a073d06737932e02c9cd0"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.StartupRun (cognitive 94): loadharness.StartupRun has cognitive complexity 94 (threshold 15). Drivers by points: if/else 45 (72 pts), loops 10 (14 pts), match/switch 2 (5 pts), boolean chains 3 (nesting depth added 34). Of this number, 83 points are the body\u0027s own statements and 11 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb125c6d50d7757da44ba783a9138ad44c2ac7a3a3e23a26e28e3741f834bcd3"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelHistory (cognitive 94): ChannelStore.ListChannelHistory has cognitive complexity 94 (threshold 15). Drivers by points: if/else 37 (62 pts), boolean chains 26, loops 5, match/switch 1 (nesting depth added 25). Of this number, 73 points are the body\u0027s own statements and 21 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"021f278b025892b8e52e1d8c2c84b716b3783fa9adf42f6cda4275cb7dfe5b50"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.EditMessage (cognitive 93): MessageStore.EditMessage has cognitive complexity 93 (threshold 15). Drivers by points: if/else 50 (81 pts), boolean chains 9, loops 2 (3 pts) (nesting depth added 32). Of this number, 92 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"7348e5b8c7d12764c3218d82421e5976cf13e3857235bc95d83f1365c0e02a0b"}},{"ruleId":"D2","level":"warning","message":{"text":"main.doFetch (cognitive 91): main.doFetch has cognitive complexity 91 (threshold 15). Drivers by points: if/else 45 (74 pts), loops 6 (10 pts), match/switch 4 (5 pts), boolean chains 2 (nesting depth added 34). Of this number, 49 points are the body\u0027s own statements and 42 belong to 7 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/appearancefetch/main.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"c19d532f4b2144962c707c6adcd4f1b6e27724cce574253bfaf2874c29eabcda"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.claimAuthLayerDefaultEvidenceLocked (cognitive 91): Router.claimAuthLayerDefaultEvidenceLocked has cognitive complexity 91 (threshold 15). Drivers by points: if/else 27 (69 pts), loops 8 (15 pts), boolean chains 7 (nesting depth added 49). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_inheritance.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1c63dec6746faa44984773dead19fdf4a895cda56a14cb3c6d8102014794d19"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.pushToUserWithSender (cognitive 90): SessionManager.pushToUserWithSender has cognitive complexity 90 (threshold 15). Drivers by points: if/else 30 (79 pts), boolean chains 7, loops 3 (4 pts) (nesting depth added 50). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1874}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb65774811dd5901e0ef39ee828a0a7c67a63bc0d5b82270ae7160f46424d159"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelStats (cognitive 90): ChannelStore.GetChannelStats has cognitive complexity 90 (threshold 15). Drivers by points: if/else 24 (55 pts), loops 14 (20 pts), boolean chains 10, match/switch 2 (5 pts) (nesting depth added 40). Of this number, 88 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"026c3884c4a2dfb0dab795e4446424252c9c6278663fcae9902904d9b65732d5"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditChannelMessage (cognitive 90): ChannelStore.EditChannelMessage has cognitive complexity 90 (threshold 15). Drivers by points: if/else 55 (76 pts), boolean chains 14 (nesting depth added 21). Of this number, 89 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"50e5138143cb16da4ce9329212895b0618a890a69cb9a3790af89d129154c417"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.serveConn (cognitive 89): Server.serveConn has cognitive complexity 89 (threshold 15). Drivers by points: if/else 32 (85 pts), boolean chains 3, loops 1 (nesting depth added 53). Of this number, 87 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":997}}}],"partialFingerprints":{"codehealthFindingId/v1":"067f3a482d8f533444761f1f5fa2039d84f739e1077e5f6e5e30019b13358413"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.CraftStarGift (cognitive 88): StarGiftLifecycleStore.CraftStarGift has cognitive complexity 88 (threshold 15). Drivers by points: if/else 44 (72 pts), boolean chains 11, loops 5 (nesting depth added 28). Of this number, 26 points are the body\u0027s own statements and 62 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"d46647a55bc1dee7e5ee584f0f80fa2f8d5b8ac04d955ada21a304b6c532e445"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditChannelMessage (cognitive 87): ChannelStore.EditChannelMessage has cognitive complexity 87 (threshold 15). Drivers by points: if/else 30 (60 pts), boolean chains 16, loops 5 (11 pts) (nesting depth added 36). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"06fbe5211da8c2a11714418686f85c7e0245824c494fd583278f616db1625690"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetDiscussionGroup (cognitive 87): ChannelStore.SetDiscussionGroup has cognitive complexity 87 (threshold 15). Drivers by points: if/else 46 (71 pts), boolean chains 16 (nesting depth added 25). Of this number, 81 points are the body\u0027s own statements and 6 belong to 4 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":1121}}}],"partialFingerprints":{"codehealthFindingId/v1":"9916c122bbd7da455f52685b291f1cfc98ae951c887bd7bf083104b52e20d25b"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.sweep (cognitive 85): Service.sweep has cognitive complexity 85 (threshold 15). Drivers by points: if/else 38 (78 pts), loops 3 (4 pts), boolean chains 3 (nesting depth added 41). Of this number, 69 points are the body\u0027s own statements and 16 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/sweep.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"958dd38fca193ea95b6f41cbc93bce97c54ccc9737b328c8d864baba131b9017"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelDialogs (cognitive 85): ChannelStore.GetChannelDialogs has cognitive complexity 85 (threshold 15). Drivers by points: if/else 34 (73 pts), loops 7 (8 pts), boolean chains 4 (nesting depth added 40). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":755}}}],"partialFingerprints":{"codehealthFindingId/v1":"59488d4484dc565f2acd44bce824efebe7962460c849748ce8688b7fa2f7e2bf"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.domainPollFromInputMedia (cognitive 84): Router.domainPollFromInputMedia has cognitive complexity 84 (threshold 15). Drivers by points: if/else 33 (63 pts), boolean chains 12, loops 5 (7 pts), match/switch 1 (2 pts) (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_polls.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"46fde34b7b48a5524b82358b732bacd7863cfbffb6ff3f87479b2e58b7f57d2e"}},{"ruleId":"D2","level":"warning","message":{"text":"CachedContactStore.ContactProjectionForViewers (cognitive 81): CachedContactStore.ContactProjectionForViewers has cognitive complexity 81 (threshold 15). Drivers by points: if/else 17 (58 pts), loops 7 (18 pts), boolean chains 5 (nesting depth added 52). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"b613b0c92e26fce94bd2aa5dafa592a4a9dc68410bb5dfb9cefe404493bd0c53"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ReadHistory (cognitive 81): MessageStore.ReadHistory has cognitive complexity 81 (threshold 15). Drivers by points: if/else 19 (55 pts), loops 6 (19 pts), boolean chains 7 (nesting depth added 49). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"664b1ebd4eb4e4cc5206e1075789a103dbb50fcbdaaf10e85bd0f2cc8fe528ee"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.domainInlineResultFromTG (cognitive 80): Router.domainInlineResultFromTG has cognitive complexity 80 (threshold 15). Drivers by points: if/else 30 (77 pts), match/switch 2 (3 pts) (nesting depth added 48). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e9575124cbd54c63e71cbcfdf040d84d749a8c8a33068ab93f6f68073328224"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.dispatch (cognitive 80): Router.dispatch has cognitive complexity 80 (threshold 15). Drivers by points: if/else 32 (73 pts), boolean chains 4, loops 1 (2 pts), match/switch 1 (nesting depth added 42). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":675}}}],"partialFingerprints":{"codehealthFindingId/v1":"95d0ba81aa1a2ca4913f64d22f0b5fcbc1100b4157a97ddac91d606f87401037"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.CanSeeForViewerUserIDs (cognitive 77): Service.CanSeeForViewerUserIDs has cognitive complexity 77 (threshold 15). Drivers by points: if/else 21 (45 pts), loops 15 (27 pts), boolean chains 5 (nesting depth added 36). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service_sparse.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"18a1cc2282e9978fdbd9a002a125c5748d15bb620e96cbb53c851ae176a6b1b3"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ToggleSuggestedPostApproval (cognitive 77): ChannelStore.ToggleSuggestedPostApproval has cognitive complexity 77 (threshold 15). Drivers by points: if/else 45 (65 pts), boolean chains 12 (nesting depth added 20). Of this number, 76 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"02962c4b8c32aab977d975cbafa5382e9314fd1729ef683fbcd3666c33e62b8a"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.retireUserStarGiftMessagesTx (cognitive 77): StarGiftLifecycleStore.retireUserStarGiftMessagesTx has cognitive complexity 77 (threshold 15). Drivers by points: if/else 29 (67 pts), boolean chains 5, loops 4 (5 pts) (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle_projection.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6374c7e0a823b74855abf3b3c654a538481ffc841b7afb5a91d0c9906c0c4b6"}},{"ruleId":"D2","level":"warning","message":{"text":"richMessageMediaRefs.collectBlocks (cognitive 76): richMessageMediaRefs.collectBlocks has cognitive complexity 76 (threshold 15). Drivers by points: if/else 18 (64 pts), loops 4 (10 pts), match/switch 1 (2 pts) (nesting depth added 53). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_rich_message.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"7486a52f209aa43ee9018ac7bf70b2fa65c0d1a1f9653be26b34e72fded87316"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.parseBotAPIHTML (cognitive 75): botapi.parseBotAPIHTML has cognitive complexity 75 (threshold 15). Drivers by points: if/else 15 (59 pts), match/switch 2 (7 pts), loops 3 (5 pts), boolean chains 4 (nesting depth added 51). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b5163d98bcee6dda9bf220800c75bd5eccebb3a56649cb5ddd52b3ea53d2f92"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SearchJoinedMessages (cognitive 74): ChannelStore.SearchJoinedMessages has cognitive complexity 74 (threshold 15). Drivers by points: if/else 22 (49 pts), boolean chains 20, loops 4 (5 pts) (nesting depth added 28). Of this number, 72 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"015da3eb0a9f303f5709e049ad5669b5991f9686550abcc6e46a9b27381ad880"}},{"ruleId":"D2","level":"warning","message":{"text":"ActionExecutor.Execute (cognitive 73): ActionExecutor.Execute has cognitive complexity 73 (threshold 15). Drivers by points: if/else 27 (61 pts), boolean chains 11, match/switch 1 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/actions.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"56c908d9cef01778366b1d3429d7854be1ca7d5b31fdca1f3b1297fdc033c5e9"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.listChannelDifferenceAttempt (cognitive 73): ChannelStore.listChannelDifferenceAttempt has cognitive complexity 73 (threshold 15). Drivers by points: if/else 34 (54 pts), boolean chains 9, loops 5 (8 pts), match/switch 1 (2 pts) (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"722aa456243b37cd2cebea7ec620e6dd7018c8380a0450bc6cb2007bedb19fab"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.Run (cognitive 70): loadharness.Run has cognitive complexity 70 (threshold 15). Drivers by points: if/else 34 (44 pts), match/switch 4 (10 pts), loops 6 (8 pts), boolean chains 4, jumps 4 (nesting depth added 18). Of this number, 68 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":738}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8c6817d144e368b5475a82c699d6c9078281da686bd28bfe741574d65a58c1d"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.handleEncrypted (cognitive 70): Server.handleEncrypted has cognitive complexity 70 (threshold 15). Drivers by points: if/else 40 (66 pts), boolean chains 4 (nesting depth added 26). Of this number, 68 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"417c85537f4161f5178c108083df77291eaa9b575eaefb2431c59455a2639240"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftUpgradeStore.UpgradeStarGift (cognitive 70): StarGiftUpgradeStore.UpgradeStarGift has cognitive complexity 70 (threshold 15). Drivers by points: if/else 47 (57 pts), boolean chains 11, loops 1 (2 pts) (nesting depth added 11). Of this number, 16 points are the body\u0027s own statements and 54 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4c33c2a586f54586e5700b82f0c7050fd3aa849fd97186d8321dbc36d2b70ea"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.VerifyLoginEmail (cognitive 69): Service.VerifyLoginEmail has cognitive complexity 69 (threshold 15). Drivers by points: if/else 36 (63 pts), boolean chains 6 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":870}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7284f37fc023c177c630071d42e2f322a4b2db944e36e32095347c1fd723fdc"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.CanSeeMatrix (cognitive 69): Service.CanSeeMatrix has cognitive complexity 69 (threshold 15). Drivers by points: if/else 21 (44 pts), loops 9 (19 pts), boolean chains 6 (nesting depth added 33). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dac5441fe4481d6848fcaf08dbcde75fdfe8c35902c7977ae6c9e56bbe20d00"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.evaluateReport (cognitive 69): loadharness.evaluateReport has cognitive complexity 69 (threshold 15). Drivers by points: if/else 29 (49 pts), loops 8 (11 pts), boolean chains 9 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1201}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2f06bcc3e2307e83f9e5a7c4317f83917c2c08c411cd98a253ee5d8592776a0"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelStats (cognitive 69): ChannelStore.GetChannelStats has cognitive complexity 69 (threshold 15). Drivers by points: if/else 38 (57 pts), loops 8 (9 pts), boolean chains 3 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbaac775bd900151083706ba8217356e5b3874b495f4e21e9e5e49227f757968"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.scanBotAPIHTMLTag (cognitive 68): botapi.scanBotAPIHTMLTag has cognitive complexity 68 (threshold 15). Drivers by points: if/else 19 (33 pts), loops 9 (18 pts), boolean chains 17 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"e012be7a022ad98e53b868719d9d444ed4ab481a29b9073858466c23276994c6"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.prepareInboundRPCBatch (cognitive 68): Server.prepareInboundRPCBatch has cognitive complexity 68 (threshold 15). Drivers by points: if/else 22 (52 pts), loops 4 (7 pts), match/switch 2 (6 pts), boolean chains 3 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"d84711eaa8a50d77fc90478debee1052c36ee95df799b0fb6fa727827103c352"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetChannelMessageReactions (cognitive 68): ChannelStore.SetChannelMessageReactions has cognitive complexity 68 (threshold 15). Drivers by points: if/else 34 (56 pts), loops 5 (7 pts), boolean chains 5 (nesting depth added 24). Of this number, 67 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"4855853b4e56634ca9f3c512e1b6b6cf3b075b97cd12ef2b3c46e32bb6b61f63"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.settleStarGiftAuction (cognitive 68): StarGiftLifecycleStore.settleStarGiftAuction has cognitive complexity 68 (threshold 15). Drivers by points: if/else 26 (55 pts), boolean chains 7, loops 3 (6 pts) (nesting depth added 32). Most of this is not in the body itself: 2 of the 68 points are its own statements and the rest belongs to one function literal inside it that branches (line 617). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e29a55af97a872739b748e863b2a60ea660662f651961582d81979fa26e2ffd"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.seedInitialLayerProfile (cognitive 67): Server.seedInitialLayerProfile has cognitive complexity 67 (threshold 15). Drivers by points: if/else 31 (63 pts), boolean chains 4 (nesting depth added 32). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn_layer_profile.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"3670658e013a08b75dbbfca77cdba02ca8064b895d26085093f61655eabad257"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSendMultiMedia (cognitive 67): Router.onMessagesSendMultiMedia has cognitive complexity 67 (threshold 15). Drivers by points: if/else 34 (56 pts), loops 6 (7 pts), boolean chains 4 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":464}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1d1527689d8029e980a25a272b640aa9e946619c6a277792443ae357534f84c"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.validateMarkupButton (cognitive 66): domain.validateMarkupButton has cognitive complexity 66 (threshold 15). Drivers by points: if/else 21 (50 pts), boolean chains 12, match/switch 3 (4 pts) (nesting depth added 30). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_markup.go"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3784b8c74d2bf7cdc14eb0d1a506f706bb5e4ca0feb1ca7881a778fb24e01d4"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.ListByOwnerFiltered (cognitive 66): StarGiftStore.ListByOwnerFiltered has cognitive complexity 66 (threshold 15). Drivers by points: if/else 24 (49 pts), boolean chains 15, loops 2 (nesting depth added 25). Of this number, 60 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"cade259d3a0e784e60336d1d5ef98a0a101b959db7402e9cc92036104c383b3d"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginRequest.Validate (cognitive 65): TelegramLoginRequest.Validate has cognitive complexity 65 (threshold 15). Drivers by points: if/else 27 (43 pts), boolean chains 19, loops 1 (2 pts), match/switch 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/telegram_login.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eac080020cc738025b72b695748fc83499add712d5d4c76454762c15b7a136a"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSendMedia (cognitive 65): Router.onMessagesSendMedia has cognitive complexity 65 (threshold 15). Drivers by points: if/else 40 (57 pts), boolean chains 5, match/switch 2 (3 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c4228565471eca0dc3dc48e58d06299551c0e1335779e8d643e0e542a2371d9"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.domainStoryMediaAreasFromTL (cognitive 65): Router.domainStoryMediaAreasFromTL has cognitive complexity 65 (threshold 15). Drivers by points: if/else 22 (61 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 40). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1671}}}],"partialFingerprints":{"codehealthFindingId/v1":"b337e052cbc3dd825fe7a2a2d611bc807d33c0823c837e0d5daa2d102afaea8b"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.finishMemoryDeleteLocked (cognitive 65): MessageStore.finishMemoryDeleteLocked has cognitive complexity 65 (threshold 15). Drivers by points: if/else 18 (46 pts), loops 9 (15 pts), boolean chains 4 (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_delete.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"f32c4c7a7d5ab195a3d5167181fa2712efeee42e1bbc1105bf5cf8afb1f75772"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.CreateAuthorization (cognitive 64): Service.CreateAuthorization has cognitive complexity 64 (threshold 15). Drivers by points: if/else 35 (49 pts), boolean chains 15 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"27e6c693e53b0f615c232c2486075c1bc5def0bd1139e7e1203a9c336aabd7f0"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.walkInbound (cognitive 64): Server.walkInbound has cognitive complexity 64 (threshold 15). Drivers by points: if/else 33 (54 pts), boolean chains 8, loops 1 (2 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"2084a36e44b58e1556241ed413d56c245801c314abde98eec9934da35c02a76b"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SendChannelMessage (cognitive 64): ChannelStore.SendChannelMessage has cognitive complexity 64 (threshold 15). Drivers by points: if/else 30 (44 pts), boolean chains 13, loops 2 (4 pts), match/switch 1 (3 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce7ef9b06eb59f77800045fa47c595d04bc2173389edbb753ff30f0581f46c9e"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.InviteToChannel (cognitive 64): ChannelStore.InviteToChannel has cognitive complexity 64 (threshold 15). Drivers by points: if/else 30 (57 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 29). Of this number, 63 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_members.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6657351b85ad6f2b8c7944f354f7fc0e81028e56ac15eb68a247d9397fb76ca"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SendMonoforumMessage (cognitive 64): ChannelStore.SendMonoforumMessage has cognitive complexity 64 (threshold 15). Drivers by points: if/else 37 (52 pts), boolean chains 11, loops 1 (nesting depth added 15). Of this number, 63 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_monoforum.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"a94b1e57d509c6c5a3b7aff1416c015ebfe1e0d4b61f3b405ec7cc3f44dea925"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ReadMessageContents (cognitive 64): MessageStore.ReadMessageContents has cognitive complexity 64 (threshold 15). Drivers by points: if/else 34 (51 pts), loops 7 (8 pts), boolean chains 5 (nesting depth added 18). Of this number, 63 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_read.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ac3534f8344dab787774dbea39b292e7dc3b24d7593575390dfe1a79c94bd23"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.sendSingleSendMessage (cognitive 63): Router.sendSingleSendMessage has cognitive complexity 63 (threshold 15). Drivers by points: if/else 39 (55 pts), boolean chains 6, match/switch 1 (2 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"033c8e7e385a022dda03b991bdabcea6ce50abae01e9582e707cbfde6ba1e9ed"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.buildUserFullProjection (cognitive 63): Router.buildUserFullProjection has cognitive complexity 63 (threshold 15). Drivers by points: if/else 32 (57 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"69223d6156a1e97dec75cb2084e85be6a32333a5af52fdb431541fe9593da04b"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.listChannelDialogs (cognitive 63): ChannelStore.listChannelDialogs has cognitive complexity 63 (threshold 15). Drivers by points: if/else 38 (52 pts), boolean chains 7, loops 3, match/switch 1 (nesting depth added 14). Of this number, 59 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"83de2aa669e137e33c081b687e53b1c8ba31088bb85ffd790e1f87c40e0fd283"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.sendFromBot (cognitive 62): Service.sendFromBot has cognitive complexity 62 (threshold 15). Drivers by points: if/else 32 (47 pts), boolean chains 15 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bd20899db36a500299539e579af1efedf390ba6527e738282ba14b721db49ee"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.executeInboundPlan (cognitive 62): Server.executeInboundPlan has cognitive complexity 62 (threshold 15). Drivers by points: if/else 20 (59 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 40). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":935}}}],"partialFingerprints":{"codehealthFindingId/v1":"b763a7fd38fca466d8f97c7d2b936fa8b8f1ee8e7ed6cf0c6369dc840f2a4c53"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesEditMessage (cognitive 62): Router.onMessagesEditMessage has cognitive complexity 62 (threshold 15). Drivers by points: if/else 37 (50 pts), boolean chains 12 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"a68888b3e756b75b4f4c45d83f277112156d70867418100d661314eaf585e9ae"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.populateChannelMessagesReactionsWhere (cognitive 62): ChannelStore.populateChannelMessagesReactionsWhere has cognitive complexity 62 (threshold 15). Drivers by points: if/else 23 (43 pts), loops 10 (16 pts), boolean chains 3 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_helpers.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b8af71bdb26b29af7c182af8e36dd20e3e9c5c76ff76d850f875c9d6f7d6f87"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.commitLayerProfileEvidence (cognitive 61): Server.commitLayerProfileEvidence has cognitive complexity 61 (threshold 15). Drivers by points: if/else 24 (55 pts), boolean chains 6 (nesting depth added 31). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":1097}}}],"partialFingerprints":{"codehealthFindingId/v1":"df5c64222c1365c3fbde0034c9d45feddfc0ee7b27f15224a1cc71735acf3877"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesToggleDialogPin (cognitive 61): Router.onMessagesToggleDialogPin has cognitive complexity 61 (threshold 15). Drivers by points: if/else 29 (58 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"10e904e151b60628573a8c0fbeac59b9b1f3d71038df7a59e7f353d158365cb6"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.reconcileSeedWith (cognitive 61): postgres.reconcileSeedWith has cognitive complexity 61 (threshold 15). Drivers by points: if/else 25 (48 pts), loops 6 (8 pts), boolean chains 5 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/langpack.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"541ab9850c1b17977e0ff205206ea9b8875169bfacf76d37c2517fae9ce21bd5"}},{"ruleId":"D2","level":"warning","message":{"text":"apiKeyboardButton.UnmarshalJSON (cognitive 60): apiKeyboardButton.UnmarshalJSON has cognitive complexity 60 (threshold 15). Drivers by points: if/else 32 (50 pts), boolean chains 7, match/switch 1 (2 pts), loops 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"44bac43a7b7f87d9606edd390582074686eab5bd87667934aaa3c8a6832c3baa"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.prepareTelegramLoginMarkup (cognitive 60): Router.prepareTelegramLoginMarkup has cognitive complexity 60 (threshold 15). Drivers by points: if/else 18 (48 pts), boolean chains 6, loops 4 (6 pts) (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"89998fde6c64f763572c96ff4fca8af5a1c3fc6df2448727bb6997ebe8c6143f"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.SweepStarGiftLifecycle (cognitive 60): StarGiftLifecycleStore.SweepStarGiftLifecycle has cognitive complexity 60 (threshold 15). Drivers by points: if/else 24 (47 pts), loops 6 (10 pts), boolean chains 3 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"8eaaf7806f8531bae804b2a84706fa70700ac58047797c2b11e6cf31ac428ef3"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.peerIdentityMaps (cognitive 58): Router.peerIdentityMaps has cognitive complexity 58 (threshold 15). Drivers by points: if/else 20 (35 pts), boolean chains 15, loops 4 (8 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/peer_identity_cache.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5a4cee85a6e4028570b53aa52d01fd01bb20ed372d2a95d770378a41cd01c39"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetChannelMessageReactions (cognitive 58): ChannelStore.SetChannelMessageReactions has cognitive complexity 58 (threshold 15). Drivers by points: if/else 23 (37 pts), loops 8 (16 pts), boolean chains 5 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ac5c9718711abd9bb874c9c78177ace22aaa045ad531fad32fb2a47a82a7c1c"}},{"ruleId":"D2","level":"warning","message":{"text":"Projector.ForViewerUserIDs (cognitive 57): Projector.ForViewerUserIDs has cognitive complexity 57 (threshold 15). Drivers by points: if/else 18 (40 pts), loops 6 (9 pts), boolean chains 8 (nesting depth added 25). Of this number, 55 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection_sparse.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f265a7486974e584a854372a185341ec99a5660855a745c22ff9c4ede82f859"}},{"ruleId":"D2","level":"warning","message":{"text":"Cache.GetOrLoadBatch (cognitive 57): Cache.GetOrLoadBatch has cognitive complexity 57 (threshold 15). Drivers by points: if/else 14 (38 pts), loops 6 (15 pts), match/switch 1 (3 pts), boolean chains 1 (nesting depth added 35). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/readmodelcache/cache.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c06d28a7e0aec6be9843af1e7cf7325fca4ee18cda2385c9199ba1c2dfb108d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onChannelsGetSendAs (cognitive 57): Router.onChannelsGetSendAs has cognitive complexity 57 (threshold 15). Drivers by points: if/else 17 (44 pts), loops 2 (7 pts), boolean chains 6 (nesting depth added 32). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ccff7419e3ab945be0a8020502d9596bd13e2414a2422735b23d097de1334a8"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.requestedPeerDetails (cognitive 56): Router.requestedPeerDetails has cognitive complexity 56 (threshold 15). Drivers by points: if/else 16 (42 pts), loops 6 (7 pts), boolean chains 5, match/switch 1 (2 pts) (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"509e5d4f8e462b34da81a304e5db1369aafd3f000c893c16bddcfec1ab1db81e"}},{"ruleId":"D2","level":"warning","message":{"text":"CachedReadModelVersionStore.ReadModelHashes (cognitive 56): CachedReadModelVersionStore.ReadModelHashes has cognitive complexity 56 (threshold 15). Drivers by points: if/else 16 (41 pts), loops 5 (9 pts), boolean chains 3, match/switch 1 (3 pts) (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/read_model_cache.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"38105e6992632d385b8dd585cbdc16adda784f24293df384018d58a3f96a18c7"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgSavedStarGifts (cognitive 55): rpc.tgSavedStarGifts has cognitive complexity 55 (threshold 15). Drivers by points: if/else 21 (44 pts), boolean chains 10, loops 1 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1721}}}],"partialFingerprints":{"codehealthFindingId/v1":"92cc0207d019d650a4a0386dd6c62991cf22f3c55ff0e62b44fd5bdfe4ebb957"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.PublishAdmittedLayerProfileEvidence (cognitive 55): Router.PublishAdmittedLayerProfileEvidence has cognitive complexity 55 (threshold 15). Drivers by points: if/else 29 (43 pts), boolean chains 10, match/switch 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_inheritance.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"0483997b3909f85aaff8c2c4cd030a2b92921e0d220d3f2319507bae220caf93"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteChannelHistory (cognitive 55): ChannelStore.DeleteChannelHistory has cognitive complexity 55 (threshold 15). Drivers by points: if/else 29 (47 pts), boolean chains 4, match/switch 1 (3 pts), loops 1 (nesting depth added 20). Of this number, 54 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"71f5a69b4916a4027d3d1fe35d0f7ce0a59955782e8ce0890a0f1e06f5a08112"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupCallStore.RemoveConferenceCallParticipants (cognitive 55): GroupCallStore.RemoveConferenceCallParticipants has cognitive complexity 55 (threshold 15). Drivers by points: if/else 28 (49 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 22). Of this number, 54 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d164cd86fe2412198a498ee2bcb03b2f82d70fa778962cf23b66fb11f5d4609"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.PurchaseResaleStarGift (cognitive 55): StarGiftLifecycleStore.PurchaseResaleStarGift has cognitive complexity 55 (threshold 15). Drivers by points: if/else 38 (45 pts), boolean chains 10 (nesting depth added 7). Most of this is not in the body itself: 15 of the 55 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 659, 573). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4c83bc471399b4e5c8c5be887193ea59aeebf6f6c0e02435340dc666d0bd620"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.CanSeeBatch (cognitive 54): Service.CanSeeBatch has cognitive complexity 54 (threshold 15). Drivers by points: if/else 19 (37 pts), loops 8 (13 pts), boolean chains 4 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"27118f2fb74e01a7c43ca4a6cde172a8a7cfa1bffda563951f9c0758a3b5ca39"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgChannelMessage (cognitive 53): rpc.tgChannelMessage has cognitive complexity 53 (threshold 15). Drivers by points: if/else 32 (41 pts), boolean chains 8, match/switch 1 (4 pts) (nesting depth added 12). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd3360798342d7235097a3a11c32975b151822ebf39be3b20e1443e4a6dae6bd"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetMessageReactionsList (cognitive 53): Router.onMessagesGetMessageReactionsList has cognitive complexity 53 (threshold 15). Drivers by points: if/else 21 (41 pts), boolean chains 8, loops 2 (4 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_lists.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6a34def89600da2775abdcaeedb5f6cd7a803e65b72b17f28eb871d0a576912"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelDifference (cognitive 53): ChannelStore.ListChannelDifference has cognitive complexity 53 (threshold 15). Drivers by points: if/else 19 (35 pts), boolean chains 9, loops 5 (7 pts), match/switch 1 (2 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6a98945bb6b97457e12ab90da94d87379ce7e5227a4039cf1ee015fc78f34c5"}},{"ruleId":"D2","level":"warning","message":{"text":"channelFanoutDispatcher.Run (cognitive 52): channelFanoutDispatcher.Run has cognitive complexity 52 (threshold 15). Drivers by points: if/else 13 (31 pts), loops 6 (9 pts), match/switch 3 (9 pts), boolean chains 2, jumps 1 (nesting depth added 27). Most of this is not in the body itself: 11 of the 52 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 482, 512). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"337707df44aea5537f0ce764518e1187d994a50b1b8d5fc8d2d8d2223846760b"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.viewLocked (cognitive 52): CommunityStore.viewLocked has cognitive complexity 52 (threshold 15). Drivers by points: if/else 17 (35 pts), loops 5 (9 pts), boolean chains 8 (nesting depth added 22). Of this number, 50 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"348b6b365062577eee68f164df9119f8ea9afbc174b045775c26770b02d3a3ed"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.readHistoryOnce (cognitive 52): MessageStore.readHistoryOnce has cognitive complexity 52 (threshold 15). Drivers by points: if/else 33 (49 pts), boolean chains 3 (nesting depth added 16). Of this number, 51 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"30fb482f667eb68854538e3bfa12fb829c7bcc0cad7442f07d607bb2d584d244"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ImportContacts (cognitive 51): Service.ImportContacts has cognitive complexity 51 (threshold 15). Drivers by points: if/else 19 (34 pts), loops 8 (11 pts), boolean chains 6 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cb210dbacbe1ceb29f4175a6cfccf9db0e9b8789aab4e275fe9594059aa7694"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ManualPurge (cognitive 51): Service.ManualPurge has cognitive complexity 51 (threshold 15). Drivers by points: if/else 13 (32 pts), loops 7 (18 pts), boolean chains 1 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"a310a7d33f1b33aacfaa5ce039052f5d6546693e055645c0c459d8a1f74c9271"}},{"ruleId":"D2","level":"warning","message":{"text":"UserStore.claimOfficialUsernameOnce (cognitive 51): UserStore.claimOfficialUsernameOnce has cognitive complexity 51 (threshold 15). Drivers by points: if/else 32 (40 pts), boolean chains 9, loops 2 (nesting depth added 8). Of this number, 49 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c63b856b8844c758658a08ed92d48805eff76821b58e60452ba37f36aa09f22"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.applyTelegramLoginConfiguration (cognitive 50): Service.applyTelegramLoginConfiguration has cognitive complexity 50 (threshold 15). Drivers by points: if/else 21 (40 pts), boolean chains 8, match/switch 1 (2 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"e40c967d55558dfffb45597b729531a604828f5de2a8ac5da8077c84577f20d5"}},{"ruleId":"D2","level":"warning","message":{"text":"RetentionWorker.runRetentionOnce (cognitive 50): RetentionWorker.runRetentionOnce has cognitive complexity 50 (threshold 15). Drivers by points: if/else 35 (49 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/maintenance/retention.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"55437683a2a58dc200e74f705246a5791e16b1bc41c3ffe3b8e6f1056ef39b76"}},{"ruleId":"D2","level":"warning","message":{"text":"CachedContactStore.ContactProjectionForViewerUserIDs (cognitive 50): CachedContactStore.ContactProjectionForViewerUserIDs has cognitive complexity 50 (threshold 15). Drivers by points: if/else 16 (44 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache_sparse.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4656c2555d1ee2ae37af4f51c3ca83342325da37fbcea793681006356191a55"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.collectRichMessageBlockMetrics (cognitive 50): rpc.collectRichMessageBlockMetrics has cognitive complexity 50 (threshold 15). Drivers by points: if/else 7 (21 pts), loops 6 (17 pts), match/switch 3 (10 pts), boolean chains 2 (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/rich_message_limits.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfb71f216d66ecf56a16d3de72113a8fb81761f7a2fa07162a2c9ff433a9154c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.BuildOutboxUpdates (cognitive 50): Router.BuildOutboxUpdates has cognitive complexity 50 (threshold 15). Drivers by points: if/else 13 (31 pts), loops 10 (18 pts), boolean chains 1 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/outbox_update_builder.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"74cb03d567c9d89304745341ba538913c85b5df59beb3bf80681b192c90db419"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsGetResaleStarGifts (cognitive 50): Router.onPaymentsGetResaleStarGifts has cognitive complexity 50 (threshold 15). Drivers by points: if/else 14 (28 pts), loops 5 (15 pts), boolean chains 4, match/switch 1 (3 pts) (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"2186a4a4f8a043020b32881a82cc4098160f686dd6bf61c5ed48c5a327c3c8d5"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsSendStarsForm (cognitive 50): Router.onPaymentsSendStarsForm has cognitive complexity 50 (threshold 15). Drivers by points: if/else 32 (41 pts), boolean chains 8, match/switch 1 (nesting depth added 9). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5f7e2df43ecf91a9be66768c823213d1402763c9a657c0d50ba088662966b5b"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.persistPlainPrivateSendProjectionBatch (cognitive 50): postgres.persistPlainPrivateSendProjectionBatch has cognitive complexity 50 (threshold 15). Drivers by points: if/else 23 (42 pts), boolean chains 6, loops 2 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_sql.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea924a34724d03cd234f0ed94f03f8c513da257ff546c79ce70d3b2bad9cb5b0"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetPaidMessagesPrice (cognitive 50): ChannelStore.SetPaidMessagesPrice has cognitive complexity 50 (threshold 15). Drivers by points: if/else 22 (41 pts), boolean chains 9 (nesting depth added 19). Most of this is not in the body itself: 4 of the 50 points are its own statements and the rest belongs to one function literal inside it that branches (line 84). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_settings.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"90f6a1137d6bfbfde31743fcc22c6c1834ca83b40ccc7dd822fad11cc0d829f7"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.dispatchStarGiftAuctionAwards (cognitive 50): StarGiftLifecycleStore.dispatchStarGiftAuctionAwards has cognitive complexity 50 (threshold 15). Drivers by points: if/else 16 (44 pts), loops 3 (5 pts), boolean chains 1 (nesting depth added 30). Of this number, 34 points are the body\u0027s own statements and 16 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":804}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c5ac8e5b2305864b876e1b49f3de98f38bfdb5c5b1f1d9dcd5b80191ec22716"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.importDocument (cognitive 49): Service.importDocument has cognitive complexity 49 (threshold 15). Drivers by points: if/else 23 (47 pts), boolean chains 1, loops 1 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c28de06c5030dc35b2e156ce99e13b045824110adcf49c226c56aaff98d2244"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.applyOfflineChannelActions (cognitive 49): loadharness.applyOfflineChannelActions has cognitive complexity 49 (threshold 15). Drivers by points: if/else 21 (45 pts), boolean chains 4 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecedc5b5427949369a1cf30a9b762b3252538902ca8bce632d1bbe613d51b6b2"}},{"ruleId":"D2","level":"warning","message":{"text":"rpcRewrapAlias.activate (cognitive 49): rpcRewrapAlias.activate has cognitive complexity 49 (threshold 15). Drivers by points: if/else 26 (42 pts), boolean chains 7 (nesting depth added 16). Most of this is not in the body itself: 10 of the 49 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 872, 865). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_rewrap.go"},"region":{"startLine":855}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4b84558d848b85d9ea49667781aecaf251ac52e911ac65a53863335beb1b0b6"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgMessageMedia (cognitive 49): rpc.tgMessageMedia has cognitive complexity 49 (threshold 15). Drivers by points: if/else 24 (47 pts), boolean chains 1, match/switch 1 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_media.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"312b65bb4e393a5ed3b778b6a4af1146f3acf4f32f7827ceeb171185c3bd2f1a"}},{"ruleId":"D2","level":"warning","message":{"text":"OutboxDispatcher.dispatchBatch (cognitive 49): OutboxDispatcher.dispatchBatch has cognitive complexity 49 (threshold 15). Drivers by points: if/else 18 (37 pts), loops 9 (12 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/outbox_dispatcher.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"d88c6bb6435e9ede948a28773eeb61a6d783f52ae33be92f9fe6d23765690ff3"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetDiscussionGroup (cognitive 49): ChannelStore.SetDiscussionGroup has cognitive complexity 49 (threshold 15). Drivers by points: if/else 25 (37 pts), boolean chains 12 (nesting depth added 12). Of this number, 45 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1c8bc145ca0045e39ebc9193c2ec33417eef995b377d01ae47e58a03c6d144c"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.EditMessage (cognitive 49): MessageStore.EditMessage has cognitive complexity 49 (threshold 15). Drivers by points: if/else 17 (33 pts), boolean chains 10, loops 4 (6 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_edit.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"a45ee5482565f174bbe8a2051a8f4b411fffed7c438efc55f9a48aa8cb36e410"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannels (cognitive 49): ChannelStore.GetChannels has cognitive complexity 49 (threshold 15). Drivers by points: if/else 23 (38 pts), loops 7, boolean chains 4 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"608b330f0a4ba62cf4cbb5ced87f26ddf19ad4d28f7bd4330e0c394b847ce90c"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SignUp (cognitive 48): Service.SignUp has cognitive complexity 48 (threshold 15). Drivers by points: if/else 33 (38 pts), boolean chains 10 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1281}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1c1400a5215ff66304039fe840c960ea10cc4aa6e9d05888766ebaff2c2375b"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.runFlush (cognitive 48): SessionManager.runFlush has cognitive complexity 48 (threshold 15). Drivers by points: if/else 15 (42 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1242}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2bbd80ffd753523734fe43fb82606bd6fd5e5a023c4246d88240a444c40b2c9"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.resolveChannelReply (cognitive 48): ChannelStore.resolveChannelReply has cognitive complexity 48 (threshold 15). Drivers by points: if/else 21 (34 pts), boolean chains 12, match/switch 1 (2 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":808}}}],"partialFingerprints":{"codehealthFindingId/v1":"e008ac2120d945cbc588362f83ee583321df99f6f5ac873d6fc7172115057aed"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.DeleteHistory (cognitive 48): MessageStore.DeleteHistory has cognitive complexity 48 (threshold 15). Drivers by points: if/else 28 (42 pts), boolean chains 6 (nesting depth added 14). Of this number, 47 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":497}}}],"partialFingerprints":{"codehealthFindingId/v1":"4085fc6f9e6609915767a845b46a3cdfb077596d42c9a8a999759cb29323902e"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.upsertMemoryDialog (cognitive 47): memory.upsertMemoryDialog has cognitive complexity 47 (threshold 15). Drivers by points: if/else 15 (44 pts), boolean chains 2, loops 1 (nesting depth added 29). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":681}}}],"partialFingerprints":{"codehealthFindingId/v1":"2632b59b0f15a2b30b3925f33690a05bf48b1accc6a3f8fbdc2dfae36bb057a8"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditChannelAdmin (cognitive 47): ChannelStore.EditChannelAdmin has cognitive complexity 47 (threshold 15). Drivers by points: if/else 33 (43 pts), boolean chains 4 (nesting depth added 10). Of this number, 46 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"574f035bd36cbb07b8e113cdc63a4ca6b68bcc11ffcb9a9253f1984d687bd115"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.chatBotPromptText (cognitive 46): Service.chatBotPromptText has cognitive complexity 46 (threshold 15). Drivers by points: if/else 11 (38 pts), boolean chains 5, loops 1 (3 pts) (nesting depth added 29). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/chatbot.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"119e49f2f4e4f818082958bf59b8c9e27cf79264061cf69913c3def6ac5aef7d"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.apiUpdate (cognitive 46): botapi.apiUpdate has cognitive complexity 46 (threshold 15). Drivers by points: if/else 18 (39 pts), boolean chains 4, loops 1 (2 pts), match/switch 1 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d390f11b3fa9c792c0749cf9161eede1890f632c903735140e17c04ed0358ad"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.apiReplyMarkup (cognitive 46): botapi.apiReplyMarkup has cognitive complexity 46 (threshold 15). Drivers by points: if/else 10 (25 pts), match/switch 3 (13 pts), loops 3 (8 pts) (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":486}}}],"partialFingerprints":{"codehealthFindingId/v1":"75669b3885c439b9f32058c963e161662c9cb7cd9704b596e3b97ac28fbb7549"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.mergeDialogPageKnownOverlap (cognitive 46): loadharness.mergeDialogPageKnownOverlap has cognitive complexity 46 (threshold 15). Drivers by points: if/else 16 (35 pts), boolean chains 7, loops 4 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":401}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa9c97bfd827c6639ab12f815084f233af11bb84546a52cfa51889c0c815445b"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onUsersGetUsers (cognitive 46): Router.onUsersGetUsers has cognitive complexity 46 (threshold 15). Drivers by points: if/else 18 (37 pts), loops 3 (4 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d44d1a45696bdc42e5f5155c21e5ebbb97ed2ea21bc2ff60a0285afd54c8976"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.filterMessageList (cognitive 46): memory.filterMessageList has cognitive complexity 46 (threshold 15). Drivers by points: if/else 17 (33 pts), boolean chains 11, loops 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d91ec05d54272a897c6db275b89824e4ef74c6dba7fdafce1163f4553984821"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.loadChannelDifferenceBase (cognitive 46): ChannelStore.loadChannelDifferenceBase has cognitive complexity 46 (threshold 15). Drivers by points: if/else 21 (41 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"503641a676a3a6b2be4e10fdb64d8821b2a69da730fa93c7acc55b913d822203"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.ApproveTelegramLoginRequest (cognitive 46): TelegramLoginStore.ApproveTelegramLoginRequest has cognitive complexity 46 (threshold 15). Drivers by points: if/else 32 (41 pts), boolean chains 5 (nesting depth added 9). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":523}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd41356ad2c1f6d74d5c2e0c088d366a277ef47ba60e2053e80c7c69d63bc297"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.validateApps (cognitive 46): Catalog.validateApps has cognitive complexity 46 (threshold 15). Drivers by points: if/else 11 (36 pts), loops 4 (9 pts), boolean chains 1 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/updatecdn/catalog.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"942ff5f07e4f154343d043ab0844949bd53bfb61810a9a30e3784d17eccc3b88"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.createStickerSet (cognitive 45): Service.createStickerSet has cognitive complexity 45 (threshold 15). Drivers by points: if/else 24 (39 pts), boolean chains 4, loops 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"07150f02288aa92f7caad05143120932e921e2f94ff739f17d26d774e2f08d63"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.apiRequestedPeer (cognitive 45): botapi.apiRequestedPeer has cognitive complexity 45 (threshold 15). Drivers by points: if/else 14 (31 pts), boolean chains 10, loops 3 (4 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":856}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e8cc6f2f8d0777179b067b7a7493ece34563d16b0e5d84d27539c8f9e67cbed"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.requestValuesWithFiles (cognitive 45): botapi.requestValuesWithFiles has cognitive complexity 45 (threshold 15). Drivers by points: if/else 15 (35 pts), loops 4 (7 pts), match/switch 1 (3 pts) (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1280}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c5a6167a8c818bdfa344b882790baab3790ce7154a7f4cb361900d035ec243d"}},{"ruleId":"D2","level":"warning","message":{"text":"apiInlineKeyboardButton.UnmarshalJSON (cognitive 45): apiInlineKeyboardButton.UnmarshalJSON has cognitive complexity 45 (threshold 15). Drivers by points: if/else 27 (41 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":726}}}],"partialFingerprints":{"codehealthFindingId/v1":"23ca7f16fd0a34c2e98e1fcdf1ae4cd405a15cd21242692d83cf8b398c965765"}},{"ruleId":"D2","level":"warning","message":{"text":"Conn.handleOutboundSend (cognitive 45): Conn.handleOutboundSend has cognitive complexity 45 (threshold 15). Drivers by points: if/else 27 (38 pts), boolean chains 7 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":2260}}}],"partialFingerprints":{"codehealthFindingId/v1":"394aeac177f91129510510c88a9b600a7caf93a529f55f8b0c05478472cb1757"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.sendOutgoing (cognitive 45): Router.sendOutgoing has cognitive complexity 45 (threshold 15). Drivers by points: if/else 25 (39 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2c708eb7a3f17e0a3c42dc236d7eb0beeba76fbc65410d789dce81d1dffa2ee"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.buildEmojiStickerIndex (cognitive 45): Router.buildEmojiStickerIndex has cognitive complexity 45 (threshold 15). Drivers by points: if/else 10 (34 pts), loops 4 (10 pts), boolean chains 1 (nesting depth added 30). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers_emoji_index.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"4578d295398054101f1d7b01da6334ac0a9dacec9428a790813636a30688422c"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelMessageViews (cognitive 45): ChannelStore.GetChannelMessageViews has cognitive complexity 45 (threshold 15). Drivers by points: if/else 19 (36 pts), loops 5, boolean chains 4 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_views.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8ab0ac63d9874a8916cd913ffb4a6fd8e8d59c4ae1613da92fe26c8cc511f51"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.populateChannelMessageReplies (cognitive 45): ChannelStore.populateChannelMessageReplies has cognitive complexity 45 (threshold 15). Drivers by points: if/else 13 (30 pts), loops 6 (12 pts), boolean chains 3 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":722}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e2786a6aadc3a724c4f30370342318d7bc0dd6f851e962ac3257ab2f7e26478"}},{"ruleId":"D2","level":"warning","message":{"text":"files.parsePremiumPromoSeed (cognitive 44): files.parsePremiumPromoSeed has cognitive complexity 44 (threshold 15). Drivers by points: if/else 21 (38 pts), boolean chains 5, loops 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/premium_promo_seed.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae82d792d2ad12b75b871ceebf5bc5a6362638cc030b0ce8f21131d5035e58c7"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.parseBotAPIMarkdown (cognitive 44): botapi.parseBotAPIMarkdown has cognitive complexity 44 (threshold 15). Drivers by points: if/else 12 (29 pts), loops 3 (7 pts), boolean chains 6, match/switch 1 (2 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ccf7185013a7f1bb5f8f8fe8fb1a27ffadd9bff131620faa2ef8aa5e0b56d47"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgUpdatesDifference (cognitive 44): rpc.tgUpdatesDifference has cognitive complexity 44 (threshold 15). Drivers by points: if/else 14 (38 pts), boolean chains 2, loops 2, match/switch 1 (2 pts) (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"a46a4374ed82aa4d56a1071ca3cec62f457d3fdd77075090bcae822d4fe3f08f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.messageReplyFromInput (cognitive 44): Router.messageReplyFromInput has cognitive complexity 44 (threshold 15). Drivers by points: if/else 22 (33 pts), boolean chains 9, match/switch 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":632}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd1bc349259a84bab2353d59bf02eb8fa981137fe6d66ff12cdd351fc8476721"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftUpgradeStore.GrantUniqueStarGift (cognitive 44): StarGiftUpgradeStore.GrantUniqueStarGift has cognitive complexity 44 (threshold 15). Drivers by points: if/else 33 (40 pts), boolean chains 4 (nesting depth added 7). Of this number, 16 points are the body\u0027s own statements and 28 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"832c3ab478b32b317b4369790a3608057d16f5597a3c0a7cea809fe658f567c1"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.GiveStarGift (cognitive 43): Service.GiveStarGift has cognitive complexity 43 (threshold 15). Drivers by points: if/else 26 (35 pts), boolean chains 8 (nesting depth added 9). Most of this is not in the body itself: 14 of the 43 points are its own statements and the rest belongs to one function literal inside it that branches (line 489). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/star_gift_catalog.go"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"2001e4425fcf9ea745612ccba814108137beeb623631b2e26dee89ff332624a4"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.validateDecisionActions (cognitive 43): Service.validateDecisionActions has cognitive complexity 43 (threshold 15). Drivers by points: if/else 13 (34 pts), boolean chains 6, match/switch 1 (2 pts), loops 1 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/actions.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"188b54bbdcab812625c29dbd3f472d8fd6273643af86e2c394c7af871b264547"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.catchUpStartupChannel (cognitive 43): loadharness.catchUpStartupChannel has cognitive complexity 43 (threshold 15). Drivers by points: if/else 18 (36 pts), loops 2 (3 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":745}}}],"partialFingerprints":{"codehealthFindingId/v1":"5027eb116ec87cdcbe258d272f0b31221b79d4b6c0906e058d74c0f2c9fba864"}},{"ruleId":"D2","level":"warning","message":{"text":"files.parseWebPageMeta (cognitive 42): files.parseWebPageMeta has cognitive complexity 42 (threshold 15). Drivers by points: if/else 7 (25 pts), match/switch 4 (12 pts), jumps 3, boolean chains 1, loops 1 (nesting depth added 26). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/webpage.go"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"28cb02b552ed7e074e45a78a8565d58a56e2235b70fd586aec91c45699f505ab"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.seedEmojiGroupIcons (cognitive 42): Service.seedEmojiGroupIcons has cognitive complexity 42 (threshold 15). Drivers by points: if/else 14 (34 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/emoji_group_icons_seed.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"2589fd7d86a9c3ba78ce7133495246caff94c6c0e2934dde2d584caa4e1c12a9"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.resolveTexts (cognitive 42): Service.resolveTexts has cognitive complexity 42 (threshold 15). Drivers by points: if/else 15 (29 pts), loops 5 (9 pts), boolean chains 3, match/switch 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/service.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"8248db15218b1acd1cfaa606f5832d106f91711bf038823ad8af258ecbcb201b"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.forumTopicsResponse (cognitive 42): Router.forumTopicsResponse has cognitive complexity 42 (threshold 15). Drivers by points: if/else 12 (29 pts), loops 5 (11 pts), boolean chains 2 (nesting depth added 23). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"de1e353852f8379d1d3403c7a7a0300b4778bcbae8312e6a17c40dce7c97d107"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.verifyPasswordRecoveryCode (cognitive 41): Service.verifyPasswordRecoveryCode has cognitive complexity 41 (threshold 15). Drivers by points: if/else 18 (38 pts), boolean chains 2, loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":631}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f5ba8e9947c2d0586a4df6024457c89a75413a535a907d73d84603e70a382f0"}},{"ruleId":"D2","level":"warning","message":{"text":"userprojection.projectBatch (cognitive 41): userprojection.projectBatch has cognitive complexity 41 (threshold 15). Drivers by points: if/else 19 (35 pts), boolean chains 5, loops 1 (nesting depth added 16). Of this number, 25 points are the body\u0027s own statements and 16 belong to 7 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a6a48213d142849cdd2540bfb7ae3bc913f690c1080bd1845d3b49727dba2ba"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.decodeInboundLayerRPCWithOptions (cognitive 41): Server.decodeInboundLayerRPCWithOptions has cognitive complexity 41 (threshold 15). Drivers by points: if/else 24 (34 pts), boolean chains 7 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":994}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8d554eb7caf334ebde3f13c108d58a35a4e9e4c8d6d104638644535074c12dd"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgMessageServiceAction (cognitive 41): rpc.tgMessageServiceAction has cognitive complexity 41 (threshold 15). Drivers by points: if/else 18 (36 pts), boolean chains 4, match/switch 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"c38441c8483eaf0ed106469b38f2a7d6e0547b8b24fa616a694b76f1d30ea2d3"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.storyViewUserIDs (cognitive 41): rpc.storyViewUserIDs has cognitive complexity 41 (threshold 15). Drivers by points: if/else 13 (37 pts), boolean chains 3, loops 1 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_peer_projection.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"313272052e23dc4076fc252317f0a30b01d33a44c3adfc22ea5a27763570098d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.resolveBotCallbackQuery (cognitive 41): Router.resolveBotCallbackQuery has cognitive complexity 41 (threshold 15). Drivers by points: if/else 20 (34 pts), boolean chains 7 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"23c11dafc735f0da55f80780417c6ff00b1ba2d981d434bbc2777b279de05966"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onEditMessageLiveLocation (cognitive 41): Router.onEditMessageLiveLocation has cognitive complexity 41 (threshold 15). Drivers by points: if/else 21 (34 pts), boolean chains 7 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"315e4ac41dbfafe302cc4671014f08812c6e13a49c29b7af80203e74147e78b9"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.forwardSources (cognitive 41): Router.forwardSources has cognitive complexity 41 (threshold 15). Drivers by points: if/else 12 (32 pts), boolean chains 4, loops 2 (4 pts), match/switch 1 (nesting depth added 22). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":617}}}],"partialFingerprints":{"codehealthFindingId/v1":"e685112501785c2c509df093a5e57c7f9d10980c366d59d369d29ae7884557c6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.accountChannelDifferenceNudges (cognitive 41): Router.accountChannelDifferenceNudges has cognitive complexity 41 (threshold 15). Drivers by points: if/else 11 (30 pts), loops 4 (9 pts), boolean chains 2 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/updates.go"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"63343973a6d70524aaf21b92e64f04add0562b95d7ad2635a6757ee5abb01091"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onUsersGetRequirementsToContact (cognitive 41): Router.onUsersGetRequirementsToContact has cognitive complexity 41 (threshold 15). Drivers by points: if/else 14 (24 pts), loops 5 (7 pts), boolean chains 6, match/switch 2 (4 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"51ab2bc51ae5f3d5c842ebf84a5d42f54881957f9c4c95e82b745971a3b08dc1"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelDialogs (cognitive 41): ChannelStore.ListChannelDialogs has cognitive complexity 41 (threshold 15). Drivers by points: if/else 18 (31 pts), boolean chains 5, loops 5 (nesting depth added 13). Of this number, 37 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e9b4d5d79370596cad38bf00a6fb82eb5b2cae0b32742cc841475fe4bd60dbb"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.sendPrivateTextLocked (cognitive 41): MessageStore.sendPrivateTextLocked has cognitive complexity 41 (threshold 15). Drivers by points: if/else 24 (30 pts), loops 4 (6 pts), boolean chains 5 (nesting depth added 8). Of this number, 35 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_send.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4579ff1b1978efd182ea0095f31f454b4b859ecb1af6a25f720f62c8c0f1c49"}},{"ruleId":"D2","level":"warning","message":{"text":"main.main (cognitive 40): main.main has cognitive complexity 40 (threshold 15). Drivers by points: if/else 24 (30 pts), loops 2 (5 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 10). Most of this is not in the body itself: 5 of the 40 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 142, 122). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"f568d096b974f7ee204154525f06fb43940304af9ef97ea16baa2d428ec8327b"}},{"ruleId":"D2","level":"warning","message":{"text":"main.main (cognitive 40): main.main has cognitive complexity 40 (threshold 15). Drivers by points: if/else 20 (29 pts), loops 5 (11 pts) (nesting depth added 15). Most of this is not in the body itself: 4 of the 40 points are its own statements and the rest belongs to one function literal inside it that branches (line 111). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/catalogfetch/main.go"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"420bde45a72944467c73052bb78d016599e3112777b6818a25d9dd27dd6f12e8"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.handleChooseBot (cognitive 40): Service.handleChooseBot has cognitive complexity 40 (threshold 15). Drivers by points: if/else 18 (35 pts), match/switch 2 (3 pts), boolean chains 1, loops 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cdf51e8aabe56aa02e4d63a1d290d360450049ecc50ebe0bc78e956adeadfac"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ReportMessages (cognitive 40): Service.ReportMessages has cognitive complexity 40 (threshold 15). Drivers by points: if/else 11 (27 pts), loops 4 (8 pts), boolean chains 4, match/switch 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"064a01af1615964106c44c111cbd744181cbb8c53e5db0539a915bc0abda301c"}},{"ruleId":"D2","level":"warning","message":{"text":"Projector.ForViewers (cognitive 40): Projector.ForViewers has cognitive complexity 40 (threshold 15). Drivers by points: if/else 13 (27 pts), loops 4 (7 pts), boolean chains 6 (nesting depth added 17). Of this number, 37 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"835485c9c440d3ab8a1fcc2ae18c6022c080ed3e2f6a04e1f68d334bdc4ba6b3"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.apiMessageMedia (cognitive 40): botapi.apiMessageMedia has cognitive complexity 40 (threshold 15). Drivers by points: if/else 16 (34 pts), loops 1 (3 pts), match/switch 2 (3 pts) (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0b28b4e5642d3868e6bfdaa0fe5d77f0c747e632c1048984a64de1c0f644a95"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.forwardMessagesToMonoforum (cognitive 40): Router.forwardMessagesToMonoforum has cognitive complexity 40 (threshold 15). Drivers by points: if/else 20 (30 pts), loops 5 (6 pts), boolean chains 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb7d66d9a1adfc3ec37155774ac2fde2a572e13ed3b44c6bef9d7c6c5e963b83"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSearchGlobal (cognitive 40): Router.onMessagesSearchGlobal has cognitive complexity 40 (threshold 15). Drivers by points: if/else 21 (28 pts), boolean chains 12 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":589}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfc0b6fa6a75e2d5ce2b294dc9b4cd19b97c87507df0aa9bcd328694547312d8"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ReadChannelMessageContents (cognitive 40): ChannelStore.ReadChannelMessageContents has cognitive complexity 40 (threshold 15). Drivers by points: if/else 14 (25 pts), loops 7 (10 pts), boolean chains 5 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e60144045a3bcc3dafca19f5dc7d204f3b59ac98aa424311e67edc49497451a"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ToggleCommunityParticipantBanned (cognitive 40): CommunityStore.ToggleCommunityParticipantBanned has cognitive complexity 40 (threshold 15). Drivers by points: if/else 14 (30 pts), boolean chains 9, loops 1 (nesting depth added 16). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":697}}}],"partialFingerprints":{"codehealthFindingId/v1":"c478cc2388cb998d674d541829cd375996807cb9210fbdf5321385db289ed585"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditChannelBanned (cognitive 40): ChannelStore.EditChannelBanned has cognitive complexity 40 (threshold 15). Drivers by points: if/else 27 (34 pts), boolean chains 5, match/switch 1 (nesting depth added 7). Of this number, 39 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"46a58e72f170b263f1aa97caf498e284f59158dc7a13f08cea39244486d6c3eb"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.PinPrivateMessage (cognitive 40): MessageStore.PinPrivateMessage has cognitive complexity 40 (threshold 15). Drivers by points: if/else 23 (32 pts), boolean chains 7, loops 1 (nesting depth added 9). Of this number, 39 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"da290a136f4ee2162279ab1a9b0b9caeb76644da2c27157664d0d0f2c7a51f8f"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.SetStarGiftListing (cognitive 40): StarGiftLifecycleStore.SetStarGiftListing has cognitive complexity 40 (threshold 15). Drivers by points: if/else 21 (33 pts), boolean chains 6, match/switch 1 (nesting depth added 12). Most of this is not in the body itself: 6 of the 40 points are its own statements and the rest belongs to one function literal inside it that branches (line 325). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3b1b9f4f68d7f60bd76fe9d50f4da4c2bd39104e97bd731018e2f2e787932a8"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.composeStreamWithProviders (cognitive 39): Service.composeStreamWithProviders has cognitive complexity 39 (threshold 15). Drivers by points: if/else 13 (34 pts), boolean chains 4, loops 1 (nesting depth added 21). Of this number, 36 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd67ed449b2bec71ed38e83020f607f125ebd6a618931966c93f4a1b4b9708e5"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ensureStickerMaterialShape (cognitive 39): Service.ensureStickerMaterialShape has cognitive complexity 39 (threshold 15). Drivers by points: if/else 15 (32 pts), boolean chains 3, match/switch 2 (3 pts), loops 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c2671fc82ac2381fec446a4906546139dddcef75581f8bebf4431e5f26bfd2a"}},{"ruleId":"D2","level":"warning","message":{"text":"giftpack.ParseManifest (cognitive 39): giftpack.ParseManifest has cognitive complexity 39 (threshold 15). Drivers by points: if/else 14 (28 pts), loops 4 (8 pts), boolean chains 3 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/giftpack/manifest.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"61bcaed4b6ffff49aa2e5d4e927ae72738e522efc63ee0dacc7283500efbabd1"}},{"ruleId":"D2","level":"warning","message":{"text":"config.validateLoginEmailConfig (cognitive 39): config.validateLoginEmailConfig has cognitive complexity 39 (threshold 15). Drivers by points: if/else 16 (21 pts), boolean chains 13, match/switch 3, loops 1 (2 pts) (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":2023}}}],"partialFingerprints":{"codehealthFindingId/v1":"e62818bc06914dd38ed5c43d5a8d6bd58f02144caf3eab2bae224312d8d7719e"}},{"ruleId":"D2","level":"warning","message":{"text":"rpcExecutionLedger.acquire (cognitive 39): rpcExecutionLedger.acquire has cognitive complexity 39 (threshold 15). Drivers by points: if/else 15 (37 pts), boolean chains 1, loops 1 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_flight.go"},"region":{"startLine":538}}}],"partialFingerprints":{"codehealthFindingId/v1":"d50670325f0784e0145a052952625fecd024cd965a84c0905d94d55d62a7df2b"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.publishRPCResult (cognitive 39): Server.publishRPCResult has cognitive complexity 39 (threshold 15). Drivers by points: if/else 26 (32 pts), boolean chains 7 (nesting depth added 6). Of this number, 20 points are the body\u0027s own statements and 19 belong to 3 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":880}}}],"partialFingerprints":{"codehealthFindingId/v1":"598c871334d96a6ee5fbd81690e80ab45e68ceba153c50d8c1218ba83b56dac9"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onChannelsGetParticipants (cognitive 39): Router.onChannelsGetParticipants has cognitive complexity 39 (threshold 15). Drivers by points: if/else 19 (27 pts), loops 5 (9 pts), boolean chains 3 (nesting depth added 12). Of this number, 37 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"8382bc37d9160e69c03be8d7adbf6eae8c066e709344ce4f5d560feca06836c6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsGetPaymentForm (cognitive 39): Router.onPaymentsGetPaymentForm has cognitive complexity 39 (threshold 15). Drivers by points: if/else 26 (36 pts), boolean chains 2, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c7d45981322a6a7621c529e2cfb1025fed624fd7749d60be2de3bdde6e8eeb3"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.enrichPreparedUpdateEvents (cognitive 39): Router.enrichPreparedUpdateEvents has cognitive complexity 39 (threshold 15). Drivers by points: if/else 13 (25 pts), loops 7 (13 pts), boolean chains 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf5279207a693b6eb1f92426c713e93cba6869954036950d96485a49f15c5a8c"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.resolvePrivateSendReply (cognitive 39): MessageStore.resolvePrivateSendReply has cognitive complexity 39 (threshold 15). Drivers by points: if/else 22 (34 pts), boolean chains 5 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":808}}}],"partialFingerprints":{"codehealthFindingId/v1":"885fc03d9f8563cfa0736f23234d5e681e413707c019c82709e7026d1e12b69b"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.markCraftInputMessageTx (cognitive 39): StarGiftLifecycleStore.markCraftInputMessageTx has cognitive complexity 39 (threshold 15). Drivers by points: if/else 19 (34 pts), boolean chains 4, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_projection.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9d5f3dc1421dce69aa77f99e771daa8c23cf8c80c5dfc8579c52f1aa8ccc72a"}},{"ruleId":"D2","level":"warning","message":{"text":"UpdateEventStore.BatchByCursor (cognitive 39): UpdateEventStore.BatchByCursor has cognitive complexity 39 (threshold 15). Drivers by points: if/else 19 (37 pts), loops 2 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"11717042cff64e6d44cc47cba70f9d22e0741b158137c55041e9150be368ce77"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetInlineBotResults (cognitive 38): Router.onMessagesGetInlineBotResults has cognitive complexity 38 (threshold 15). Drivers by points: if/else 24 (33 pts), boolean chains 5 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"e84d32d3f462f64876830d0e2b5557df36962ae0bc8d2d8ce5e30fad7b88d4db"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.requestedPeerMatches (cognitive 38): Router.requestedPeerMatches has cognitive complexity 38 (threshold 15). Drivers by points: if/else 19 (26 pts), boolean chains 12 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"63af3d71778fd0cb483c0e8c50150e4c74eab1deaa5c6c1833ab7716e08872d1"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSendReaction (cognitive 38): Router.onMessagesSendReaction has cognitive complexity 38 (threshold 15). Drivers by points: if/else 16 (28 pts), boolean chains 8, loops 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_send.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"9877d4822562b30c35a987c346dc81665f345cb9ba1f60411ea08dcb94b645a0"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListDirtyActiveChannelsForUser (cognitive 38): ChannelStore.ListDirtyActiveChannelsForUser has cognitive complexity 38 (threshold 15). Drivers by points: if/else 13 (26 pts), boolean chains 7, loops 3 (5 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"1903299e73b5816b644c36d06b2b61fce54d44aa36a0112bb9c896b69158e367"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SendMonoforumMessage (cognitive 38): ChannelStore.SendMonoforumMessage has cognitive complexity 38 (threshold 15). Drivers by points: if/else 18 (26 pts), boolean chains 9, loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"cce3641d825f3e14148df3496da2e7f7208c5c68847cf0704d410e97302b480c"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupCallStore.RemoveConferenceCallParticipants (cognitive 38): GroupCallStore.RemoveConferenceCallParticipants has cognitive complexity 38 (threshold 15). Drivers by points: if/else 15 (30 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b83bc7bbe5882e517158143666746e08fd48ee91cd17b4ecc5f3f35d496764e"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditExportedInvite (cognitive 38): ChannelStore.EditExportedInvite has cognitive complexity 38 (threshold 15). Drivers by points: if/else 23 (31 pts), boolean chains 7 (nesting depth added 8). Of this number, 37 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1c6bbcdab2ad24e268237c68216c2dce8272e471a3bba208501c31d148e4847"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.ResolveSavedIDs (cognitive 38): StarGiftStore.ResolveSavedIDs has cognitive complexity 38 (threshold 15). Drivers by points: if/else 17 (31 pts), boolean chains 4, loops 3 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":669}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a067814de1e227b1d7ba939077e3b34e5b6c68f8397279239b5366945752170"}},{"ruleId":"D2","level":"warning","message":{"text":"UpdateEventStore.ListAfter (cognitive 38): UpdateEventStore.ListAfter has cognitive complexity 38 (threshold 15). Drivers by points: if/else 19 (37 pts), loops 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"62d77664c05f1519f88b5967f571e6586c645bf5d83e18927ec708ba3020fa24"}},{"ruleId":"D2","level":"warning","message":{"text":"main.run (cognitive 37): main.run has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (25 pts), loops 4 (5 pts), match/switch 2 (5 pts), boolean chains 2 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4aa2ded69d13201c25b1bcb6f9aaf0ba7ef38d79abde5bf9dc2ebf7e802a9ad"}},{"ruleId":"D2","level":"warning","message":{"text":"HTTPProvider.composeOpenAIChatStream (cognitive 37): HTTPProvider.composeOpenAIChatStream has cognitive complexity 37 (threshold 15). Drivers by points: if/else 18 (30 pts), boolean chains 5, loops 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"03e384b716a4e7478ef30c951fca98c708614c7793e02874712a1673a39760c4"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.appendMissingChannelPeerPreviews (cognitive 37): Service.appendMissingChannelPeerPreviews has cognitive complexity 37 (threshold 15). Drivers by points: if/else 15 (28 pts), boolean chains 5, loops 4 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"321d4a31ede2cd7039a9eb0b6334a2c94df275314e76c6a4cb1443072d6ebe8a"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.DeleteBlobBytesForMediaOlderThan (cognitive 37): Service.DeleteBlobBytesForMediaOlderThan has cognitive complexity 37 (threshold 15). Drivers by points: if/else 13 (29 pts), loops 4 (7 pts), boolean chains 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"27f34fabc677e9b72fb693964ef6aa63a620b76165a7897be8c28b3f592b6c96"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.seedStickerSets (cognitive 37): Service.seedStickerSets has cognitive complexity 37 (threshold 15). Drivers by points: if/else 10 (24 pts), loops 6 (12 pts), boolean chains 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bea974314b2faa1a509710d9118bedd24eb325ee4bd050f8dd8ba0cdc29e36e"}},{"ruleId":"D2","level":"warning","message":{"text":"serverMetricsClient.scrape (cognitive 37): serverMetricsClient.scrape has cognitive complexity 37 (threshold 15). Drivers by points: if/else 18 (33 pts), boolean chains 3, loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/server_metrics.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"91a39273f0d0fd2dbef69dd776818cbf28452e4180f2ba0aa36239612df0806d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.savedDialogsProjection (cognitive 37): Router.savedDialogsProjection has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (28 pts), loops 3 (5 pts), boolean chains 3, match/switch 1 (nesting depth added 16). Of this number, 25 points are the body\u0027s own statements and 12 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_saved_dialogs.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"344015dc53ae02f83d83f8402633a9001669113162cdcb2f8aa6e3c7aa65b2dc"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.InviteToChannel (cognitive 37): ChannelStore.InviteToChannel has cognitive complexity 37 (threshold 15). Drivers by points: if/else 13 (32 pts), boolean chains 3, loops 2 (nesting depth added 19). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"2684279fa2a8aee7ff308df600e0e8a1bccb48976fa15c1081bb35e22c0e941c"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.executePlainPrivateSendBatch (cognitive 37): postgres.executePlainPrivateSendBatch has cognitive complexity 37 (threshold 15). Drivers by points: if/else 20 (29 pts), loops 4 (5 pts), boolean chains 3 (nesting depth added 10). Of this number, 36 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_actor.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"72d435c17d0ae9c0a515e7304cb1e639c2d9f222eca18b7500d529ebc0c58616"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.TogglePrivateNoForwards (cognitive 37): MessageStore.TogglePrivateNoForwards has cognitive complexity 37 (threshold 15). Drivers by points: if/else 25 (33 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 9). Most of this is not in the body itself: 10 of the 37 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 85, 183). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_no_forwards.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"b45a6ea73f1a11e7ca80eb8c6e945fd60cdd576f72508974444e2934b0601dba"}},{"ruleId":"D2","level":"warning","message":{"text":"PremiumStore.settlePremiumPayment (cognitive 37): PremiumStore.settlePremiumPayment has cognitive complexity 37 (threshold 15). Drivers by points: if/else 26 (27 pts), boolean chains 10 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7a7449b35729b426d333016feaf9e0e7b935528407c346810437815b4a6ba5b"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.BidStarGiftAuction (cognitive 37): StarGiftLifecycleStore.BidStarGiftAuction has cognitive complexity 37 (threshold 15). Drivers by points: if/else 19 (29 pts), boolean chains 8 (nesting depth added 10). Of this number, 23 points are the body\u0027s own statements and 14 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":994}}}],"partialFingerprints":{"codehealthFindingId/v1":"49950d50ee3334595219729cf467c3af8d5cfc124af9e906795a5fee749bc677"}},{"ruleId":"D2","level":"warning","message":{"text":"dialogs.dialogListForPeer (cognitive 36): dialogs.dialogListForPeer has cognitive complexity 36 (threshold 15). Drivers by points: if/else 8 (22 pts), loops 6 (10 pts), boolean chains 3, match/switch 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0f8527547f68052ea7a430b3d026d710e6349976d4d61655871e18023ce7bff"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.documentsNeedSeedRepair (cognitive 36): Service.documentsNeedSeedRepair has cognitive complexity 36 (threshold 15). Drivers by points: if/else 10 (26 pts), boolean chains 6, loops 3 (4 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":1093}}}],"partialFingerprints":{"codehealthFindingId/v1":"686c193d688a60011e6f652597d89ed0578357307cb6491c0a61f1cec70549a3"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.snapshotDialogsObserved (cognitive 36): loadharness.snapshotDialogsObserved has cognitive complexity 36 (threshold 15). Drivers by points: if/else 16 (29 pts), loops 3, boolean chains 2, match/switch 1 (2 pts) (nesting depth added 14). Of this number, 35 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad6bad30dd36229923eb6c19becd1f605ecc2ceabe92b9d493d7af07f3237051"}},{"ruleId":"D2","level":"warning","message":{"text":"serverExchangeCompat.run (cognitive 36): serverExchangeCompat.run has cognitive complexity 36 (threshold 15). Drivers by points: if/else 31 (33 pts), boolean chains 1, jumps 1, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/exchange_compat.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d1fd46b893c28fcd2dc053daed1864bacba22bb9db1f4195c671aa891c47688"}},{"ruleId":"D2","level":"warning","message":{"text":"inboundRPCBatchReservation.commit (cognitive 36): inboundRPCBatchReservation.commit has cognitive complexity 36 (threshold 15). Drivers by points: if/else 15 (26 pts), boolean chains 5, loops 3 (5 pts) (nesting depth added 13). Most of this is not in the body itself: 6 of the 36 points are its own statements and the rest belongs to one function literal inside it that branches (line 689). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_rpc.go"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa9e2732ebdeacd1b3d8cadf9de41b881f7325c5b38112e46526f0910038491b"}},{"ruleId":"D2","level":"warning","message":{"text":"rpcResultWaiter.subscribe (cognitive 36): rpcResultWaiter.subscribe has cognitive complexity 36 (threshold 15). Drivers by points: if/else 16 (26 pts), boolean chains 8, match/switch 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_flight.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"e56e02244c53eeb72be46a84452fdfe9ac98c397f7b07f5a4fdb8a556dcc01fd"}},{"ruleId":"D2","level":"warning","message":{"text":"BatchedReverseContactStore.run (cognitive 36): BatchedReverseContactStore.run has cognitive complexity 36 (threshold 15). Drivers by points: if/else 6 (17 pts), match/switch 4 (14 pts), loops 2 (3 pts), jumps 2 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"b513df9745a1cf29761a62ea88893d2b766f233cc7cb00c3bd0b510d885ed7c9"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ListCommunityPeerLinkRequests (cognitive 36): CommunityStore.ListCommunityPeerLinkRequests has cognitive complexity 36 (threshold 15). Drivers by points: if/else 15 (28 pts), loops 4 (8 pts) (nesting depth added 17). Of this number, 34 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c5f6d7c731ae5d355f77880834d5500dcf8b4332ad319ae13d54487a260f4f6"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ListByUser (cognitive 36): MessageStore.ListByUser has cognitive complexity 36 (threshold 15). Drivers by points: if/else 21 (31 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eb453754def2b555c7909afaedb9ecde1e64b482ead36d53fd46685818b5a11"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.UnpinAllPrivateMessages (cognitive 36): MessageStore.UnpinAllPrivateMessages has cognitive complexity 36 (threshold 15). Drivers by points: if/else 21 (30 pts), loops 3 (5 pts), boolean chains 1 (nesting depth added 11). Of this number, 35 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"4aea83ba917414756c98675c8ec96749e27d7b32d7a201b0a1ba7911b04f6cf5"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.ListResaleStarGifts (cognitive 36): StarGiftLifecycleStore.ListResaleStarGifts has cognitive complexity 36 (threshold 15). Drivers by points: if/else 19 (23 pts), boolean chains 7, match/switch 2 (4 pts), loops 2 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"ced16fdc248e3245271a0eda1ab3c1062d73af02a5b24934e922985a92bd81ab"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.prepareStarGiftPurchase (cognitive 36): StarGiftLifecycleStore.prepareStarGiftPurchase has cognitive complexity 36 (threshold 15). Drivers by points: if/else 20 (30 pts), boolean chains 6 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d2e0d999c127d69926dbcf12beb2413627bf873e0073e622ef68edae5cf0fe2"}},{"ruleId":"D2","level":"warning","message":{"text":"BatchedReadModelVersionStore.run (cognitive 36): BatchedReadModelVersionStore.run has cognitive complexity 36 (threshold 15). Drivers by points: if/else 6 (17 pts), match/switch 4 (14 pts), loops 2 (3 pts), jumps 2 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/read_model_batch.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"416705f9f3b010a165f162ae77df6abf74a5497f516b7fb51efe9c39af2c79d6"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.WatchChain (cognitive 35): Service.WatchChain has cognitive complexity 35 (threshold 15). Drivers by points: if/else 15 (27 pts), match/switch 2 (4 pts), boolean chains 3, loops 1 (nesting depth added 14). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/watcher.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b639d58cfa702c297fecd027661d3282b707ef248a99dee326fdb774ccf34dc"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.getUpdates (cognitive 35): handler.getUpdates has cognitive complexity 35 (threshold 15). Drivers by points: if/else 22 (32 pts), boolean chains 2, loops 1 (nesting depth added 10). Of this number, 33 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"d12e79913ada0b5466fe36364e7d6e154ff491ee175b074a6655865647fda278"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.handleRPC (cognitive 35): Server.handleRPC has cognitive complexity 35 (threshold 15). Drivers by points: if/else 22 (33 pts), boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":745}}}],"partialFingerprints":{"codehealthFindingId/v1":"22d2e2266f0fe4fc37ae94538886ecbd29b67a3c58217c11565cba5882d84a98"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onChannelsGetFullChannel (cognitive 35): Router.onChannelsGetFullChannel has cognitive complexity 35 (threshold 15). Drivers by points: if/else 20 (33 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd575ca0f4b19f42ea981e971fceb831c8faaf7db07791530be7b024a5670fc5"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.cacheResolvedDurableSessionLayer (cognitive 35): Router.cacheResolvedDurableSessionLayer has cognitive complexity 35 (threshold 15). Drivers by points: if/else 14 (24 pts), boolean chains 9, match/switch 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/durable_layer_evidence.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a815b18c0817d0669127d05fa41b5c01a582bb7486adde9ef3743cec39a8f62"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.DeleteHistory (cognitive 35): MessageStore.DeleteHistory has cognitive complexity 35 (threshold 15). Drivers by points: if/else 14 (22 pts), boolean chains 13 (nesting depth added 8). Of this number, 22 points are the body\u0027s own statements and 13 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a83711dda1045733d78ba0105338a84f1bfbf903e224dd0a40a5546501c454f"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ReadMessageContents (cognitive 35): MessageStore.ReadMessageContents has cognitive complexity 35 (threshold 15). Drivers by points: if/else 13 (23 pts), loops 6 (7 pts), boolean chains 5 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_read.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e07afaeaad6e98a22480518c51638e537a9f4a0f5bcfb051e6cb29b67821cb0"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.JoinChannel (cognitive 35): ChannelStore.JoinChannel has cognitive complexity 35 (threshold 15). Drivers by points: if/else 25 (29 pts), boolean chains 4, match/switch 1 (2 pts) (nesting depth added 5). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"a543a66939c80681954eaa4caeee4ac9f303f2a967989079bcf33ede04f3a428"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.DeliverLoginCodeMessage (cognitive 35): MessageStore.DeliverLoginCodeMessage has cognitive complexity 35 (threshold 15). Drivers by points: if/else 30 (33 pts), boolean chains 2 (nesting depth added 3). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/login_code_delivery.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"279e1fbba9dec6e2c371cc5e381af5ecc1f141b541258125acc4bf635405cbb0"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.SetMessageReactions (cognitive 35): MessageStore.SetMessageReactions has cognitive complexity 35 (threshold 15). Drivers by points: if/else 21 (28 pts), loops 4, boolean chains 3 (nesting depth added 7). Of this number, 34 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb4dcd865e4bb695884566bed0b00fee0e23f82e14e322add56906f98abae6a9"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.PublishCollectibleRevision (cognitive 35): StarGiftStore.PublishCollectibleRevision has cognitive complexity 35 (threshold 15). Drivers by points: if/else 21 (33 pts), loops 2 (nesting depth added 12). Most of this is not in the body itself: 1 of the 35 points is its own statement and the rest belongs to one function literal inside it that branches (line 53). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"34f0efa21004047a32744cdda83241e7b5d7ccb493ffa04650cdd8ae47fb3487"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.ResolveStarGiftOffer (cognitive 35): StarGiftLifecycleStore.ResolveStarGiftOffer has cognitive complexity 35 (threshold 15). Drivers by points: if/else 26 (29 pts), boolean chains 6 (nesting depth added 3). Most of this is not in the body itself: 12 of the 35 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 951, 1019). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":916}}}],"partialFingerprints":{"codehealthFindingId/v1":"2dab57d5d67bde73746b1f22d2a806afaf869a8565c5ca8081c85787f9dbae85"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.hydrateDialogSnapshotPage (cognitive 34): Service.hydrateDialogSnapshotPage has cognitive complexity 34 (threshold 15). Drivers by points: if/else 9 (23 pts), loops 3 (8 pts), boolean chains 3 (nesting depth added 19). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ad4a718a9ab0332a175693347b2656929f787c4a4c7a3be734efd44718f79ee"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.GetFile (cognitive 34): Service.GetFile has cognitive complexity 34 (threshold 15). Drivers by points: if/else 19 (32 pts), boolean chains 2 (nesting depth added 13). Of this number, 21 points are the body\u0027s own statements and 13 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":498}}}],"partialFingerprints":{"codehealthFindingId/v1":"f80739945114bbbcde9704cef0cee680db8c32eb748c3a43277753a9ea1772cb"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.loadMembershipFactsForKeys (cognitive 34): Service.loadMembershipFactsForKeys has cognitive complexity 34 (threshold 15). Drivers by points: if/else 13 (24 pts), loops 5 (7 pts), boolean chains 3 (nesting depth added 13). Of this number, 24 points are the body\u0027s own statements and 10 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service_sparse.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fe1adde9a08a4da409b7c2e0ba256cc8de2bda06e5fd0ae1fe40a3402e21b55"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.apiMessage (cognitive 34): botapi.apiMessage has cognitive complexity 34 (threshold 15). Drivers by points: if/else 18 (23 pts), boolean chains 6, loops 3 (5 pts) (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"e77900060397d0bd41964ee75b95d04ee7ce09f78905da9ad71f1c6f52c9fcf1"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.MutateOffline (cognitive 34): loadharness.MutateOffline has cognitive complexity 34 (threshold 15). Drivers by points: if/else 26 (30 pts), loops 3, boolean chains 1 (nesting depth added 4). Of this number, 22 points are the body\u0027s own statements and 12 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0c58f2d4015dc8c7924938d617c9778cdc84334f41ecce76ad347a6c3b8614a"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.seedGroup (cognitive 34): loadharness.seedGroup has cognitive complexity 34 (threshold 15). Drivers by points: if/else 16 (32 pts), boolean chains 1, loops 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b1351bdb6b856261c531c803706b40b8fefb507d8c42370bfd4940e4cb66487"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgChannelFull (cognitive 34): rpc.tgChannelFull has cognitive complexity 34 (threshold 15). Drivers by points: if/else 27 (29 pts), boolean chains 5 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"fafd37cb7ee58213865d6fd733437c5f1d8c740d946eb76d4c559c663eb4d1bd"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgRequestPeerTypeWithFilter (cognitive 34): rpc.tgRequestPeerTypeWithFilter has cognitive complexity 34 (threshold 15). Drivers by points: if/else 12 (33 pts), match/switch 1 (nesting depth added 21). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":556}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8dd8906429f6d5c4d4732d36ddd6dae6730382ec1cf160f2b45bb8ddef2cec7"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.domainRichMessageFromInput (cognitive 34): Router.domainRichMessageFromInput has cognitive complexity 34 (threshold 15). Drivers by points: if/else 18 (25 pts), boolean chains 6, loops 2, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_rich_message.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"abb78cc2f231615f042f4a04f5ddf420dd0c577c5bf99bcd95f019377e62292e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.editChannelInlineBotMessage (cognitive 34): Router.editChannelInlineBotMessage has cognitive complexity 34 (threshold 15). Drivers by points: if/else 20 (31 pts), boolean chains 3 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"831ae718ae9e69d5aeb06a2168113ea72485e619dc1e14e668a6a3dea59d7350"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.fanoutStoryPrivacyChange (cognitive 34): Router.fanoutStoryPrivacyChange has cognitive complexity 34 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 10, loops 5 (6 pts), match/switch 1 (2 pts) (nesting depth added 7). Of this number, 25 points are the body\u0027s own statements and 9 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2089}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f3963ad207053fd002846e03d85575c6d4477937a25155a164864eedc61a69d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.fanoutDeletedUserStory (cognitive 34): Router.fanoutDeletedUserStory has cognitive complexity 34 (threshold 15). Drivers by points: if/else 14 (18 pts), boolean chains 10, loops 5 (6 pts) (nesting depth added 5). Of this number, 26 points are the body\u0027s own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2178}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec27644a408b885383c80da1ae4662736c07f647c2b65ac06d69e4e58c2d9cac"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteChannelHistory (cognitive 34): ChannelStore.DeleteChannelHistory has cognitive complexity 34 (threshold 15). Drivers by points: if/else 17 (29 pts), boolean chains 4, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"61ad05f7bed1cedeafcc85fd2758c451e4546cf43e254ec60214d5f5fe464d7b"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ForwardPrivateMessages (cognitive 34): MessageStore.ForwardPrivateMessages has cognitive complexity 34 (threshold 15). Drivers by points: if/else 14 (26 pts), boolean chains 4, loops 3 (4 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_forward.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e850face9ddf2241876a2a78485c7085dad7524cc7a1d66a74619c1ce03b360"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.TogglePrivateNoForwards (cognitive 34): MessageStore.TogglePrivateNoForwards has cognitive complexity 34 (threshold 15). Drivers by points: if/else 18 (26 pts), boolean chains 4, loops 1 (2 pts), match/switch 1 (2 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_no_forwards.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"65393c39d263cde811d74b976f419547a1221d87d4f6e3097af696392a04562b"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.ApproveTelegramLoginRequest (cognitive 34): TelegramLoginStore.ApproveTelegramLoginRequest has cognitive complexity 34 (threshold 15). Drivers by points: if/else 20 (25 pts), boolean chains 8, loops 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":346}}}],"partialFingerprints":{"codehealthFindingId/v1":"1395fb1d50f296c54ce1cf6fea678ff19e25ab795535b0ea47db40899e0ba596"}},{"ruleId":"D2","level":"warning","message":{"text":"VerificationStore.ListVerificationApplications (cognitive 34): VerificationStore.ListVerificationApplications has cognitive complexity 34 (threshold 15). Drivers by points: if/else 13 (24 pts), boolean chains 8, loops 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":501}}}],"partialFingerprints":{"codehealthFindingId/v1":"fffbc4dd3bd30f878c81f2f228604f329bd8439d15a004dcca1250f5ad8e4020"}},{"ruleId":"D2","level":"warning","message":{"text":"BatchedAuthKeyStore.run (cognitive 34): BatchedAuthKeyStore.run has cognitive complexity 34 (threshold 15). Drivers by points: match/switch 4 (17 pts), if/else 4 (12 pts), loops 2 (4 pts), jumps 1 (nesting depth added 23). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_get_batch.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"c826917966bf5ba881287c359e449723ed894e694a6824e36182ef2293db2923"}},{"ruleId":"D2","level":"warning","message":{"text":"BatchedAuthKeySessionLayerStore.run (cognitive 34): BatchedAuthKeySessionLayerStore.run has cognitive complexity 34 (threshold 15). Drivers by points: match/switch 4 (17 pts), if/else 4 (12 pts), loops 2 (4 pts), jumps 1 (nesting depth added 23). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_session_layer_batch.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"26882f6aad6d56b52139bd96ebf6686f632de8095c8f7a426be3699c76ca4cda"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.LeaveChannel (cognitive 34): ChannelStore.LeaveChannel has cognitive complexity 34 (threshold 15). Drivers by points: if/else 23 (30 pts), boolean chains 3, loops 1 (nesting depth added 7). Of this number, 33 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"f93eaaccbf36d979f92c24a8e22bd2676609bc54ec43ed47c170aebd072f50e2"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.CreateCatalogRevision (cognitive 34): StarGiftStore.CreateCatalogRevision has cognitive complexity 34 (threshold 15). Drivers by points: if/else 21 (33 pts), boolean chains 1 (nesting depth added 12). Most of this is not in the body itself: 3 of the 34 points are its own statements and the rest belongs to one function literal inside it that branches (line 211). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4ed73e639a4489369e3336d78ac3babd29eb8d8a77ac2072e681aaa3d607586"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftUpgradeStore.loadUpgradeSourceReplay (cognitive 34): StarGiftUpgradeStore.loadUpgradeSourceReplay has cognitive complexity 34 (threshold 15). Drivers by points: if/else 16 (30 pts), boolean chains 3, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":1151}}}],"partialFingerprints":{"codehealthFindingId/v1":"64cf56020d7c159793a4bdd760d4ab546f48bd8b338b72710691190da657e04e"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.verifyLoginCode (cognitive 33): Service.verifyLoginCode has cognitive complexity 33 (threshold 15). Drivers by points: if/else 19 (25 pts), boolean chains 7, match/switch 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1157}}}],"partialFingerprints":{"codehealthFindingId/v1":"78e2957d3469c5bd2f42d73bcd97c00ab7b3582301eaca61a6acef913708c4f5"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.Search (cognitive 33): Service.Search has cognitive complexity 33 (threshold 15). Drivers by points: if/else 13 (22 pts), boolean chains 7, loops 2 (4 pts) (nesting depth added 11). Of this number, 30 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"4accbc7d266d84c31dfed987b3c98ecab43babdc2c9f8c832eebaa44aa86a411"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.editMessageText (cognitive 33): handler.editMessageText has cognitive complexity 33 (threshold 15). Drivers by points: if/else 22 (29 pts), boolean chains 4 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0fa0becfcd1dbdab3e5cf5bfdb07687971908a49b30311ef7a16643ac51785c"}},{"ruleId":"D2","level":"warning","message":{"text":"loadWorker.supervise (cognitive 33): loadWorker.supervise has cognitive complexity 33 (threshold 15). Drivers by points: if/else 5 (16 pts), match/switch 4 (12 pts), loops 2 (3 pts), jumps 2 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"f125f5c9562a2c18c2cf10c377062d2d3d62aa9976e40b8a4490321b9b6a6f17"}},{"ruleId":"D2","level":"warning","message":{"text":"Options.setDefaults (cognitive 33): Options.setDefaults has cognitive complexity 33 (threshold 15). Drivers by points: if/else 32 (33 pts) (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"65aefb2eb996760e27270b66e34d1fad770463b9f7926b42c02ba4bb9e5063fd"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.botAPIRichBlock (cognitive 33): rpc.botAPIRichBlock has cognitive complexity 33 (threshold 15). Drivers by points: if/else 15 (31 pts), boolean chains 1, match/switch 1 (nesting depth added 16). Of this number, 31 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fb3f8347fdb021ae515aa4a2e5201b4a5bba535ccfeb1ee27acbf27d57a4115"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.normalizeOrderedListForClients (cognitive 33): rpc.normalizeOrderedListForClients has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (24 pts), boolean chains 6, match/switch 1 (2 pts), loops 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_rich_message.go"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"abb96f86d3dc79601e6ada8129099256e0261f7fc2aec0a91db627eb62ad9146"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onContactsGetStatuses (cognitive 33): Router.onContactsGetStatuses has cognitive complexity 33 (threshold 15). Drivers by points: if/else 14 (24 pts), loops 3 (4 pts), match/switch 1 (3 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ccd3ce3204f84f952658c31c3ce048bf7770ecc29c019fa9b746a2c91adf4fd"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSendBotRequestedPeer (cognitive 33): Router.onMessagesSendBotRequestedPeer has cognitive complexity 33 (threshold 15). Drivers by points: if/else 22 (28 pts), boolean chains 4, loops 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8a9019b73aa9bf561bbb67c28105088f5120970a292a4d3eba5dcc0530ae2ce"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.messageFilterFromSearchRequest (cognitive 33): Router.messageFilterFromSearchRequest has cognitive complexity 33 (threshold 15). Drivers by points: if/else 16 (26 pts), boolean chains 5, loops 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":834}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbedf706072307928405ef8838f10310e4b0c18da047b0e3307ecdf04819b710"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesToggleNoForwards (cognitive 33): Router.onMessagesToggleNoForwards has cognitive complexity 33 (threshold 15). Drivers by points: if/else 22 (25 pts), boolean chains 8 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_no_forwards.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffc109d84fe8855eb06fbe3862764be1e38f4831dea2ed4641954a4248631571"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.usersForMessageUpdatesWithPreloaded (cognitive 33): Router.usersForMessageUpdatesWithPreloaded has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (21 pts), loops 6 (9 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 14). Of this number, 31 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1045}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b35d41bf55318ada25176bc4970be5fcf1afb50a3e5b1620a56c60911396626"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.resolvePremiumInvoice (cognitive 33): Router.resolvePremiumInvoice has cognitive complexity 33 (threshold 15). Drivers by points: if/else 12 (27 pts), boolean chains 5, match/switch 1 (nesting depth added 15). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_premium.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"34db92626ac386b6def281fab221e75286445554a3c4704ed993d376355d1d19"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ProcessSuggestedPostLifecycle (cognitive 33): ChannelStore.ProcessSuggestedPostLifecycle has cognitive complexity 33 (threshold 15). Drivers by points: if/else 12 (23 pts), boolean chains 7, loops 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_suggested_post.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"a73abdce738dbad0e022d1e4374d6ffec8ad1798f5097d66cb27998a645119d9"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelReplies (cognitive 33): ChannelStore.ListChannelReplies has cognitive complexity 33 (threshold 15). Drivers by points: if/else 14 (22 pts), boolean chains 9, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fb68b667ddf0277d7331ea5bc21d1198b9aa9c0a12a6a1ac20eebc0305b11dc"}},{"ruleId":"D2","level":"warning","message":{"text":"LangPackStore.ReconcileSeed (cognitive 33): LangPackStore.ReconcileSeed has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (23 pts), loops 6, boolean chains 4 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5647ceb568505940724b2f19966326dd1420e92f450dd27791861ee5bc53acd"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ToggleCommunityParticipantBanned (cognitive 33): CommunityStore.ToggleCommunityParticipantBanned has cognitive complexity 33 (threshold 15). Drivers by points: if/else 17 (25 pts), boolean chains 4, loops 4 (nesting depth added 8). None of this is in the body itself: all 33 points belong to one function literal inside it that branches (line 919). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":918}}}],"partialFingerprints":{"codehealthFindingId/v1":"68eee838253bcfd3703e31cb3e03056b200fccea150b07256916f9925ce872fc"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ForwardPrivateMessages (cognitive 33): MessageStore.ForwardPrivateMessages has cognitive complexity 33 (threshold 15). Drivers by points: if/else 17 (27 pts), boolean chains 4, loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"9288ed5b819e1c31e1583c6eaf0202b3661b1fcbc0bf2b5f1500af286d7eaf85"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.PrepayStarGiftUpgrade (cognitive 33): StarGiftLifecycleStore.PrepayStarGiftUpgrade has cognitive complexity 33 (threshold 15). Drivers by points: if/else 22 (26 pts), boolean chains 7 (nesting depth added 4). Of this number, 16 points are the body\u0027s own statements and 17 belong to 3 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_entitlements.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"f756128135e7036240a0034636a6b7fce72403d5ab7f97f90dc15f6a931cb25d"}},{"ruleId":"D2","level":"warning","message":{"text":"main.normalizeSeedJSON (cognitive 32): main.normalizeSeedJSON has cognitive complexity 32 (threshold 15). Drivers by points: if/else 7 (25 pts), loops 3 (6 pts), match/switch 1 (nesting depth added 21). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerseeddeploy/main.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee00cb6fb4f5c17d1a3f1b26e9b196642202c525755a201fef5115a6e7035286"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SendLoginEmailCode (cognitive 32): Service.SendLoginEmailCode has cognitive complexity 32 (threshold 15). Drivers by points: if/else 21 (29 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":765}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f3e5da35aa3af5ab27efd5d82a882fe3104d4fd0da99db148e898a0ddfc7d0e"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.loadBaseUsersByIDs (cognitive 32): Service.loadBaseUsersByIDs has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (21 pts), loops 4 (9 pts), boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":851}}}],"partialFingerprints":{"codehealthFindingId/v1":"aea0dbadf59e9b5f989257ee3dbd6f384a7865c6ba4b9e68e72f7cded016133f"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.candidateStates (cognitive 32): Service.candidateStates has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (22 pts), boolean chains 4, loops 2 (4 pts), match/switch 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":1080}}}],"partialFingerprints":{"codehealthFindingId/v1":"9721f047b864b6eeeca470fd9257f280e10bbbd25ba7d9dd7f5a9cb3d233eb19"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.validateStarGiftAttributes (cognitive 32): domain.validateStarGiftAttributes has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (21 pts), boolean chains 8, match/switch 1 (2 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1285}}}],"partialFingerprints":{"codehealthFindingId/v1":"875b5d36e408f64512f3afa84a62bbcae7792978b5a91a0101958e013cf80935"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.layerRPCDependencies (cognitive 32): Server.layerRPCDependencies has cognitive complexity 32 (threshold 15). Drivers by points: if/else 8 (25 pts), loops 2 (3 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":1279}}}],"partialFingerprints":{"codehealthFindingId/v1":"2599fdb805a9d8ac555f38e5f9b5d9d182683084672737bea1d298c351d45f50"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.BootstrapEnv (cognitive 32): Manager.BootstrapEnv has cognitive complexity 32 (threshold 15). Drivers by points: if/else 19 (29 pts), boolean chains 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/bootstrap.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfce4bdc0a15fdfbcc7c27594acb4257f2a711fb90d38d45da8d41ca86bbb7e6"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.botAPIRichTable (cognitive 32): rpc.botAPIRichTable has cognitive complexity 32 (threshold 15). Drivers by points: if/else 13 (29 pts), loops 2 (3 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f52936c8e87dce01e5402ff1b9d8320296b0237b60462dd620b0650b29e3045"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgMessage (cognitive 32): rpc.tgMessage has cognitive complexity 32 (threshold 15). Drivers by points: if/else 25 (31 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d7f8c0ce6b49ba76ca442ff1e165fa0d6d41ff3dec2f9cccedebf79dd4f8747"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onContactsSetBlocked (cognitive 32): Router.onContactsSetBlocked has cognitive complexity 32 (threshold 15). Drivers by points: if/else 14 (26 pts), loops 4, boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2c410c6d978fb23a7892ccf5975062e1b245dc10409f6080d2acb8e3ade8e2f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesReadDiscussion (cognitive 32): Router.onMessagesReadDiscussion has cognitive complexity 32 (threshold 15). Drivers by points: if/else 20 (31 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c15cf93c9d2ed1623e2392ef7d1df97977078fdfc2e35bbdc3790419cdebfec"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.checkedMessageReadPeer (cognitive 32): Router.checkedMessageReadPeer has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (25 pts), boolean chains 3, loops 1 (3 pts), match/switch 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read_filter.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"37433ff169b4b821bcfc1c47a493b33dc8bb77043403bb2268f566d981d26f0b"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.starGiftRefFromInput (cognitive 32): Router.starGiftRefFromInput has cognitive complexity 32 (threshold 15). Drivers by points: if/else 11 (24 pts), boolean chains 7, match/switch 1 (nesting depth added 13). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1366}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dc2001a178dadb2fffa266b6ad852788e2158734b48e9f099a12be26f13a6f0"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.editSelfParticipant (cognitive 32): Router.editSelfParticipant has cognitive complexity 32 (threshold 15). Drivers by points: if/else 17 (28 pts), boolean chains 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_edit.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe2b7d7ad49e482a4930455880c421f24ed213eacd1c654e6724680e084c7574"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onStatsGetPollStats (cognitive 32): Router.onStatsGetPollStats has cognitive complexity 32 (threshold 15). Drivers by points: if/else 11 (23 pts), boolean chains 5, loops 2 (4 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1b33f8a4b9d7bc0ee857978989b213cc99e669af9e2f3c8f94571f3a40d1bea"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesAcceptURLAuth (cognitive 32): Router.onMessagesAcceptURLAuth has cognitive complexity 32 (threshold 15). Drivers by points: if/else 18 (26 pts), boolean chains 6 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca10491abeb13e04b416101a9a0d883bc69772c67506d03a705530c91a85bc3d"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelDialogs (cognitive 32): ChannelStore.GetChannelDialogs has cognitive complexity 32 (threshold 15). Drivers by points: if/else 11 (25 pts), boolean chains 6, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"e41c2ebfc211186491efa0e7ed05f3fe6f3957832a6641731ab3be3b169ce97f"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.channelMessageRepliesLocked (cognitive 32): ChannelStore.channelMessageRepliesLocked has cognitive complexity 32 (threshold 15). Drivers by points: if/else 13 (24 pts), boolean chains 7, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"70cc82e2d611853ff36cbe18acc164e8375618a9f1b47bda5d4f02578eff1e7f"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ListSavedDialogs (cognitive 32): MessageStore.ListSavedDialogs has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (20 pts), boolean chains 7, loops 4 (5 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fe79915f49675cd0497d65a43ce14e1f68cf812f0c5188189096b1594be454b"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.DeleteExpiredTelegramLoginArtifacts (cognitive 32): TelegramLoginStore.DeleteExpiredTelegramLoginArtifacts has cognitive complexity 32 (threshold 15). Drivers by points: if/else 9 (20 pts), boolean chains 7, loops 3 (5 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":670}}}],"partialFingerprints":{"codehealthFindingId/v1":"4aa83e60feba91f24087668b7331b55fa999be1b57b7996e2a7fb00146aca7bc"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.pollViewerAggregates (cognitive 32): postgres.pollViewerAggregates has cognitive complexity 32 (threshold 15). Drivers by points: if/else 17 (27 pts), loops 4 (5 pts) (nesting depth added 11). Of this number, 31 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/poll.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d8569ab11ae7a87969ddb16e8bf9c32e489b361b717cbcf9fee6c0e3fe8edfd"}},{"ruleId":"D2","level":"warning","message":{"text":"DialogStore.listByUser (cognitive 32): DialogStore.listByUser has cognitive complexity 32 (threshold 15). Drivers by points: if/else 16 (30 pts), loops 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2311d54a37d248b1af0466275362805732b41bc8c83b6e95872e5df3a60c5cd"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.ReviewModerationAppeal (cognitive 32): ModerationReportStore.ReviewModerationAppeal has cognitive complexity 32 (threshold 15). Drivers by points: if/else 24 (27 pts), boolean chains 5 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"49eb24d25487727ba23213e2c6f2020f573b0c95dbf17c166bd3d1bcf180fa69"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.loadCraftReplay (cognitive 32): StarGiftLifecycleStore.loadCraftReplay has cognitive complexity 32 (threshold 15). Drivers by points: if/else 15 (25 pts), boolean chains 6, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":514}}}],"partialFingerprints":{"codehealthFindingId/v1":"a42859799dfd9e3eb9ce3585fc78c972d3afbef32ea9f4bf05e887b83eb6d73e"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.ConvertStarGift (cognitive 32): StarGiftLifecycleStore.ConvertStarGift has cognitive complexity 32 (threshold 15). Drivers by points: if/else 18 (27 pts), boolean chains 4, match/switch 1 (nesting depth added 9). Most of this is not in the body itself: 6 of the 32 points are its own statements and the rest belongs to one function literal inside it that branches (line 79). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"33ef1f2b32b0b4dab3e63787e0213d9b2a46da1f35ce3c4ffd7d2503ea6f8571"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.Configure (cognitive 31): Service.Configure has cognitive complexity 31 (threshold 15). Drivers by points: if/else 31. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":662}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc538d376b0b29f29920d24b7f2cec7fd67ab975e802324c77f96400963bf75d"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SeedPremiumPromo (cognitive 31): Service.SeedPremiumPromo has cognitive complexity 31 (threshold 15). Drivers by points: if/else 21 (28 pts), loops 2, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/premium_promo_seed.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c17fb0c5100ac33f9b98b0ce488b155762bc374ef11f7247aa40f3d6ec6006f"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.seedDocumentJSONsReady (cognitive 31): Service.seedDocumentJSONsReady has cognitive complexity 31 (threshold 15). Drivers by points: if/else 14 (24 pts), loops 4 (5 pts), boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed_state.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd7b794104f51e1b99e9234ff98b05c5c5dbf90dca9ae52f26aa3afcc0fd02cf"}},{"ruleId":"D2","level":"warning","message":{"text":"BatchCache.UsersForView (cognitive 31): BatchCache.UsersForView has cognitive complexity 31 (threshold 15). Drivers by points: if/else 10 (22 pts), loops 4 (8 pts), boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/peerview/cache.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"d348c7698d45a6c11139272143a25368053073756c896136a34b57428d5ece3e"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.ReadEnvGroups (cognitive 31): Manager.ReadEnvGroups has cognitive complexity 31 (threshold 15). Drivers by points: if/else 16 (27 pts), boolean chains 2, loops 2 (nesting depth added 11). Of this number, 24 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/procctl.go"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"993adb5d1bf91fd211e9a954fa4db523d6a3c574a6bf2843bc2db4faf384f4dd"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.Run (cognitive 31): Manager.Run has cognitive complexity 31 (threshold 15). Drivers by points: if/else 10 (17 pts), loops 4 (6 pts), boolean chains 4, jumps 2, match/switch 1 (2 pts) (nesting depth added 10). Of this number, 17 points are the body\u0027s own statements and 14 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"5413410e8fb0cb0028e57640d5103e1bb6411baa965848bc66a07aa434fd7ce6"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgStoryMediaAreas (cognitive 31): rpc.tgStoryMediaAreas has cognitive complexity 31 (threshold 15). Drivers by points: if/else 9 (27 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_stories.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"47f0ca0cbe488ca2e662eef60f7cdcdd82503c6b9e0d6850493d53798bca3197"}},{"ruleId":"D2","level":"warning","message":{"text":"viewerPeerCache.channelsForIDs (cognitive 31): viewerPeerCache.channelsForIDs has cognitive complexity 31 (threshold 15). Drivers by points: if/else 9 (19 pts), loops 5 (11 pts), boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/peer_projection_cache.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d05985abc458ff09cdc3785183f6cb2bede7e83044f0ab2c2abbb06b00aba5f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.webViewBotAppFromInput (cognitive 31): Router.webViewBotAppFromInput has cognitive complexity 31 (threshold 15). Drivers by points: if/else 13 (27 pts), boolean chains 3, match/switch 1 (nesting depth added 14). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"2202d4305e289922e91ad0c04b5c812fdbcb3af099f6bbb0c6de5ff8c737c8ff"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.validateBotAPIUpdateRequest (cognitive 31): memory.validateBotAPIUpdateRequest has cognitive complexity 31 (threshold 15). Drivers by points: if/else 12 (19 pts), boolean chains 11, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ddb6f166fac88d15f1c4312415ce9fd3ae734041a5879b34fd68701ec6c9a52"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.approveInviteImporterLocked (cognitive 31): ChannelStore.approveInviteImporterLocked has cognitive complexity 31 (threshold 15). Drivers by points: if/else 17 (24 pts), boolean chains 7 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":732}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2b70f5925e5682f29fe10cce744ea0e82d63a72e5b270c50eea56852bb06121"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.canonicalizeStoredPhoneIdentitiesInTableTx (cognitive 31): postgres.canonicalizeStoredPhoneIdentitiesInTableTx has cognitive complexity 31 (threshold 15). Drivers by points: if/else 11 (24 pts), loops 3 (6 pts), match/switch 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/phone_identity_migration.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6f62afd87b07dc30c8aee382adb992f641e161319cd374b155dfa05605b3b2a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetParticipants (cognitive 31): ChannelStore.GetParticipants has cognitive complexity 31 (threshold 15). Drivers by points: if/else 17 (25 pts), match/switch 2 (3 pts), boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_list.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a2723af6794d432b71e42778dda6903b2e42fb776c9305da0d7627aae6b6074"}},{"ruleId":"D2","level":"warning","message":{"text":"DialogStore.ListByPeers (cognitive 31): DialogStore.ListByPeers has cognitive complexity 31 (threshold 15). Drivers by points: if/else 13 (28 pts), loops 2, boolean chains 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad6d0404960ebf1361722575284a5f48fa660feba75b2254c782ae7ecbac519e"}},{"ruleId":"D2","level":"warning","message":{"text":"postgresAdmissionController.claimControllerSlotLocked (cognitive 31): postgresAdmissionController.claimControllerSlotLocked has cognitive complexity 31 (threshold 15). Drivers by points: if/else 9 (28 pts), loops 2 (3 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/postgres_connection_admission.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"966391eb895678062f7cdd2082a6a04d67157f605c0e264556806596208c76a8"}},{"ruleId":"D2","level":"warning","message":{"text":"Catalog.validateDesktop (cognitive 31): Catalog.validateDesktop has cognitive complexity 31 (threshold 15). Drivers by points: if/else 9 (27 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/updatecdn/catalog.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"976c87a4ef5d8b7c89076f3754fab73e645345bf2e64025739a54154c882c916"}},{"ruleId":"D2","level":"warning","message":{"text":"main.pythonBytesLiteralToHex (cognitive 30): main.pythonBytesLiteralToHex has cognitive complexity 30 (threshold 15). Drivers by points: if/else 8 (19 pts), loops 2 (5 pts), boolean chains 4, match/switch 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerseeddeploy/main.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"457d22ee162ad8c5ffe5ef3375761fe77b49a8ecf1cae05ed613da2e24c8d2fb"}},{"ruleId":"D2","level":"warning","message":{"text":"main.classify (cognitive 30): main.classify has cognitive complexity 30 (threshold 15). Drivers by points: if/else 9 (21 pts), boolean chains 4, match/switch 3 (4 pts), loops 1 (nesting depth added 13). Most of this is not in the body itself: 8 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 393). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"e23a99bf94676d302166155f826a91d36b783837505a7decfd05f434db8ca750"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.TogglePinned (cognitive 30): Service.TogglePinned has cognitive complexity 30 (threshold 15). Drivers by points: if/else 11 (26 pts), boolean chains 3, match/switch 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":950}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8bdc0a7d01a0a13afad3141e5fbe010d69f613110071c98f2d65f34482c3d61"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.refreshConfirmationsAndCredit (cognitive 30): Service.refreshConfirmationsAndCredit has cognitive complexity 30 (threshold 15). Drivers by points: if/else 14 (27 pts), loops 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/watcher.go"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4b08d98424da11328419f928793dc9c9b77290251d0b7275443339027f9e2d8"}},{"ruleId":"D2","level":"warning","message":{"text":"telegramlogin.LoadSigningKeyRing (cognitive 30): telegramlogin.LoadSigningKeyRing has cognitive complexity 30 (threshold 15). Drivers by points: if/else 13 (24 pts), boolean chains 5, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/keyfiles.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"73bdca2f88b59dca3a3596e977ae8ffa74ae8421e41364fce682579e9e659fa1"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.setWebhook (cognitive 30): handler.setWebhook has cognitive complexity 30 (threshold 15). Drivers by points: if/else 21 (28 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"3282c60f0844812af8ca8c04de472d5ea02521726a161155e7343a0f22cf323d"}},{"ruleId":"D2","level":"warning","message":{"text":"webhookDispatcher.deliver (cognitive 30): webhookDispatcher.deliver has cognitive complexity 30 (threshold 15). Drivers by points: if/else 17 (22 pts), boolean chains 3, loops 3, match/switch 1 (2 pts) (nesting depth added 6). Of this number, 27 points are the body\u0027s own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/webhook.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd4fc3de4db2def2d0e07cf059ffc46801fbfa87562496d693d4afafe30ba753"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.pushToBusinessAuthKey (cognitive 30): SessionManager.pushToBusinessAuthKey has cognitive complexity 30 (threshold 15). Drivers by points: if/else 11 (28 pts), loops 2 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1681}}}],"partialFingerprints":{"codehealthFindingId/v1":"94f086d56943f90f4d119d3235dd5cfbe3b8a15c78df69a2d4145259d6b53e01"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.nudgeBeyondCapChannelMessageAudience (cognitive 30): Router.nudgeBeyondCapChannelMessageAudience has cognitive complexity 30 (threshold 15). Drivers by points: if/else 12 (20 pts), loops 4 (7 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1270}}}],"partialFingerprints":{"codehealthFindingId/v1":"daa49ed641f51eb557f99e76ac4ccc7b3ad85e6e7b2fe3c16f5a1f5f34e680e3"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.channelMessagesUpdatesWithPeerCacheAndUsernames (cognitive 30): Router.channelMessagesUpdatesWithPeerCacheAndUsernames has cognitive complexity 30 (threshold 15). Drivers by points: if/else 13 (26 pts), boolean chains 2, loops 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_updates.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"9300ce85b8d4b016f5962fb61c590b05eb2b5538f2d1dd92676a2b6ad544a4d1"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.fanoutCloseFriendStoryChanges (cognitive 30): Router.fanoutCloseFriendStoryChanges has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (22 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"223a4c624b9af10a7222e97bcdea2f10ac3b2374deb5f749156ed4fb29c0f287"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.applyLayerRPCWrapperEffects (cognitive 30): Router.applyLayerRPCWrapperEffects has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (23 pts), boolean chains 4, match/switch 1 (2 pts), loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_dispatch.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"373df32296eb20aa96729d12da1a1680dee9227a2a859475e89298ce76fb7a32"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetMessageEditData (cognitive 30): Router.onMessagesGetMessageEditData has cognitive complexity 30 (threshold 15). Drivers by points: if/else 13 (23 pts), boolean chains 6, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"122ca1393f7fcbc725dfd2467ba4af79d6cc65779dbc3a17e1d20e23116b25ec"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetSearchCounters (cognitive 30): Router.onMessagesGetSearchCounters has cognitive complexity 30 (threshold 15). Drivers by points: if/else 14 (24 pts), boolean chains 2, loops 2, match/switch 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"436011ba850ee65da835d99908e271eb806dac0e6b114e17836c93b6f1f8d38d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.groupCallScopeFrom (cognitive 30): Router.groupCallScopeFrom has cognitive complexity 30 (threshold 15). Drivers by points: if/else 15 (26 pts), boolean chains 3, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a4523d188ffc5a435a8c7999eeb55b8ba2c2b978ec71963ddd2cd0e4f74768e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.rememberClientInfoAt (cognitive 30): Router.rememberClientInfoAt has cognitive complexity 30 (threshold 15). Drivers by points: if/else 13 (23 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":898}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f03778aba2681c923f24d30d732f5e0812d98b0618d65a54cce26e31d179758"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.rememberClientLayerAt (cognitive 30): Router.rememberClientLayerAt has cognitive complexity 30 (threshold 15). Drivers by points: if/else 19 (24 pts), boolean chains 6 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":992}}}],"partialFingerprints":{"codehealthFindingId/v1":"47a3e18bc3b6dfb2484d3ca5b0d15fa52a3ba4f389c5753553ec4a04d539c082"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onStoriesGetAllStories (cognitive 30): Router.onStoriesGetAllStories has cognitive complexity 30 (threshold 15). Drivers by points: if/else 16 (26 pts), boolean chains 4 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"111c81b9a02e3d288ed23b2559a9f2a0fb9d6306d7deb4db0da59ce8782b4c8c"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SearchPublicPosts (cognitive 30): ChannelStore.SearchPublicPosts has cognitive complexity 30 (threshold 15). Drivers by points: if/else 11 (21 pts), boolean chains 5, loops 3 (4 pts) (nesting depth added 11). Of this number, 28 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b07ab20097b059c060d65c285ab8389c9223cce454f8c92a2c3ee229b713919"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteChannelParticipantReactions (cognitive 30): ChannelStore.DeleteChannelParticipantReactions has cognitive complexity 30 (threshold 15). Drivers by points: if/else 12 (19 pts), loops 5 (6 pts), boolean chains 5 (nesting depth added 8). Of this number, 29 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"2375317056e33eba8189fe40eab5a12c743400ccdcc3a14147c0db07d37783c2"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ReadChannelReactions (cognitive 30): ChannelStore.ReadChannelReactions has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (18 pts), loops 4 (7 pts), boolean chains 5 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"67108e8f1ae8d074e65b2cfc0c5c9b0cdedadd4039a1d3224671e03a105c304b"}},{"ruleId":"D2","level":"warning","message":{"text":"PasswordStore.SaveMusic (cognitive 30): PasswordStore.SaveMusic has cognitive complexity 30 (threshold 15). Drivers by points: if/else 17 (25 pts), loops 4, boolean chains 1 (nesting depth added 8). Most of this is not in the body itself: 2 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 789). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":785}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c9435d28474f81e0f46f325f399ffca5f56a0c6d5673defbaf4168f9d1a11f2"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.TransferChannelOwnership (cognitive 30): ChannelStore.TransferChannelOwnership has cognitive complexity 30 (threshold 15). Drivers by points: if/else 26 (27 pts), boolean chains 3 (nesting depth added 1). Of this number, 29 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"458a9d28f6d6c3a81e66212e0b1a88a67853d024c0442a7de008b2b29921a5dd"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.processSuggestedPostLifecycleOne (cognitive 30): ChannelStore.processSuggestedPostLifecycleOne has cognitive complexity 30 (threshold 15). Drivers by points: if/else 22 (27 pts), boolean chains 3 (nesting depth added 5). Of this number, 29 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9415333dd5002536338345d578a9f4d827e6554987851fc12d9e2e0cd011e02"}},{"ruleId":"D2","level":"warning","message":{"text":"plainPrivateSendBatchActor.run (cognitive 30): plainPrivateSendBatchActor.run has cognitive complexity 30 (threshold 15). Drivers by points: loops 7 (16 pts), if/else 4 (9 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 15). Most of this is not in the body itself: 14 of the 30 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 171, 163). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_actor.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"c79aea2ade2965c0a6dd49ff19570eae63c8cbdf85359bfc63d8287bc4fc5aaa"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.CreateScheduledMessage (cognitive 30): MessageStore.CreateScheduledMessage has cognitive complexity 30 (threshold 15). Drivers by points: if/else 23 (27 pts), boolean chains 3 (nesting depth added 4). Of this number, 29 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"edc2e34ff126e4cd3338e642fddb5f95db270cd864432c82638e74af6eaa39ca"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.SubmitModerationAppealByLink (cognitive 30): ModerationReportStore.SubmitModerationAppealByLink has cognitive complexity 30 (threshold 15). Drivers by points: if/else 21 (24 pts), boolean chains 6 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":533}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d305181bf90a239adefe7721fd2ad00841800d0bbddbcf3e8e2561cfa813d0d"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.PutTelegramLoginAuthorizationCode (cognitive 30): TelegramLoginStore.PutTelegramLoginAuthorizationCode has cognitive complexity 30 (threshold 15). Drivers by points: if/else 19 (25 pts), boolean chains 4, match/switch 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":742}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fbd1a5eeec3244baa058f2da97df3eee88cd384c6013ab45f0115b26f85ce3a"}},{"ruleId":"D2","level":"warning","message":{"text":"bots.serviceBotCommandByteSpans (cognitive 29): bots.serviceBotCommandByteSpans has cognitive complexity 29 (threshold 15). Drivers by points: if/else 7 (21 pts), loops 3 (7 pts), boolean chains 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service_bot_entities.go"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"26b12a4d7e8825e7074799f951b4a13a4329456a5d4ab695566f8fff738e5ff9"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.controls (cognitive 29): Service.controls has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (26 pts), match/switch 2 (3 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1376}}}],"partialFingerprints":{"codehealthFindingId/v1":"04f1bb515e8151d0866e67cb8d6070b4877ec4a552b2f31b40a63bb715f15556"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.getDialogs (cognitive 29): Service.getDialogs has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (25 pts), boolean chains 4 (nesting depth added 13). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"98e34ede8b8cbae991f057643590df1cad5afaf63994563b232dd17fe9b2a58b"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.appearanceSeedReady (cognitive 29): Service.appearanceSeedReady has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (18 pts), loops 7 (9 pts), boolean chains 2 (nesting depth added 8). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"11e592eb3d88d2d554218efb3be970075eb60930592b9ddb5c3a92dc98b008d7"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.CreateCatalogBundle (cognitive 29): Service.CreateCatalogBundle has cognitive complexity 29 (threshold 15). Drivers by points: if/else 15 (22 pts), boolean chains 7 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"d27f737ec3a0be94807247ab95421c52615eaa9a6c6a512fd3efde8019cb84c2"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.exchangeAuthorizationCode (cognitive 29): Service.exchangeAuthorizationCode has cognitive complexity 29 (threshold 15). Drivers by points: if/else 19 (25 pts), boolean chains 4 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":1297}}}],"partialFingerprints":{"codehealthFindingId/v1":"e42cdb97860979420322c0e631a738845913e90ea1e0e77869ef02244d5b6fad"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.sendMedia (cognitive 29): handler.sendMedia has cognitive complexity 29 (threshold 15). Drivers by points: if/else 18 (23 pts), boolean chains 6 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":650}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7e69612b7a93c9156ac06cd2efea661db564913e21e4ac0c35b02b1bfdc9caa"}},{"ruleId":"D2","level":"warning","message":{"text":"DatasetSeedState.Validate (cognitive 29): DatasetSeedState.Validate has cognitive complexity 29 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 10, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"e019f6ddb2bc76f31fcbc871044bb94ff87d79e079aab72dc5b130056c2c875e"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgChannelMessageAction (cognitive 29): rpc.tgChannelMessageAction has cognitive complexity 29 (threshold 15). Drivers by points: if/else 14 (28 pts), match/switch 1 (nesting depth added 14). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"e20496b500d0b9b6abaf8764cb061e4b8526c25f9cca44ff650539280801773c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.currentUserID (cognitive 29): Router.currentUserID has cognitive complexity 29 (threshold 15). Drivers by points: if/else 11 (27 pts), boolean chains 2 (nesting depth added 16). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_auth.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"56937b8348d6f89f8389248d4c17b5c50560794ccb22ae15728518b904c69861"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.mentionedUserIDsFromMessage (cognitive 29): Router.mentionedUserIDsFromMessage has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (25 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 14). Of this number, 27 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":770}}}],"partialFingerprints":{"codehealthFindingId/v1":"71fcb1438c6892bb3eb8bd8573e0e6cf03c90db545e41f36eb3e50bb3aa3ba7c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.withBotProfileFlagsForUsers (cognitive 29): Router.withBotProfileFlagsForUsers has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 5 (11 pts), boolean chains 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":819}}}],"partialFingerprints":{"codehealthFindingId/v1":"7eab9e15e8af482d21b522345d5838e179bd97beee7b2686b344f5ea57817f06"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.resolveChannelReplyLocked (cognitive 29): ChannelStore.resolveChannelReplyLocked has cognitive complexity 29 (threshold 15). Drivers by points: if/else 14 (20 pts), boolean chains 9 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"a15e4a4303c93bcf3f66a53c6d66c4aff3bbc623ad25683af2f2dc7905f37896"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.refreshPrivateReactionDialogSnapshotsLocked (cognitive 29): MessageStore.refreshPrivateReactionDialogSnapshotsLocked has cognitive complexity 29 (threshold 15). Drivers by points: if/else 6 (17 pts), loops 4 (9 pts), boolean chains 3 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"75764db86a725cbc775f720f904ebea14b1de460cca77fd158cf24f3c803ae0c"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.resolveMemoryReplyLocked (cognitive 29): MessageStore.resolveMemoryReplyLocked has cognitive complexity 29 (threshold 15). Drivers by points: if/else 15 (22 pts), boolean chains 5, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_send.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"43a31a1e33f18b997439cd12e9cc79686bd2314d9f2a833e72c382c483ffe155"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.selectPlainPrivateSendBatch (cognitive 29): postgres.selectPlainPrivateSendBatch has cognitive complexity 29 (threshold 15). Drivers by points: if/else 7 (18 pts), loops 4 (8 pts), boolean chains 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_actor.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcd5ef7a0f0cf3108350b5c17f642715c49727fb6329428853c21c404f3c68e6"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.pruneConfirmedUserPrefixTx (cognitive 29): postgres.pruneConfirmedUserPrefixTx has cognitive complexity 29 (threshold 15). Drivers by points: if/else 20 (24 pts), boolean chains 3, loops 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event_retention.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfbfaa9e268fc8a7be37dd5f17de1209446857aa7d2eed9ede3bad66a7e7ff81"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.HydrateChannelDialogSnapshot (cognitive 29): ChannelStore.HydrateChannelDialogSnapshot has cognitive complexity 29 (threshold 15). Drivers by points: if/else 15 (23 pts), boolean chains 3, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":953}}}],"partialFingerprints":{"codehealthFindingId/v1":"20e7b042f2757ed460a25f5754c26d8db99ff67b5a79595066ea4a83b27c8f20"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.approveInviteImporterTx (cognitive 29): ChannelStore.approveInviteImporterTx has cognitive complexity 29 (threshold 15). Drivers by points: if/else 22 (27 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"559e280b3fcbaecebe34f21378dd6d9dea7b5a60b7c11b102eaa3134b59c22df"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.reconcileChannelEditMentionsTx (cognitive 29): ChannelStore.reconcileChannelEditMentionsTx has cognitive complexity 29 (threshold 15). Drivers by points: if/else 14 (22 pts), loops 4, boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":639}}}],"partialFingerprints":{"codehealthFindingId/v1":"89170a88f73bd6ccaf203d6b9918944123b7966265c79910f947ae429fb4b416"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.getChannelMessagesForMember (cognitive 29): ChannelStore.getChannelMessagesForMember has cognitive complexity 29 (threshold 15). Drivers by points: if/else 14 (21 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f954e68ab092ca652faddaeb4fd7cc1438885c168a180d78eb0139541249bad"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelMessageViews (cognitive 29): ChannelStore.GetChannelMessageViews has cognitive complexity 29 (threshold 15). Drivers by points: if/else 15 (24 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_views.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"f891bb084ef31169cb72eccc963c55c33e0fb2a623ffa9083951ef439658d2ec"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteChannelParticipantReactions (cognitive 29): ChannelStore.DeleteChannelParticipantReactions has cognitive complexity 29 (threshold 15). Drivers by points: if/else 18 (24 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 7). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"114ab46dc52aaf392e2f13fa3091fcc38364253d4553560b0ab915d7da56bda2"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ReserveAlbumGroup (cognitive 29): MessageStore.ReserveAlbumGroup has cognitive complexity 29 (threshold 15). Drivers by points: if/else 16 (22 pts), loops 6, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/album_group.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"21f2ce482680a5983706a360e045670760cfbc9a4d1b98b753615d58c5226c4c"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ListSavedDialogs (cognitive 29): MessageStore.ListSavedDialogs has cognitive complexity 29 (threshold 15). Drivers by points: if/else 13 (22 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"83d198ee5e6ef0385de48fbcb6247217da814a2e6d02ffdab685519d808d25c5"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.DeleteSavedHistory (cognitive 29): MessageStore.DeleteSavedHistory has cognitive complexity 29 (threshold 15). Drivers by points: if/else 16 (26 pts), loops 2, boolean chains 1 (nesting depth added 10). Of this number, 28 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"0202042cfda18359031da021a628a694aebd971eaf93b2a14f9f494954820828"}},{"ruleId":"D2","level":"warning","message":{"text":"PremiumStore.UpsertPremiumPlan (cognitive 29): PremiumStore.UpsertPremiumPlan has cognitive complexity 29 (threshold 15). Drivers by points: if/else 16 (25 pts), boolean chains 4 (nesting depth added 9). Most of this is not in the body itself: 5 of the 29 points are its own statements and the rest belongs to one function literal inside it that branches (line 92). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3db51b986a6977f91effedd39f025af0c82d1737b500e3e8ee46c45bace1c21"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.ListByOwnerFiltered (cognitive 29): StarGiftStore.ListByOwnerFiltered has cognitive complexity 29 (threshold 15). Drivers by points: if/else 21 (26 pts), boolean chains 2, loops 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"f324d6eb6360642a2745051588d262808257f1d06105c87ce309fa215a8c867e"}},{"ruleId":"D2","level":"warning","message":{"text":"server.runOperatorCommand (cognitive 28): server.runOperatorCommand has cognitive complexity 28 (threshold 15). Drivers by points: if/else 20 (23 pts), boolean chains 5 (nesting depth added 3). Of this number, 27 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/admin_command_runner.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"2dd255c4107463dd85a578179baaf0dd4c140f62101dc050b503ed7678a69e91"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SetAccountFrozen (cognitive 28): Service.SetAccountFrozen has cognitive complexity 28 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 8 (nesting depth added 5). Most of this is not in the body itself: 13 of the 28 points are its own statements and the rest belongs to one function literal inside it that branches (line 1494). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1473}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e6238abd7104371bd5a535be96253f41e956451e79eb4623c717a84becc24fd"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ChangePhone (cognitive 28): Service.ChangePhone has cognitive complexity 28 (threshold 15). Drivers by points: if/else 16 (19 pts), boolean chains 8, match/switch 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/phone_change.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"66dd71b6707f3cec437682ade580ec7ab4e253e7625fc951c7c8e427f73f22fa"}},{"ruleId":"D2","level":"warning","message":{"text":"dialogs.dialogOwnerSnapshotStructuralHash (cognitive 28): dialogs.dialogOwnerSnapshotStructuralHash has cognitive complexity 28 (threshold 15). Drivers by points: if/else 16 (27 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"76243d5ba2ea2ba88627375fb6f75e11d18200ee934dc4d76a77e8811da0ce10"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ReorderPinned (cognitive 28): Service.ReorderPinned has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (20 pts), loops 2 (6 pts), boolean chains 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":1078}}}],"partialFingerprints":{"codehealthFindingId/v1":"524378ace4b08f7934d1e16c964ce74908d053c39008b1b3099abf4b3518187b"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SendFromClient (cognitive 28): Service.SendFromClient has cognitive complexity 28 (threshold 15). Drivers by points: if/else 15 (21 pts), boolean chains 7 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd9dd5b60cb578c9d3dbbbd38a986a991c8c3888e6b2b19752cddad0ad003a4a"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.DeleteOrphanedOlderThan (cognitive 28): Service.DeleteOrphanedOlderThan has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (20 pts), loops 4 (7 pts), boolean chains 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"060c92c8aef447cb78e537fee6035512ebc81e631d20954a4c875ed093d08523"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SeedMedia (cognitive 28): Service.SeedMedia has cognitive complexity 28 (threshold 15). Drivers by points: if/else 20 (25 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e67aa66bfccd34ca94bcaa6a6bcdb0f833db30979d65cd03811b6ae5c600a2b"}},{"ruleId":"D2","level":"warning","message":{"text":"uploadPartsReader.Read (cognitive 28): uploadPartsReader.Read has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (24 pts), match/switch 1 (3 pts), loops 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":877}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0872f52b5508f9c5dfb6a60ae31877bb1e5ae28560eb5f65c253b4581706405"}},{"ruleId":"D2","level":"warning","message":{"text":"tdesktop.catalogChatThemes (cognitive 28): tdesktop.catalogChatThemes has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (21 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/startup_stubs.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"74f19b8e533ffa561d86cf1c67fad0f4d6d96812065a5bb923027371021590dc"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.SnapshotClientState (cognitive 28): loadharness.SnapshotClientState has cognitive complexity 28 (threshold 15). Drivers by points: if/else 22 (25 pts), loops 3 (nesting depth added 3). Of this number, 24 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"aada44565209f85fcea3894e13a7ab274f247eb761e135eb3bba14b04cf66eb1"}},{"ruleId":"D2","level":"warning","message":{"text":"Conn.sendOutboundWithTerminalReserved (cognitive 28): Conn.sendOutboundWithTerminalReserved has cognitive complexity 28 (threshold 15). Drivers by points: if/else 13 (20 pts), match/switch 3 (5 pts), boolean chains 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1779}}}],"partialFingerprints":{"codehealthFindingId/v1":"988def7365a6d73ad1df6ccb1e3558c539e7981fa051e939ef2cad4013051164"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.OnlineChannelIDsSnapshot (cognitive 28): SessionManager.OnlineChannelIDsSnapshot has cognitive complexity 28 (threshold 15). Drivers by points: if/else 8 (19 pts), loops 4 (6 pts), boolean chains 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2392}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6c5b6df6ecc263f983b6cc024b3a0673c6cde82d24232ad8edc33d4acd16de7"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.WriteEnvValues (cognitive 28): Manager.WriteEnvValues has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (24 pts), boolean chains 3, loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/procctl.go"},"region":{"startLine":478}}}],"partialFingerprints":{"codehealthFindingId/v1":"de4ba0164bad26e2f6a16ce06c93f6189b2b1a7913ccc6cb34c62c9e10117a99"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.cacheBoundAuthKeyLayerResolution (cognitive 28): Router.cacheBoundAuthKeyLayerResolution has cognitive complexity 28 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 9, loops 2, match/switch 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e169f5697db6f99c53d0cfe14061303012d93cf0414616f4a93d3117b88795f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.botAPIQueuedUpdates (cognitive 28): Router.botAPIQueuedUpdates has cognitive complexity 28 (threshold 15). Drivers by points: if/else 16 (26 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"9593d22377030e6ec5564978b376ffdd0cfa0b9d2481ea2f8e75f623c4043589"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onChannelsGetChannels (cognitive 28): Router.onChannelsGetChannels has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 5, loops 4 (5 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"1132b6db673e9288c93d5d997b0c65a8388d9a837207e6293e4613c9fcff4b08"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.DispatchAdmitted (cognitive 28): Router.DispatchAdmitted has cognitive complexity 28 (threshold 15). Drivers by points: if/else 17 (21 pts), boolean chains 7 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_dispatch.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"e95b813078569d319c0bdf13237eda520d93ed935a930016fedeb5b3dae5cd14"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.channelMessagesReactionsUpdates (cognitive 28): Router.channelMessagesReactionsUpdates has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (20 pts), boolean chains 5, loops 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_send.go"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"0514ade30a52c0b5bfef99a5f2d32da6f402ee4a5663ae4d34ff1d7240fed145"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.starGiftAuctionBidTarget (cognitive 28): Router.starGiftAuctionBidTarget has cognitive complexity 28 (threshold 15). Drivers by points: if/else 16 (24 pts), boolean chains 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"99b62ebe5e0e89cdd1385673279c1cc58a3d67d0c46a6aa18a428ee0ca5b31a4"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.validateStarsGiveawayPurpose (cognitive 28): Router.validateStarsGiveawayPurpose has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (19 pts), loops 4 (5 pts), boolean chains 4 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"5360c1bf78a6e414d6714f64dade0b1da4d1033e64781def16679590004e99bb"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.FreezeNegotiatedSessionLayerAt (cognitive 28): Router.FreezeNegotiatedSessionLayerAt has cognitive complexity 28 (threshold 15). Drivers by points: if/else 15 (24 pts), boolean chains 4 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1179}}}],"partialFingerprints":{"codehealthFindingId/v1":"11aa2332b2c688ac722a4d2a589a65934fb3e8f104d2e2a0df84ab4cc68e3855"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.HideAllChatJoinRequests (cognitive 28): ChannelStore.HideAllChatJoinRequests has cognitive complexity 28 (threshold 15). Drivers by points: if/else 14 (23 pts), boolean chains 3, loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":666}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1514b8958501b3666917c683245dc7faacc78d77868eb97ad8b4e98264d2c22"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ListCommunityParticipants (cognitive 28): CommunityStore.ListCommunityParticipants has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 6, loops 4 (5 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":825}}}],"partialFingerprints":{"codehealthFindingId/v1":"56d64e196b9eb3dec8a390af510bfab19c4cae410657d7473d04496fa9bf3473"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.CreateChannel (cognitive 28): ChannelStore.CreateChannel has cognitive complexity 28 (threshold 15). Drivers by points: if/else 20 (23 pts), loops 3, boolean chains 2 (nesting depth added 3). Of this number, 27 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4745d7c322ebf060f27c0cd0e1a81c5c91025bd59cf48f5afd5e37a8a902b4a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelDialogSnapshotHeaders (cognitive 28): ChannelStore.ListChannelDialogSnapshotHeaders has cognitive complexity 28 (threshold 15). Drivers by points: if/else 19 (21 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 3). Of this number, 24 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":293}}}],"partialFingerprints":{"codehealthFindingId/v1":"636ca7ca8c9b4ed5e4532403a062e397ad7ae2af4a22ba62a98567f56cec296f"}},{"ruleId":"D2","level":"warning","message":{"text":"server.storageEnvValues (cognitive 27): server.storageEnvValues has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (21 pts), match/switch 3 (4 pts), boolean chains 2 (nesting depth added 12). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/serverstorage.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"a48775866fa5d498912432fd1eacc6d5a594b4c2480ff0eec0d013e90c4fbcc0"}},{"ruleId":"D2","level":"warning","message":{"text":"main.analyzeHandlers (cognitive 27): main.analyzeHandlers has cognitive complexity 27 (threshold 15). Drivers by points: if/else 8 (17 pts), loops 4 (7 pts), boolean chains 3 (nesting depth added 12). Most of this is not in the body itself: 13 of the 27 points are its own statements and the rest belongs to one function literal inside it that branches (line 261). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"974cfc177b555c3c263c565654d6b1a48f5c1a809dcf3c7e13fe176c6a41d843"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.resolveTone (cognitive 27): Service.resolveTone has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 7, loops 2 (4 pts), match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":574}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd3fc5d33aa6c554b127ecf3c8c5e20914d9fadf64521a915a71ec7ed60b180a"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.handleTelegramLoginConfigurationInput (cognitive 27): Service.handleTelegramLoginConfigurationInput has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (25 pts), loops 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":770}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0aa2816bc14d881c7a4069652305080604f0dcd84f97e6f462cc6991a9aebaa"}},{"ruleId":"D2","level":"warning","message":{"text":"files.inspectMP4Layout (cognitive 27): files.inspectMP4Layout has cognitive complexity 27 (threshold 15). Drivers by points: if/else 8 (19 pts), match/switch 2 (4 pts), boolean chains 3, loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/mp4faststart.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"58b26b3c60568724c22d2e436d129fad051c0e5edcdfde39394d370957d53657"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.apiPoll (cognitive 27): botapi.apiPoll has cognitive complexity 27 (threshold 15). Drivers by points: if/else 15 (23 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":760}}}],"partialFingerprints":{"codehealthFindingId/v1":"017765246db33e0e3aa69d1b39124fc5261b050a4ad834aa776d0b84a550bad1"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.richMessageInputFromAPI (cognitive 27): botapi.richMessageInputFromAPI has cognitive complexity 27 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 7 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/rich_message.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbd94ec3ea1ce7465dbad6754ed518dbc26a1ef8ea04bbec9b55b914e06592d8"}},{"ruleId":"D2","level":"warning","message":{"text":"config.validateVerificationConfig (cognitive 27): config.validateVerificationConfig has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18, boolean chains 9. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1730}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccd590aeac44cfaca28d44d40f20e93b365be95e2564e96f0eba947231ad51ba"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.runStartupAccount (cognitive 27): loadharness.runStartupAccount has cognitive complexity 27 (threshold 15). Drivers by points: if/else 17 (23 pts), boolean chains 3, loops 1 (nesting depth added 6). Most of this is not in the body itself: 8 of the 27 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 461, 447). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6b53b2ee9dcca8b38cdcda2efcd10da2ee2669b3923fefaf2479ffd63c059c8"}},{"ruleId":"D2","level":"warning","message":{"text":"mtprotoedge.preflightInboundItem (cognitive 27): mtprotoedge.preflightInboundItem has cognitive complexity 27 (threshold 15). Drivers by points: if/else 13 (26 pts), match/switch 1 (nesting depth added 13). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":648}}}],"partialFingerprints":{"codehealthFindingId/v1":"8890f2202d00ed9590b84dc44a9578dfa845b09d0bfb0caea7d3c5fb7d9cf18f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesUnpinAllMessages (cognitive 27): Router.onMessagesUnpinAllMessages has cognitive complexity 27 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 7 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"03b4c7814c5f73560dc45201a8593c5a1e2b14085ad9406203a94ea86da79439"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.editPrivateInlineBotMessage (cognitive 27): Router.editPrivateInlineBotMessage has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16 (24 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"54e026085f0fa4c97faa1cda99fc71944c626cfb318451656355d08284207e86"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesReorderPinnedDialogs (cognitive 27): Router.onMessagesReorderPinnedDialogs has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16 (21 pts), boolean chains 5, loops 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":767}}}],"partialFingerprints":{"codehealthFindingId/v1":"3faace5e60f14af7d97e0acc91ddd06e2569a7f5674058a2d5e8b201d92e43a4"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.privateMessagesReactionsUpdates (cognitive 27): Router.privateMessagesReactionsUpdates has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (20 pts), boolean chains 5, loops 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_send.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"0da086d077c0c45ef61150de43e17039cd27a7c247696466330e9eca77901f2d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhoneDeleteConferenceCallParticipants (cognitive 27): Router.onPhoneDeleteConferenceCallParticipants has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16 (21 pts), boolean chains 4, loops 2 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_conference.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c52e207b46f271579bbf90fd376943280f326ecbf57afae4e948ae2dd282528"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.fillUserFullPhotos (cognitive 27): Router.fillUserFullPhotos has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16 (25 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":812}}}],"partialFingerprints":{"codehealthFindingId/v1":"514d12b9107e0662ba1633619fafddb0fd815c105d53d5bca58ac66df92af438"}},{"ruleId":"D2","level":"warning","message":{"text":"BotVerificationStore.ListCustomVerificationRequests (cognitive 27): BotVerificationStore.ListCustomVerificationRequests has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (17 pts), boolean chains 8, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":705}}}],"partialFingerprints":{"codehealthFindingId/v1":"a063ba14e717cf5d0d27ebce6bb4c4f9c8918399f2f2c10680371b054b064541"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListInviteImporters (cognitive 27): ChannelStore.ListInviteImporters has cognitive complexity 27 (threshold 15). Drivers by points: if/else 14 (19 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 6). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"693eae09f126cf18c08979be75f72f0567d116b0d5be861b151fd54400be30a9"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.JoinChannel (cognitive 27): ChannelStore.JoinChannel has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16 (22 pts), boolean chains 5 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"481a9f7e3681f2c8ae3bf6acf71e12526638852ed126f5e80c4ee0701c701b44"}},{"ruleId":"D2","level":"warning","message":{"text":"ContactStore.ContactProjectionForViewers (cognitive 27): ContactStore.ContactProjectionForViewers has cognitive complexity 27 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 4 (5 pts), boolean chains 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"293b8475ae287b1cdb8c5939d7e84a183d0edbecbffaa750b78a4c7ed889fa3c"}},{"ruleId":"D2","level":"warning","message":{"text":"LangPackStore.ListLanguages (cognitive 27): LangPackStore.ListLanguages has cognitive complexity 27 (threshold 15). Drivers by points: if/else 5 (18 pts), loops 3 (4 pts), match/switch 1 (3 pts), boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2a788a0efaffba8f441d903bc98eee1d30118a949b2c36294bd0c68ba516224"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.DeleteSavedHistory (cognitive 27): MessageStore.DeleteSavedHistory has cognitive complexity 27 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 7, loops 2 (3 pts) (nesting depth added 7). Of this number, 19 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"5aafcd43d10cb99be114f48edd682423e4d3c7442a36463a78a3b05a8326fd14"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteChannel (cognitive 27): ChannelStore.DeleteChannel has cognitive complexity 27 (threshold 15). Drivers by points: if/else 17 (24 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 8). Of this number, 26 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cfd06d300a1d3d19f700fa024a4442574b01786ad8f9a62e49c36a31c7b344f"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.deleteChannelMessagesTx (cognitive 27): ChannelStore.deleteChannelMessagesTx has cognitive complexity 27 (threshold 15). Drivers by points: if/else 18 (24 pts), loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":438}}}],"partialFingerprints":{"codehealthFindingId/v1":"91b3e2e826e768f5818092716e69471fb1cb4165ecc3adb8ca296f87b6923a42"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SearchJoinedMessages (cognitive 27): ChannelStore.SearchJoinedMessages has cognitive complexity 27 (threshold 15). Drivers by points: if/else 17 (18 pts), boolean chains 5, loops 2 (3 pts), match/switch 1 (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"94e9d67d3c5a4e3a301154ce48f5790193ace1e1c5ce35c483c5a65aa8cdf419"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListMonoforumDialogs (cognitive 27): ChannelStore.ListMonoforumDialogs has cognitive complexity 27 (threshold 15). Drivers by points: if/else 15 (22 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_monoforum.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"71707897a972f305e9a131dc31f466ea79626939427b93a2d6554c01f25b1023"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.pruneChannelUpdateEvents (cognitive 27): ChannelStore.pruneChannelUpdateEvents has cognitive complexity 27 (threshold 15). Drivers by points: if/else 19 (23 pts), boolean chains 3, loops 1 (nesting depth added 4). Most of this is not in the body itself: 6 of the 27 points are its own statements and the rest belongs to one function literal inside it that branches (line 132). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_update_retention.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"60f53d812c30cba766faeb51dd7a6073fbfb768defd277d4c5f33900178bb6e5"}},{"ruleId":"D2","level":"warning","message":{"text":"StoryStore.populateStoryViewState (cognitive 27): StoryStore.populateStoryViewState has cognitive complexity 27 (threshold 15). Drivers by points: if/else 13 (21 pts), loops 4, boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1906}}}],"partialFingerprints":{"codehealthFindingId/v1":"a75a30c3c3a4827de9444a7df1d8cdab2f84853505d6b52468dac2b0dfd40f48"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.runCommand (cognitive 26): Service.runCommand has cognitive complexity 26 (threshold 15). Drivers by points: if/else 15 (17 pts), boolean chains 5, loops 2 (4 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3933}}}],"partialFingerprints":{"codehealthFindingId/v1":"3660601539c6fcde5487b93efa37a02b19b5bfa1af3d7ec94604767c55b1c104"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.DeleteAccount (cognitive 26): Service.DeleteAccount has cognitive complexity 26 (threshold 15). Drivers by points: if/else 17 (20 pts), boolean chains 6 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"44c65b7aaa3c361b90a1f9a44a8a145bc956f88ddd35b103380c5599cc798380"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ChainBalance (cognitive 26): Service.ChainBalance has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (18 pts), loops 5 (6 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/balance.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b7cea91d3d2be44ae4bf07bf6d9f11e084f5011e6ee2251f7d4d1677f81b4da"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.CreateDocumentFromUpload (cognitive 26): Service.CreateDocumentFromUpload has cognitive complexity 26 (threshold 15). Drivers by points: if/else 17 (23 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0a97901a77ff0e525a7702ee8024e54174f783d6b4685eb86096bfcc76d2641"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.WarmCaches (cognitive 26): Service.WarmCaches has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (16 pts), loops 7 (10 pts) (nesting depth added 9). Of this number, 24 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/warm.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba0ba6b925080e2d1a86ea5e59502b3ae94abd28a1dc96e3a48560b199a47b9"}},{"ruleId":"D2","level":"warning","message":{"text":"telegramlogin.parseWebURL (cognitive 26): telegramlogin.parseWebURL has cognitive complexity 26 (threshold 15). Drivers by points: if/else 14 (20 pts), boolean chains 5, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/url.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"1371ad16d41806a992c206599a36c0b65f2cdc6ba2954a44661100fbe42859d5"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.Translate (cognitive 26): Service.Translate has cognitive complexity 26 (threshold 15). Drivers by points: if/else 13 (21 pts), boolean chains 4, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/service.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca255902773acd6b1b928ff7facb28525011078ae5eebe107470db8f3020aad8"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.messageEntitiesFromAPI (cognitive 26): botapi.messageEntitiesFromAPI has cognitive complexity 26 (threshold 15). Drivers by points: if/else 9 (21 pts), boolean chains 2, match/switch 1 (2 pts), loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"9854ec6ebac9a001a91cbafdb848adb3804719c02c06112194e51b7a25dbb6bd"}},{"ruleId":"D2","level":"warning","message":{"text":"mtprotoedge.closeConnBatch (cognitive 26): mtprotoedge.closeConnBatch has cognitive complexity 26 (threshold 15). Drivers by points: if/else 9 (15 pts), loops 6 (7 pts), match/switch 2 (3 pts), boolean chains 1 (nesting depth added 8). Of this number, 24 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1079}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f5a3e33c2b2a1e33c6959d3a76474c98ec28d63932c5f46c370dddaca47d21f"}},{"ruleId":"D2","level":"warning","message":{"text":"Conn.enqueueEncodedDeliveryReserved (cognitive 26): Conn.enqueueEncodedDeliveryReserved has cognitive complexity 26 (threshold 15). Drivers by points: if/else 15 (23 pts), boolean chains 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1678}}}],"partialFingerprints":{"codehealthFindingId/v1":"d22034b8e0221793aebe57dbe4636dfba977c19a7dd994f671e5fc27bbc87d20"}},{"ruleId":"D2","level":"warning","message":{"text":"Conn.handleOutboundResend (cognitive 26): Conn.handleOutboundResend has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (24 pts), boolean chains 1, loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":2394}}}],"partialFingerprints":{"codehealthFindingId/v1":"6088f75b3e498b75f815cf4afe65b9aeadd8fac4e549119a67fe000dc3f65c68"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.refreshActivatedInheritedLayerProfile (cognitive 26): Server.refreshActivatedInheritedLayerProfile has cognitive complexity 26 (threshold 15). Drivers by points: if/else 13 (25 pts), boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn_layer_profile.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"760fc002dcb9399fd33101178d9523f3340183ed7b4385a0fe135c03f4890e73"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.handleAdmittedLayerRPC (cognitive 26): Server.handleAdmittedLayerRPC has cognitive complexity 26 (threshold 15). Drivers by points: if/else 16 (22 pts), boolean chains 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/layer_rpc_execution.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a4b22e036b1a90a79a79a28a13404388347be274b9bdc372f91e089ff7ce4f4"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgBotInlineResult (cognitive 26): rpc.tgBotInlineResult has cognitive complexity 26 (threshold 15). Drivers by points: if/else 14 (22 pts), boolean chains 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":1088}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5b6f48d83deb0a0213b812dab6fbc91403c1ea9d1fb33d016bafb28fb1436b2"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.domainRequestPeerFilter (cognitive 26): rpc.domainRequestPeerFilter has cognitive complexity 26 (threshold 15). Drivers by points: if/else 12 (24 pts), boolean chains 1, match/switch 1 (nesting depth added 12). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fc90ede6c2b684b1409724c4cbb6c5abb96109627bc2c518962f30357b135f1"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgWebPage (cognitive 26): rpc.tgWebPage has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (25 pts), match/switch 1 (nesting depth added 14). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_media.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"271806804f3df87e7bac18f74ad398af6cd7ef768579d8c223e9481a05c64c37"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.collectChannelMessagePeerRefs (cognitive 26): rpc.collectChannelMessagePeerRefs has cognitive complexity 26 (threshold 15). Drivers by points: if/else 13 (19 pts), loops 3 (6 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":416}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4a510224904c03368072f4de1f56a28be27402ea84d5dc66ffa13f4595e17d9"}},{"ruleId":"D2","level":"warning","message":{"text":"channelFanoutDispatcher.runRecoverySweeps (cognitive 26): channelFanoutDispatcher.runRecoverySweeps has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (19 pts), match/switch 2 (6 pts), loops 1 (nesting depth added 15). Of this number, 25 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":768}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e635480ccfd8582c80650858db18f58082bf81b040c86e05a21a2749b0d4109"}},{"ruleId":"D2","level":"warning","message":{"text":"channelFanoutDispatcher.sweepOnlineChannelRecovery (cognitive 26): channelFanoutDispatcher.sweepOnlineChannelRecovery has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (20 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":823}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a13ef874b42c0adce685f3f1c24ca08234007530398356cded4c94974b232aa"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetChats (cognitive 26): Router.onMessagesGetChats has cognitive complexity 26 (threshold 15). Drivers by points: if/else 9 (20 pts), loops 3 (6 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0f9324c5cf86843703b904950891ed91f6e5dbaf8c6c9fce7835512770b1b6c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.tgChatlistPeerEnvelopeWithChannels (cognitive 26): Router.tgChatlistPeerEnvelopeWithChannels has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (19 pts), loops 2 (4 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/chatlists.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca37bf173e371aa904c0f2cd3dfed758d0d9fcbe3cdddd54e5cbb1cdd622f256"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.preflightVoiceOrRound (cognitive 26): Router.preflightVoiceOrRound has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (18 pts), loops 3 (5 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/privacy_voice.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"9356a97e30acb800a6e27a3faa7886c57b74ceeb7bbf95eee517ed635caa6c2a"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onStoriesSendReaction (cognitive 26): Router.onStoriesSendReaction has cognitive complexity 26 (threshold 15). Drivers by points: if/else 14 (21 pts), boolean chains 5 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2762}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9a764a7a1d012c949c41b0305df353b75dd68f6c2a8390dcb607dcbc9aa0229"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.applyStoryMaxIDsToPeerObjects (cognitive 26): Router.applyStoryMaxIDsToPeerObjects has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (19 pts), loops 4, boolean chains 3 (nesting depth added 8). Of this number, 24 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_peer_projection.go"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb5024841185958d0a619ccb06475452dde9b51b7270aa62682eeeffed28a4ef"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.prepareUpdateEventsForViewer (cognitive 26): Router.prepareUpdateEventsForViewer has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (20 pts), loops 2 (6 pts) (nesting depth added 17). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"a31ad616286c90fdfd56feda94fa883c86552fce4af1aa1d85298a6955a34d3a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.toggleSuggestedPostApprovalLocked (cognitive 26): ChannelStore.toggleSuggestedPostApprovalLocked has cognitive complexity 26 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 8, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_suggested_post.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"55c2b559f1d0a8b968e99621fb3c7657d088200c42cae7ae0be4a785b2f6d31f"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SearchChannelMedia (cognitive 26): ChannelStore.SearchChannelMedia has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (20 pts), boolean chains 5, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b9c7804941213aa44fca05ca1f8f60f23eba99ac8be0ee197351e75b66ef526"}},{"ruleId":"D2","level":"warning","message":{"text":"ContactStore.ContactProjectionForViewerUserIDs (cognitive 26): ContactStore.ContactProjectionForViewerUserIDs has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (18 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ad16e8c8c5d563794078556a2c308d07fd0317eae5d15452ea07217cb4c98bd"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.PinPrivateMessage (cognitive 26): MessageStore.PinPrivateMessage has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 8, loops 3 (4 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9768aca2853e035e2bbe57487d22b7cfd837a9b9f33af545839de0b25ff7a99"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.getModerationCase (cognitive 26): postgres.getModerationCase has cognitive complexity 26 (threshold 15). Drivers by points: if/else 16 (22 pts), loops 4 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1046}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6df642c7fe313c9ba9feccc3b3060928773bae0f3ba88dfcc1eb25552e5d93d"}},{"ruleId":"D2","level":"warning","message":{"text":"AccountLifecycleStore.ExecuteAccountDeletion (cognitive 26): AccountLifecycleStore.ExecuteAccountDeletion has cognitive complexity 26 (threshold 15). Drivers by points: if/else 21 (23 pts), boolean chains 3 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_lifecycle.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e2db90908d51eab6c5b5bd9bf90250b062b2759a372a2601238d8fe10500332"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelMessageReactions (cognitive 26): ChannelStore.ListChannelMessageReactions has cognitive complexity 26 (threshold 15). Drivers by points: if/else 17 (21 pts), boolean chains 4, loops 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":415}}}],"partialFingerprints":{"codehealthFindingId/v1":"c074d370d5cae4b544e3f535aafb56356409c9ba63c35ca275625a8933b70e59"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditForumTopic (cognitive 26): ChannelStore.EditForumTopic has cognitive complexity 26 (threshold 15). Drivers by points: if/else 18 (22 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"09ac7fd0c73becf4d1429c1247cd083a39ce32cfb7779e8143936fcb4513f659"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.enrichPrivateMessageReactions (cognitive 26): MessageStore.enrichPrivateMessageReactions has cognitive complexity 26 (threshold 15). Drivers by points: if/else 13 (20 pts), boolean chains 3, loops 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6ed2e5b4fce8a1daccf3ebd650591c7f213a7babdc2b1944fc461324587c045"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.duplicateSendResult (cognitive 26): MessageStore.duplicateSendResult has cognitive complexity 26 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 6 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":713}}}],"partialFingerprints":{"codehealthFindingId/v1":"629e8c75fc599b58bfb6f0b37c23d8fa605bc5d003fc5482a4726dd32379c08e"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.CompleteModerationAction (cognitive 26): ModerationReportStore.CompleteModerationAction has cognitive complexity 26 (threshold 15). Drivers by points: if/else 16 (23 pts), boolean chains 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":816}}}],"partialFingerprints":{"codehealthFindingId/v1":"a071e6bb47a01f52006eb6eb672858543935f40ddff56a93a32246b2534d2e1f"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.ConsumeTelegramLoginAuthorizationCode (cognitive 26): TelegramLoginStore.ConsumeTelegramLoginAuthorizationCode has cognitive complexity 26 (threshold 15). Drivers by points: if/else 18 (20 pts), boolean chains 6 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":866}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f181c27f4b626714e5159de4d6c6110c5e9bd04d447c5e70ef4e85be5772161"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.ConsumeTelegramLoginDirectToken (cognitive 26): TelegramLoginStore.ConsumeTelegramLoginDirectToken has cognitive complexity 26 (threshold 15). Drivers by points: if/else 18 (20 pts), boolean chains 6 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":936}}}],"partialFingerprints":{"codehealthFindingId/v1":"d13a0aec3a6c5a739e9193179c3a1db7aa8c24a9d297cd7d2eb3ab639d41caae"}},{"ruleId":"D2","level":"warning","message":{"text":"userLaneActor.run (cognitive 26): userLaneActor.run has cognitive complexity 26 (threshold 15). Drivers by points: if/else 5 (14 pts), loops 6 (10 pts), match/switch 1 (2 pts) (nesting depth added 14). Of this number, 13 points are the body\u0027s own statements and 13 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user_lane_actor.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccc970e15820dd07ec8d5c4d1a760485fea450bf1e340079eef6af022141a7b0"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.publicUserPeer (cognitive 26): handler.publicUserPeer has cognitive complexity 26 (threshold 15). Drivers by points: if/else 14 (22 pts), boolean chains 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":746}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7d5f0384d1f2111c278cc67ef75689e7d13c10c4f2eb0bb7f87cfa69e46fc00"}},{"ruleId":"D2","level":"warning","message":{"text":"main.fetchAll (cognitive 25): main.fetchAll has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (22 pts), loops 2 (3 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/langpackfetch/main.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca8369fa86c8d2adacc2fc4d927fa008685ca5f09e076a5c2023273da48a39f0"}},{"ruleId":"D2","level":"warning","message":{"text":"readStore.PeerProfileContent (cognitive 25): readStore.PeerProfileContent has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (19 pts), loops 4 (5 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f30e72e0724e962ee21dc9fa66986553e6dbd73b6846bfa5468a32450c908bb"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.AccountFreezes (cognitive 25): Service.AccountFreezes has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (17 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1372}}}],"partialFingerprints":{"codehealthFindingId/v1":"98ec3f55ef34756a7317330a454954e314a4148743e2fc1760b5e841ffc5e6b6"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.detectBotCommandMessageEntities (cognitive 25): domain.detectBotCommandMessageEntities has cognitive complexity 25 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 8, loops 3 (6 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c35715225ae3ed23ccd34f7abfc91d050b73802884edb47dbfe2608c828d8b1"}},{"ruleId":"D2","level":"warning","message":{"text":"Dataset.Validate (cognitive 25): Dataset.Validate has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c601c144a8057e8be86a062e83af48f814d76cd08749417c0a930c8f6c085db"}},{"ruleId":"D2","level":"warning","message":{"text":"RunConfig.validate (cognitive 25): RunConfig.validate has cognitive complexity 25 (threshold 15). Drivers by points: boolean chains 14, if/else 11. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"90303cc7e20a0c9ef496520faed65159e919d615816bee9486adb22ec8394f26"}},{"ruleId":"D2","level":"warning","message":{"text":"outboundTrackedBudget.waitReserveUntil (cognitive 25): outboundTrackedBudget.waitReserveUntil has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 5, match/switch 1 (2 pts), loops 1 (nesting depth added 8). Of this number, 24 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1269}}}],"partialFingerprints":{"codehealthFindingId/v1":"7304db64a2ea6dc7a44ddb62eb1ff0519f1a7a696f8183d1b7b4a40878fedc20"}},{"ruleId":"D2","level":"warning","message":{"text":"Sender.send (cognitive 25): Sender.send has cognitive complexity 25 (threshold 15). Drivers by points: if/else 20 (25 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/otpdelivery/smtp/sender.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"9397ec881db3f3fa55df73d3596764d68555b678263f486519c1bc1559ee69fa"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.postProcessBotAPIRichHTML (cognitive 25): rpc.postProcessBotAPIRichHTML has cognitive complexity 25 (threshold 15). Drivers by points: if/else 4 (13 pts), loops 3 (10 pts), match/switch 1 (2 pts) (nesting depth added 17). None of this is in the body itself: all 25 points belong to one function literal inside it that branches (line 144). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_message.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ecea962a9775fae66b82769d0906c52251fe671033806ff5f87caeeed573433"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.botAPIQueuedUpdateKind (cognitive 25): rpc.botAPIQueuedUpdateKind has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 6, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"f740bd8f36bf4a8d24450c594f20f306d4e3cbbdf01799e87ea0efb5f71f7875"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.domainChannelReactionPolicy (cognitive 25): rpc.domainChannelReactionPolicy has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (17 pts), match/switch 2 (4 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_read_reactions.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"7374d39242e49bd089e46fa562892d7673e8c79d2199d78120393dd287a1f84b"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgChannel (cognitive 25): rpc.tgChannel has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 5, match/switch 1 (2 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":449}}}],"partialFingerprints":{"codehealthFindingId/v1":"416acb3d2412f7c87a4d82e1d9b89af19ecd28353172780e05d461578cf2f31d"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgRequestedPeers (cognitive 25): rpc.tgRequestedPeers has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (19 pts), boolean chains 2, loops 2, match/switch 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"81dd3374205e3bc052f7e9913ff5129ae4c0066a6389db1a729aaab06a9d7d81"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgForwardMessagesUpdates (cognitive 25): rpc.tgForwardMessagesUpdates has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (23 pts), boolean chains 1, loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":793}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef45ff80d245449a1e93164bf9072c513c725186034426dff24af46627389e5e"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.fileLocationKey (cognitive 25): rpc.fileLocationKey has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (22 pts), boolean chains 2, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/upload.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"640b5999bb4e1e4c1449c11e7ebf7a5b197fb93894893fc585f0286fa1e9fda6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.botAPIQueuedUpdateEvents (cognitive 25): Router.botAPIQueuedUpdateEvents has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (20 pts), loops 2, match/switch 1 (2 pts), boolean chains 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d29e361caaf3a6ed1ef433b49010aada8aecda033f67331f90dabcb6d117b6c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.mentionedUserIDsFromDomainMessage (cognitive 25): Router.mentionedUserIDsFromDomainMessage has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (22 pts), loops 2 (3 pts) (nesting depth added 13). Of this number, 23 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"761d48eac17f40899d115a524fa0d8b09732fde34bf5da4fc52736154d4f5863"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetPollVotes (cognitive 25): Router.onMessagesGetPollVotes has cognitive complexity 25 (threshold 15). Drivers by points: if/else 16 (19 pts), boolean chains 5, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"60b496fa9a8b402a686308520a90eb499d9dc5d52d1504dd5e03bde15df58e36"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.validateTelemetryMessageIDs (cognitive 25): Router.validateTelemetryMessageIDs has cognitive complexity 25 (threshold 15). Drivers by points: if/else 9 (17 pts), loops 3 (5 pts), boolean chains 2, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reports.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"277c5508b734d903b3d43ec4ee80880fd2a636d0a3379de76c40dcd7be8a8dd0"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsCraftStarGift (cognitive 25): Router.onPaymentsCraftStarGift has cognitive complexity 25 (threshold 15). Drivers by points: if/else 12 (20 pts), boolean chains 3, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":792}}}],"partialFingerprints":{"codehealthFindingId/v1":"bedb6740b1ebdb0ee494d33cbf2f297688b6034ae1ba59b7173ca2d5e7772c41"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.effectiveUserID (cognitive 25): Router.effectiveUserID has cognitive complexity 25 (threshold 15). Drivers by points: if/else 13 (24 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c6fe9c97c27b2e0a2928ca7f8eda270c0616e9c030a08c6fd783960257210a6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onUpdatesGetDifference (cognitive 25): Router.onUpdatesGetDifference has cognitive complexity 25 (threshold 15). Drivers by points: if/else 14 (19 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/updates.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f12aba3b97a7331358dbc08619f3cd21812ba72e0283eb271403c8b6291679e"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.channelDialogMatchesFilter (cognitive 25): memory.channelDialogMatchesFilter has cognitive complexity 25 (threshold 15). Drivers by points: if/else 15 (18 pts), boolean chains 7 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"9675adfe550e0566ecdcc93aa89140209db21e6de92afd967051348199a65adb"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.deleteChannelMessagesLocked (cognitive 25): ChannelStore.deleteChannelMessagesLocked has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 4, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"a10a05af4870711cb606b71b5425bfbc8a5d4ffb5969a2152798b1bfac1ca99a"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.derivedMemberLocked (cognitive 25): CommunityStore.derivedMemberLocked has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 3 (7 pts), boolean chains 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"1670b55f8343a27f987c0334d423903ab58a677ecbcc21c38c1e1a945857d2bd"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.insertChannelMessageWithFingerprintTx (cognitive 25): postgres.insertChannelMessageWithFingerprintTx has cognitive complexity 25 (threshold 15). Drivers by points: if/else 21 (24 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":554}}}],"partialFingerprints":{"codehealthFindingId/v1":"c90953db6bcbb367aae0e85f573f91439d0efa43f1e2c97efb9fb9ecc26354b9"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.channelMessageViewReplies (cognitive 25): ChannelStore.channelMessageViewReplies has cognitive complexity 25 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 4, loops 3 (4 pts) (nesting depth added 6). Of this number, 22 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_views.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"c80f9fda641591db13e79bce308bc041c1fcaafee1d56dee3881eb0aedbf1e69"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.creditPeerLifecycleAmount (cognitive 25): StarGiftLifecycleStore.creditPeerLifecycleAmount has cognitive complexity 25 (threshold 15). Drivers by points: if/else 15 (24 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1387}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e825aa0592eaf2777f3df9e51510dd247076f38add990b8e3a2af4bad48adb1"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.token (cognitive 25): Handler.token has cognitive complexity 25 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 5, match/switch 2 (3 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":587}}}],"partialFingerprints":{"codehealthFindingId/v1":"0eb34c1563237eab80cab75a76479be7b8300bca7615e22af117fbc4dfa96906"}},{"ruleId":"D2","level":"warning","message":{"text":"main.documentMedia (cognitive 24): main.documentMedia has cognitive complexity 24 (threshold 15). Drivers by points: if/else 5 (13 pts), boolean chains 6, match/switch 2 (3 pts), loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":781}}}],"partialFingerprints":{"codehealthFindingId/v1":"f78ae78be60e1e8a68a1999b32da611a6489166dff8d37d088e3149c12d123e1"}},{"ruleId":"D2","level":"warning","message":{"text":"files.scanSeedDir (cognitive 24): files.scanSeedDir has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (21 pts), boolean chains 2, loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":574}}}],"partialFingerprints":{"codehealthFindingId/v1":"79811c1c63bfcdcf54483b4950b1292f327de308fc4ce28827b6805720d51f33"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.cloneStickerSetDocument (cognitive 24): Service.cloneStickerSetDocument has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (20 pts), boolean chains 3, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_material.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cb81e84ba0654956d83d112073fd9b706ee4b5d08a5e62042297da45eafc54a"}},{"ruleId":"D2","level":"warning","message":{"text":"langpack.scanSeedCandidates (cognitive 24): langpack.scanSeedCandidates has cognitive complexity 24 (threshold 15). Drivers by points: if/else 13 (18 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 6). Most of this is not in the body itself: 6 of the 24 points are its own statements and the rest belongs to one function literal inside it that branches (line 129). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/seed.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"e926dff4651fab7adec71754fadcb6c5df509e6b6c6e49f2943970cfe5678e71"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.validateBotAPIFormattedText (cognitive 24): botapi.validateBotAPIFormattedText has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 5, loops 4 (5 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"b12e2e7381ff5abc17523fe59382d656a1e7fe220daf34b10b5d0b4b5ceb5429"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.downloadFile (cognitive 24): handler.downloadFile has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (22 pts), boolean chains 1, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b5c190bee2fc49de70aea90bcd20dfb7533cfee343068a12b0a5230f73c62ca"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReport.Validate (cognitive 24): ModerationReport.Validate has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 6, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"60c9d31a12d23ecbbb28813cfd29f2d93246534d4ef5c5fe303570f46c135d0f"}},{"ruleId":"D2","level":"warning","message":{"text":"deliveryTracker.report (cognitive 24): deliveryTracker.report has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3 (4 pts), boolean chains 3, match/switch 1 (3 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/delivery.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"78979e755b95dd062543cf608e87bf7facea4883e08ac8414a4654a5e33b97b3"}},{"ruleId":"D2","level":"warning","message":{"text":"prop.numbers (cognitive 24): prop.numbers has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/lottieraster/lottieraster.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"3861f0e83b5df72e6b0cdd42250ba217660d737aa5814b761e71b66362d8a84b"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.rawURLByteSpans (cognitive 24): rpc.rawURLByteSpans has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (17 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 10). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/webpage_url_extract.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e635c8b5f65207f862e3c733ba280ff7750f6eb74e66d5ebabd6be323ea6f38"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onAccountGetNotifyExceptions (cognitive 24): Router.onAccountGetNotifyExceptions has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 4, match/switch 1 (2 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_notify.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"d51d6dab5dff53ebcaf4a11f452ec58ca9001e387663b6464da0824516dfb6f8"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onContactsDeleteContacts (cognitive 24): Router.onContactsDeleteContacts has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (19 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":792}}}],"partialFingerprints":{"codehealthFindingId/v1":"569c8f1406ff3e8ad63024dfd490d5bca2d181e2bb427ca0c83a8edca849d4ed"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.prepareRPCDispatchContext (cognitive 24): Router.prepareRPCDispatchContext has cognitive complexity 24 (threshold 15). Drivers by points: if/else 16 (23 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/dispatch_context.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"57159f48c178ee3492cb4ffdc90b7772c3dd1004fe8a8ca6fb9a0662148d0670"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.ResolveInheritedAuthKeyLayer (cognitive 24): Router.ResolveInheritedAuthKeyLayer has cognitive complexity 24 (threshold 15). Drivers by points: if/else 14 (20 pts), match/switch 1 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_inheritance.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"2064f25fb060c755fc0c760f3c43387e30b21bfe35ab51624372450c7180fd76"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsConvertStarGift (cognitive 24): Router.onPaymentsConvertStarGift has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (19 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1249}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a21391dadad0dbd8b23fb0a497f2bf2a8973b37bf22ce7df735fde4ec3aaaa2"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhoneJoinGroupCall (cognitive 24): Router.onPhoneJoinGroupCall has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18 (20 pts), boolean chains 4 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"138ee2a3dbeff518da7bf6eed56c6a8fa31e08d6c1edc2c0824ea156a42580f1"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhotosUploadContactProfilePhoto (cognitive 24): Router.onPhotosUploadContactProfilePhoto has cognitive complexity 24 (threshold 15). Drivers by points: if/else 16 (20 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdd4ccf2e270a08b65a45985963d675ee09f8b45ec944395fe12009a0cceb0c8"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onUsersGetFullUser (cognitive 24): Router.onUsersGetFullUser has cognitive complexity 24 (threshold 15). Drivers by points: if/else 18 (23 pts), boolean chains 1 (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6d7a9c1fecf6c60b7f3a1de544c2692fa8185a1eee16f21c5181f6fbc9d04d3"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListAdminLog (cognitive 24): ChannelStore.ListAdminLog has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 6, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"c02b686d179c3651451a01e6997690231a80a42963b9534f5599e557e330a1a5"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.SetMessageReactions (cognitive 24): MessageStore.SetMessageReactions has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 4, loops 3 (4 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd6f8b0126b500fd034ee48814a5bd6a4f54761bfa7fc46f03eccd42fbb45429"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.channelDialogMatchesFilter (cognitive 24): postgres.channelDialogMatchesFilter has cognitive complexity 24 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 7 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":2128}}}],"partialFingerprints":{"codehealthFindingId/v1":"8be7fe54fe67c4ce2bc4507e7d2038b50a54636b1df72a8a544268c85416b753"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ProcessSuggestedPostLifecycle (cognitive 24): ChannelStore.ProcessSuggestedPostLifecycle has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (21 pts), loops 2, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab0260d54d8336942ea19e27940a977f238378205a2ab87732b8a60db5536786"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ReorderCommunityPinned (cognitive 24): CommunityStore.ReorderCommunityPinned has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (20 pts), loops 3, boolean chains 1 (nesting depth added 9). None of this is in the body itself: all 24 points belong to one function literal inside it that branches (line 1310). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1309}}}],"partialFingerprints":{"codehealthFindingId/v1":"02217ed67dbce01b503414a4173d3d0fe2c6153cf9ebda79afdbe762899ac69a"}},{"ruleId":"D2","level":"warning","message":{"text":"PhoneChangeStore.ChangePhone (cognitive 24): PhoneChangeStore.ChangePhone has cognitive complexity 24 (threshold 15). Drivers by points: if/else 16 (22 pts), boolean chains 2 (nesting depth added 6). Of this number, 23 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/phone_change.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"42fef0fe7ee2e09b146471b405ec59216e2bbc5516c12263e8eff43a32610dfc"}},{"ruleId":"D2","level":"warning","message":{"text":"ReadModelChangeListener.flush (cognitive 24): ReadModelChangeListener.flush has cognitive complexity 24 (threshold 15). Drivers by points: if/else 23, boolean chains 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_listener.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a0eba5816ab150e1430f4fb33b0d41e4a5144369f8573ab75726504eecd4dd3"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.loadCraftInputMessageReplays (cognitive 24): StarGiftLifecycleStore.loadCraftInputMessageReplays has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (21 pts), boolean chains 2, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_projection.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"32c621583e7f6f0494c81c11315a4cf3a77e279b6d28b94cb43f51d88bf5c269"}},{"ruleId":"D2","level":"warning","message":{"text":"main.run (cognitive 23): main.run has cognitive complexity 23 (threshold 15). Drivers by points: if/else 14, boolean chains 3, loops 2 (3 pts), match/switch 1 (3 pts) (nesting depth added 3). Of this number, 18 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/blob-migrate/main.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea644a9736a3e54e023d73d834c21260c8733afe4f195821a14dc0629de924ef"}},{"ruleId":"D2","level":"warning","message":{"text":"main.rotateSigning (cognitive 23): main.rotateSigning has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 4, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telegramloginkeygen/main.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"e06255026332a77f6c685c44613451e59b88e07b73db90d067a972766dba4e59"}},{"ruleId":"D2","level":"warning","message":{"text":"readStore.fillPeers (cognitive 23): readStore.fillPeers has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (17 pts), loops 4 (6 pts) (nesting depth added 9). Of this number, 20 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":574}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7c607ffa3b69f46ce0c47e455b08e3f6f8be8d75e20853034b3c43228af25da"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.resendCode (cognitive 23): Service.resendCode has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17 (20 pts), boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":861}}}],"partialFingerprints":{"codehealthFindingId/v1":"87b5ba0a2b630aa2b6e6225d67a6963667a88d50b148faa99e3939e96bdb36ec"}},{"ruleId":"D2","level":"warning","message":{"text":"bots.normalizeStickersBotShortName (cognitive 23): bots.normalizeStickersBotShortName has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (17 pts), boolean chains 3, loops 1 (3 pts) (nesting depth added 13). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":749}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fb8875ce8b20286bccbf94e43ea43f9dd6994b2593485ed9cf66eb752cd9487"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.verifierStatusReply (cognitive 23): Service.verifierStatusReply has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (21 pts), boolean chains 1, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":822}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7c5578d090091a2abf52ee2e0a0be4aeff4d5695b82baa11b42528a95ca82ce"}},{"ruleId":"D2","level":"warning","message":{"text":"giftpack.Import (cognitive 23): giftpack.Import has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (17 pts), loops 4 (5 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/giftpack/import.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"906c6ff3f7e9dedbb631bc7faaeddc34f21110a32daa929a74bf38ba60bdab9a"}},{"ruleId":"D2","level":"warning","message":{"text":"ActionWorker.runOnce (cognitive 23): ActionWorker.runOnce has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (20 pts), boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/actions.go"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"c13e92f816d63b36f68a55e9e73be85b4d2ab9aa5c33107db06db7177dbe6c74"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.RepairDocumentThumbs (cognitive 23): Service.RepairDocumentThumbs has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12 (21 pts), boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/thumb.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"69e36a3ca3c8e69b8d04e15f8d5cdaaaf838d58a002d6e4c82de7bf08d468e40"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.replyKeyboardMarkupFromAPI (cognitive 23): botapi.replyKeyboardMarkupFromAPI has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 2 (3 pts), match/switch 1 (3 pts), boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5d74bc6383e8bf37e1381fff7e0484b24fe2b5afe55ca8372f72ddeeee77e8a"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.seedRichAccountState (cognitive 23): loadharness.seedRichAccountState has cognitive complexity 23 (threshold 15). Drivers by points: if/else 14, boolean chains 9. Most of this is not in the body itself: 2 of the 23 points are its own statements and the rest belongs to one function literal inside it that branches (line 66). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/rich_state.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"d80a38c0275002790db19cd40e021f8bdc72fe8a37a2a08ca7acc1239f8965af"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.startupResponseBytes (cognitive 23): loadharness.startupResponseBytes has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (17 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":928}}}],"partialFingerprints":{"codehealthFindingId/v1":"88503c73fe8c224582f1230166b4fa7bfaaf90a2f20426ef0be653a46780ec64"}},{"ruleId":"D2","level":"warning","message":{"text":"OfflineMutationState.Validate (cognitive 23): OfflineMutationState.Validate has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 8, loops 3 (4 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":584}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fc8f2eb9fd659ee7ffa4a6f0c65a2172b3c7519d890e8d05888b7f8b6185574"}},{"ruleId":"D2","level":"warning","message":{"text":"mtprotoedge.layerRPCAdmissionHasExplicitSelector (cognitive 23): mtprotoedge.layerRPCAdmissionHasExplicitSelector has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (18 pts), boolean chains 2, match/switch 1 (2 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":938}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1eef66faa4f5dc194a18bc72ddbeb93fa7246e534f41ab7d3478365f72eae3f"}},{"ruleId":"D2","level":"warning","message":{"text":"Manager.supervise (cognitive 23): Manager.supervise has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (22 pts), loops 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"331bebb6f74d0e05eb5c8c005d8783dd558753acccf589b32206bfc339aea7af"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.contactNote (cognitive 23): rpc.contactNote has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 4, match/switch 1 (2 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb0bd70b25352365684c97e124ce8d2671492b69379e29e4e039c28e9623a87d"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.newGetMessagesInputTrace (cognitive 23): rpc.newGetMessagesInputTrace has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (20 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_getmessages_trace.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"763ae32451a35cc7a46bf365d5b646fcadc1b3a9a6d9b61aafd10f13dccf03ae"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.extractMentionUsernames (cognitive 23): rpc.extractMentionUsernames has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 5, loops 3 (5 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":828}}}],"partialFingerprints":{"codehealthFindingId/v1":"d135ec514a71b89baf9e6c0aa5a10d883f369c52513e004ba6d393c2acf5e97a"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.botAPIMedia (cognitive 23): Router.botAPIMedia has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (16 pts), match/switch 3 (5 pts), boolean chains 2 (nesting depth added 12). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":721}}}],"partialFingerprints":{"codehealthFindingId/v1":"64cc82cf6ae72a4ab197d3843fbf7fabd44fe9446ff52db9f73f482d63977b08"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.channelFanoutRecipients (cognitive 23): Router.channelFanoutRecipients has cognitive complexity 23 (threshold 15). Drivers by points: if/else 14 (18 pts), boolean chains 2, loops 2, match/switch 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"136dfbf6a0dbca0ffc82a51e94b06645258e120a4e8e91174efbe7bfe2a4f65d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.encryptedStateUpdates (cognitive 23): Router.encryptedStateUpdates has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 2, match/switch 1 (2 pts), loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_messages.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"066039aaca806f2aae4dd8b9d7fb4f1232bac51a219d3d67148ad524bb83f832"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onEphemeralSendMessage (cognitive 23): Router.onEphemeralSendMessage has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17 (18 pts), boolean chains 5 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"2643ecd89060a664ecd435cd691fb3a24e454f483c601d507fdcd4061c49b1db"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.dialogFolderFromTG (cognitive 23): Router.dialogFolderFromTG has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (21 pts), boolean chains 1, match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":1047}}}],"partialFingerprints":{"codehealthFindingId/v1":"842a0bafa221eaeeef160e09b67f262fbf3b1c8883b838351edd677a0cce9e1b"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesToggleStickerSets (cognitive 23): Router.onMessagesToggleStickerSets has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (19 pts), loops 2, match/switch 1 (2 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_sticker_sets.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"be782570c79026288124e5a2117d131e7535064b6b59b0ce0bd5c2659ef00e3e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhoneCreateGroupCall (cognitive 23): Router.onPhoneCreateGroupCall has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16 (17 pts), boolean chains 6 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"bde7a46046aea67d75e03d66eac394dd9788a602edb2d9d01a3a353b18278a50"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhoneCheckGroupCall (cognitive 23): Router.onPhoneCheckGroupCall has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 4 (9 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"aebbae6dcb527cd632ce56b9d0b3c6e2f34308e6d8c6415540f55f5201d36678"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.presenceFanoutCandidates (cognitive 23): Router.presenceFanoutCandidates has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12 (15 pts), loops 2 (6 pts), boolean chains 2 (nesting depth added 7). Of this number, 20 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":1091}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d8f0d2dbba0ef4b5a7435711f85dd342df95b10c8bd526712f64967a7d3a2ab"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.effectiveAuthKeyID (cognitive 23): Router.effectiveAuthKeyID has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12 (21 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"c36577e6ba730edfe0c2758041e9f935df97345baafbba226e696ff5c721a274"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.telegramLoginButtonFromMessage (cognitive 23): Router.telegramLoginButtonFromMessage has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 5, loops 2 (3 pts), match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b0d385b46dab0692a6ad69c7022e455ce2d332c7a32f34fcb56a2abc0d00cb4"}},{"ruleId":"D2","level":"warning","message":{"text":"BotVerificationStore.ListCustomVerifications (cognitive 23): BotVerificationStore.ListCustomVerifications has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 7, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"29717a1679499d290d7f44b88bdc813a7bfde80ae12ffd6d62cf83bf8cafa7ac"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannels (cognitive 23): ChannelStore.GetChannels has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (19 pts), boolean chains 3, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac0f2ffd44eccb8d59f000af96a0ca39b783294ffbd4af9912dbbc38c8be5908"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditExportedInvite (cognitive 23): ChannelStore.EditExportedInvite has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 7 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b55f06d6db75f05dee2cef25c38434b2d6976df4a1b7fd9c07b916bd91aeed6"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditChannelAdmin (cognitive 23): ChannelStore.EditChannelAdmin has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16 (19 pts), boolean chains 4 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8891ad4037d2eed315ed039b72d0b68af6433b6853d37cd200ff48f8db37f0a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditForumTopic (cognitive 23): ChannelStore.EditForumTopic has cognitive complexity 23 (threshold 15). Drivers by points: if/else 16 (19 pts), boolean chains 4 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"331fc4bf0609ccf0fb90697ffa04d5cfb485cab4bc2cb1b7099f9acfb5fb6723"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.DecideAllCommunityPeerLinkRequests (cognitive 23): CommunityStore.DecideAllCommunityPeerLinkRequests has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12 (18 pts), loops 4, boolean chains 1 (nesting depth added 6). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":590}}}],"partialFingerprints":{"codehealthFindingId/v1":"c201922e2712876ee3eaa36bec025bf7db0a7c22cb56510bc729536c22138a3c"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.allParticipantsLocked (cognitive 23): CommunityStore.allParticipantsLocked has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 4 (7 pts) (nesting depth added 12). Of this number, 20 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":783}}}],"partialFingerprints":{"codehealthFindingId/v1":"185647e51acf8100256183560bdc99a5844933d95001021e5a54b630411683e2"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.UpsertSavedReactionTag (cognitive 23): MessageStore.UpsertSavedReactionTag has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_saved_reactions.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"d28e78631e2dcff395e63763c7a055e5d4610a7f6f51aa312e941a2369c96a87"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.validateBotAPIUpdateRequest (cognitive 23): postgres.validateBotAPIUpdateRequest has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 7, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":684}}}],"partialFingerprints":{"codehealthFindingId/v1":"4de0eb2436f6169d0ffc76473e5e51248ccda0a092b026bed81b22c3299672e3"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.cloneChannelTopMessage (cognitive 23): postgres.cloneChannelTopMessage has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (13 pts), loops 3 (10 pts) (nesting depth added 10). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_top_message_cache.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"19f5dc44c8189498cae19e2a9e33c564457bfe88fdba8758a4a2be160ca5cfd2"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ApplyPremiumBoost (cognitive 23): ChannelStore.ApplyPremiumBoost has cognitive complexity 23 (threshold 15). Drivers by points: if/else 14 (21 pts), boolean chains 1, loops 1 (nesting depth added 7). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"3000fd28502e13822ae2d26d13d4fe219bd954f7d93046dc61a1328e60052857"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ReadChannelMessageContents (cognitive 23): ChannelStore.ReadChannelMessageContents has cognitive complexity 23 (threshold 15). Drivers by points: if/else 18 (20 pts), loops 2, boolean chains 1 (nesting depth added 2). Of this number, 22 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"90b39d6a36019b0a3f12b818610663487aa0472d62428dbdabefd78f99c0d2dc"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelMessageStats (cognitive 23): ChannelStore.GetChannelMessageStats has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (18 pts), boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":336}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0726c372ee519c9e43d4e13f1415754d2df1261e11e6d88a4ace4acbe1abf9b"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelReplies (cognitive 23): ChannelStore.ListChannelReplies has cognitive complexity 23 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 6 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":588}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1daf608f79d5bf715161debdbd5312dd6bfa1d1b92565610947c5aa51db347d"}},{"ruleId":"D2","level":"warning","message":{"text":"CollectibleUsernameStore.MintCollectibleUsername (cognitive 23): CollectibleUsernameStore.MintCollectibleUsername has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17 (21 pts), boolean chains 1, match/switch 1 (nesting depth added 4). Most of this is not in the body itself: 4 of the 23 points are its own statements and the rest belongs to one function literal inside it that branches (line 196). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"766e697222c96d4cc78b40421fc455778b41b4c7644b49d753e80ce59e723bec"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.DecideModerationCase (cognitive 23): ModerationReportStore.DecideModerationCase has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17 (18 pts), boolean chains 5 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb4f9397aeb92eb6b1e60b919d61177e1dac29c805b920684c6c45502586bc5c"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.UpdateCollection (cognitive 23): StarGiftStore.UpdateCollection has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (18 pts), loops 3, boolean chains 2 (nesting depth added 5). None of this is in the body itself: all 23 points belong to one function literal inside it that branches (line 664). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":662}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ed28852c09aa56d0f916eb3d538012a9cbe1962e7240b7a7249fb6630c5a18b"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.CompleteStarGiftWithdrawal (cognitive 23): StarGiftLifecycleStore.CompleteStarGiftWithdrawal has cognitive complexity 23 (threshold 15). Drivers by points: if/else 17 (18 pts), boolean chains 5 (nesting depth added 1). Most of this is not in the body itself: 6 of the 23 points are its own statements and the rest belongs to one function literal inside it that branches (line 1602). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1596}}}],"partialFingerprints":{"codehealthFindingId/v1":"9482cb204dc2c836895b75948cb491dd7daa08fc9803b0920b049bbc67ddbdb7"}},{"ruleId":"D2","level":"warning","message":{"text":"main.fetchSet (cognitive 22): main.fetchSet has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13 (19 pts), loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerfetch/main.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"35e7220d97cb064a90f6f07bebec3744c0d1222087e992c5f68e386917ba44fd"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SendChangePhoneCode (cognitive 22): Service.SendChangePhoneCode has cognitive complexity 22 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/phone_change.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3909fd0486ceb868712da19641cfbcfbdf2682c6f3c4d0b2cfd8e794e6a3ede"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.handleStickers (cognitive 22): Service.handleStickers has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (19 pts), match/switch 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"f220861d71b4170c01a50452b456202705e64fe36c032f4c3d649356a1130fa0"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.PrivateDialogPeerIDs (cognitive 22): Service.PrivateDialogPeerIDs has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"120c2baa7ee20629def0bd5f54fa1148e6f63f3aba72add96c010b6f16cf9293"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.editFieldsFromBot (cognitive 22): Service.editFieldsFromBot has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 5, match/switch 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ee5204add7056797c986b77a2c6b030a1c7ed1f66677950ee2e7d3df5609774"}},{"ruleId":"D2","level":"warning","message":{"text":"files.faststartMP4 (cognitive 22): files.faststartMP4 has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 2, loops 2, match/switch 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/mp4faststart.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"1856f9d20fd54c7e2574539ae2a9d91d725d6d479d9c32592a06a000bfc353a9"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.EnsureDefaultEmojiStatusSet (cognitive 22): Service.EnsureDefaultEmojiStatusSet has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (16 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/default_statuses.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"643335ea1d536627a345b40e46f414241b8517f2eb963991a1e9a7d2c352d5f4"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SeedGifs (cognitive 22): Service.SeedGifs has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (17 pts), loops 2, match/switch 1 (2 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_seed.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"29d5ac9d899a9d0566fbc0b968b2b165a2f12da05a741da27e9bb64cbe5d978e"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SeedDirectory (cognitive 22): Service.SeedDirectory has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (17 pts), loops 3, boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/seed.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d81c5f9cdd415f85cf9df7b78983dec9120c11ec3868a4e1e8b96d2a7d430df"}},{"ruleId":"D2","level":"warning","message":{"text":"CachedContactStore.personalPhotoSnapshot (cognitive 22): CachedContactStore.personalPhotoSnapshot has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (19 pts), loops 2 (3 pts) (nesting depth added 11). Most of this is not in the body itself: 9 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 711). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":706}}}],"partialFingerprints":{"codehealthFindingId/v1":"e469e7152dd22f859769756152abe733997d5b8c9ef27be94920a816db3ab9f6"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.parseEphemeralSendTarget (cognitive 22): botapi.parseEphemeralSendTarget has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 7 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e0ca20716091f147065e560ed919d892d0b488f66d7b031bbbf0fed7564e65"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftCatalogWrite.ValidateLifecycleAuthoring (cognitive 22): StarGiftCatalogWrite.ValidateLifecycleAuthoring has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 4 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":931}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4a6b04687e5eef3c7b4775cbf2a8d631df415ee0faca1d9eddea93ff088d1e7"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.prepareDownloadFixture (cognitive 22): loadharness.prepareDownloadFixture has cognitive complexity 22 (threshold 15). Drivers by points: if/else 16 (19 pts), loops 2, boolean chains 1 (nesting depth added 3). Most of this is not in the body itself: 5 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 607). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":592}}}],"partialFingerprints":{"codehealthFindingId/v1":"61a9993aa9f89ae9e68d53cf0ed7aa3707d56c3d7a25009459feccd4f59e3f43"}},{"ruleId":"D2","level":"warning","message":{"text":"loadWorker.runClient (cognitive 22): loadWorker.runClient has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (12 pts), match/switch 3 (6 pts), boolean chains 3, loops 1 (nesting depth added 5). Most of this is not in the body itself: 1 of the 22 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 333, 299). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":290}}}],"partialFingerprints":{"codehealthFindingId/v1":"e17edf684312dd55d4fbfde2f8836cefd9e7780154d2cceaf87b89730dbe86b0"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgMessageReplyHeader (cognitive 22): rpc.tgMessageReplyHeader has cognitive complexity 22 (threshold 15). Drivers by points: if/else 14 (19 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e1ce8d2ff9877ba8fa314fe4ed4e6a50939992455d53a03dc77d36048762c36"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgChannelUpdate (cognitive 22): rpc.tgChannelUpdate has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (20 pts), boolean chains 1, match/switch 1 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"3977d2bddc48917dfd8db2b0e3f712fc2722b48c4f0f2838b997240b8180db77"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.augmentAutoEntities (cognitive 22): rpc.augmentAutoEntities has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (15 pts), loops 5, boolean chains 2 (nesting depth added 5). Of this number, 15 points are the body\u0027s own statements and 7 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/message_entities_autodetect.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf6b2cf9b858ea7315edc2efad836d51eeea2b29d25716dda7d5702360e1befc"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetBotCallbackAnswer (cognitive 22): Router.onMessagesGetBotCallbackAnswer has cognitive complexity 22 (threshold 15). Drivers by points: if/else 17 (20 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"a62805e5c79bb840edc53f5477ccf6e90900f80f7032adce090223cc29683771"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.runChannelFanoutJob (cognitive 22): Router.runChannelFanoutJob has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 4, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":877}}}],"partialFingerprints":{"codehealthFindingId/v1":"31d85b97c78cc1fa41ac23b29f84a3d75bf163fd7509e8c91dcc25787b193208"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onContactsImportContacts (cognitive 22): Router.onContactsImportContacts has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (18 pts), loops 4 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"556ae8ce6fb9ab0c0e7dcead792ac7d2add07d5ba22172bff5572f92b6344c48"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.NotifyUserModerationFlagsChanged (cognitive 22): Router.NotifyUserModerationFlagsChanged has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/premium_sweeper.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"a003a95f8d863237859efc2b3338f0653d24027e4299fdd41d8bbaee60b0a2a3"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.domainWelcomeEditFields (cognitive 22): Router.domainWelcomeEditFields has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13 (19 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/welcome_messages.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ee7e12e641eb8fb2113ce751bf3e2875aa08f5a4961c30fc5ecb14bc65ad261"}},{"ruleId":"D2","level":"warning","message":{"text":"pionSFU.livenessLoop (cognitive 22): pionSFU.livenessLoop has cognitive complexity 22 (threshold 15). Drivers by points: loops 4 (11 pts), if/else 2 (8 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 14). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"1081d2faa825c3e34ddfa0499ecc79c90ba6833c9f8c8facacb7cfefb76066fc"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SearchPublicChannels (cognitive 22): ChannelStore.SearchPublicChannels has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 5, loops 2 (nesting depth added 4). Of this number, 19 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce90f7b0e073eeefcc345307b94988d37c6bc5859d632df5fdc2ccce0aaf7cf8"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetParticipants (cognitive 22): ChannelStore.GetParticipants has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 4, match/switch 1 (2 pts), loops 1 (nesting depth added 4). Of this number, 21 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"1492ab7c101fff0685cb971fbb5fde6c92a45715de907fc7263c369e73805eea"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditChannelBanned (cognitive 22): ChannelStore.EditChannelBanned has cognitive complexity 22 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 4, match/switch 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"2381d291a9c23409346bebdac406b88c3097a6bd002838a0d900a98024930a28"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelMessages (cognitive 22): ChannelStore.GetChannelMessages has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 4, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e86ccf0f700d91cd47f32c1ecfb97caf363745fd005fc281e7b54a7f2777794"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelMessageReactions (cognitive 22): ChannelStore.ListChannelMessageReactions has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 4, loops 1 (3 pts) (nesting depth added 6). Of this number, 20 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"50fc91819bd1b355015a0799aa8c14ddaa4ba0c82131176a703030d0c2a5a4fd"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.advanceChannelReadOutboxLocked (cognitive 22): ChannelStore.advanceChannelReadOutboxLocked has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (17 pts), loops 3, boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"97446a6be58bd2de1960be9f834acaaefb0127bd6cd4673c51f3c73e69faa0f3"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.CountChannelMediaCategories (cognitive 22): ChannelStore.CountChannelMediaCategories has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"4102d999ae365f40a63ed75874c2c90e621f05f82d201bb8712376ea7737b4f1"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.validatePeerLocked (cognitive 22): CommunityStore.validatePeerLocked has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 6, loops 1, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc95c80fac777fd19c750e5aacadde56a09be88bd793323deafecbbbea0fae9a"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.GetCommunityParticipantJoinedChats (cognitive 22): CommunityStore.GetCommunityParticipantJoinedChats has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":654}}}],"partialFingerprints":{"codehealthFindingId/v1":"22d4ad90fc88a0e745ce9a5a908a8edb362ba524f2db620781a4ee26de317e71"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.ReviewModerationAppeal (cognitive 22): ModerationReportStore.ReviewModerationAppeal has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 6, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":503}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ecb48afe1a9e3703b28af811662c480fc6e66f87e60ea27db95a482355b4228"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.MarkConverted (cognitive 22): StarGiftStore.MarkConverted has cognitive complexity 22 (threshold 15). Drivers by points: if/else 5 (14 pts), loops 3 (8 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":592}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f8a6c3c3562d946d0b15b5c652f6d54ee9316867de9ac5f1dd39d3f5e6b6b0c"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.UpsertTelegramLoginNativeApp (cognitive 22): TelegramLoginStore.UpsertTelegramLoginNativeApp has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"d45bd3373332c14ee3e05e28b913d0db88dec0bf7d42b1ed968cdf6667e2c799"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListAllBuiltinChannelDialogSnapshot (cognitive 22): ChannelStore.ListAllBuiltinChannelDialogSnapshot has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13 (17 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 5). Of this number, 18 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e48e5bbf78a16fd8bc07cb83ef4526bb004910437a7c7c4fb0f47374b5c64b1"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteExpiredChannelUpdateEvents (cognitive 22): ChannelStore.DeleteExpiredChannelUpdateEvents has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (19 pts), loops 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_update_retention.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"3df86765a7149a66fca74a806835f2818a41b7c430bd0f42d7dfbcdccf531fff"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.DecideAllCommunityPeerLinkRequests (cognitive 22): CommunityStore.DecideAllCommunityPeerLinkRequests has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (18 pts), loops 3, boolean chains 1 (nesting depth added 6). None of this is in the body itself: all 22 points belong to one function literal inside it that branches (line 749). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"8562915da920921379d495a24c06772ae267d34437c2713068661d7d9b7aa818"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.loadStarGiftAuction (cognitive 22): StarGiftLifecycleStore.loadStarGiftAuction has cognitive complexity 22 (threshold 15). Drivers by points: if/else 13 (18 pts), boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":1139}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4c4ad30f101b31f059855d00edd4697bd9639e0f3cd603bc9f698e87420a831"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.TransferStarGift (cognitive 22): StarGiftLifecycleStore.TransferStarGift has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19 (21 pts), boolean chains 1 (nesting depth added 2). Most of this is not in the body itself: 10 of the 22 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 450, 481). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"0591ae94e9e02ce7538762ff227d24287d18aaeab690dd56a83f7a23dc183a07"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.UpsertTelegramLoginNativeApp (cognitive 22): TelegramLoginStore.UpsertTelegramLoginNativeApp has cognitive complexity 22 (threshold 15). Drivers by points: if/else 15 (22 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"44b7527673484c0e2eb2363a3bac783048b31393df06c0c050daab607315cda2"}},{"ruleId":"D2","level":"warning","message":{"text":"main.main (cognitive 21): main.main has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12 (18 pts), loops 2 (3 pts) (nesting depth added 7). Most of this is not in the body itself: 2 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 78). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/langpackfetch/main.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa4b93772cbe588837c600d743093f03bf47ffb8639ea09d5d7ac7796988772e"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.RevokeSessions (cognitive 21): Service.RevokeSessions has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15 (19 pts), boolean chains 1, loops 1 (nesting depth added 4). Most of this is not in the body itself: 7 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 3140). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3120}}}],"partialFingerprints":{"codehealthFindingId/v1":"a55262efaed48a7fa4a4908e5f3bc3980d09895323a2402baf3aecc07563ec52"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.scanNativeTransfers (cognitive 21): Service.scanNativeTransfers has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (17 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/watcher.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4b96d16ec0c620de34b69cfa32d9e769edb1c7d39a4331d5d72c679f08eb838"}},{"ruleId":"D2","level":"warning","message":{"text":"files.patchChunkOffsets (cognitive 21): files.patchChunkOffsets has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (15 pts), match/switch 2 (4 pts), boolean chains 1, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/mp4faststart.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"499f848b84f52e6705a5b59165b54e93020ff2c3b827a2bedf9fec0702c26772"}},{"ruleId":"D2","level":"warning","message":{"text":"mapTileProxy.sweepDisk (cognitive 21): mapTileProxy.sweepDisk has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (18 pts), loops 2, boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/maptile_proxy.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"9acd9271d01c62942da587acd6500142965c16b68b07b73c2c0390b4161e0a01"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SeedAppearance (cognitive 21): Service.SeedAppearance has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (14 pts), loops 3 (4 pts), boolean chains 3 (nesting depth added 4). Of this number, 17 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"9573c089b5b80dc3eb64fe7bd631bb4863a75a5f640ba5a14541c3b40e0cbda5"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.CreateDocumentFromBytes (cognitive 21): Service.CreateDocumentFromBytes has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 3, loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":642}}}],"partialFingerprints":{"codehealthFindingId/v1":"70a7fa087e292c1a7e507603b66b602c41480ef8b0a70b2b960fc382c844d408"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SendPrivateText (cognitive 21): Service.SendPrivateText has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 5 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"7529eb1068d2cf2fe6b1c5338c866221a54be92238378c95a074bef912e9e8b5"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ReportReaction (cognitive 21): Service.ReportReaction has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 4, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f9f6503964398f119b539b63a530289676c09ad78fded72632bd4056ccc09b4"}},{"ruleId":"D2","level":"warning","message":{"text":"telegramlogin.importSigningKey (cognitive 21): telegramlogin.importSigningKey has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 4, loops 1 (nesting depth added 3). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/jose.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"91b15dd7f48bc00dad54441236e633f482900ee85e92526456947dc1d40e96af"}},{"ruleId":"D2","level":"warning","message":{"text":"userprojection.applyPrivacy (cognitive 21): userprojection.applyPrivacy has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 5 (nesting depth added 2). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":634}}}],"partialFingerprints":{"codehealthFindingId/v1":"46f0d7c1caefb8c9262a76818fd66832af53c3236dc3c69247ecfdbec7b13c44"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.EligibleTargets (cognitive 21): Service.EligibleTargets has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (18 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"95d518f0ed36c55cccc9973003010037243c844f4eaeecc0e234f5b60bcefcc5"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.targetState (cognitive 21): Service.targetState has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 4, match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":976}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f4ba5483ff651b891f4a9180ae4dcd549dc479632b124bbcb951bf251562ed6"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.apiMessageEntities (cognitive 21): botapi.apiMessageEntities has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 2, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"4537768d2f9f205f636a7086642ee3e0c08cdf8f69030c30444c482a4aa75982"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.apiDocumentMedia (cognitive 21): botapi.apiDocumentMedia has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (18 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":657}}}],"partialFingerprints":{"codehealthFindingId/v1":"960c0bed9de6f77bc70caaac23f2f28a17e92eadcd3383f61945a34ed793e5e5"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.EvaluatePrivacy (cognitive 21): domain.EvaluatePrivacy has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 4, match/switch 2 (4 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/privacy_evaluate.go"},"region":{"startLine":5}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ec2a267fd04b59954f2b37d5ad0f9eecf59d2cd75993c9dee3f8b89b0fa3768"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.validateStarGiftUpgradePreviewPool (cognitive 21): domain.validateStarGiftUpgradePreviewPool has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 3, loops 2 (nesting depth added 6). Most of this is not in the body itself: 9 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 1238). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1237}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a82ea7c039fd01d9f1e01f928d86f24219e2611100aacbf6347d9e26d4c6741"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.Seed (cognitive 21): loadharness.Seed has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15 (16 pts), loops 5 (nesting depth added 1). Of this number, 18 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"31124401de60cd02f2aadc3ee9673cae9d705df70d3045268d60b80728a8d612"}},{"ruleId":"D2","level":"warning","message":{"text":"Conn.writeFrame (cognitive 21): Conn.writeFrame has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18 (21 pts) (nesting depth added 3). Of this number, 17 points are the body\u0027s own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":2866}}}],"partialFingerprints":{"codehealthFindingId/v1":"c604179b4ad1c93c21f8f0e50ff6bc0f42dc7155b58c5249c6c336a09f28bf3b"}},{"ruleId":"D2","level":"warning","message":{"text":"connStateOverlay.validateSeq (cognitive 21): connStateOverlay.validateSeq has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 5, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"342258b579666c2c140da50e719c478a710b71972a91e665fcebfa7487876ba1"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.botAPIQueuedUpdateEventFromMessages (cognitive 21): rpc.botAPIQueuedUpdateEventFromMessages has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 3, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"52f83e428e141439407092fc8e3fb53b178d8ab73b7cab8a8539ecfd33dec5d9"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.botAPIRequestedPeerProjectable (cognitive 21): rpc.botAPIRequestedPeerProjectable has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 9, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":576}}}],"partialFingerprints":{"codehealthFindingId/v1":"629bfc43c9b39bfd3a28d74280e3c9746c8881d62c7a6dac6756ee93fc944e82"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgUniqueStarGift (cognitive 21): rpc.tgUniqueStarGift has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 3 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_unique.go"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5c33b1b167ca83c5286dea6f2686dff128685e9f1ef70e1a1d7d44db65c0d45"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgMessageActionStarGift (cognitive 21): rpc.tgMessageActionStarGift has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, boolean chains 1. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1623}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe5341e643ef225ce23927efe84752febe728e0343ac8f7d99aec6a2302890ef"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.registerLayerRPCAdmissionFieldPreflights (cognitive 21): rpc.registerLayerRPCAdmissionFieldPreflights has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (18 pts), loops 2, boolean chains 1 (nesting depth added 7). Most of this is not in the body itself: 8 of the 21 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 96, 133, 117). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/request_preflight.go"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e0ca0e9c0ccf0b7b8cb948fa38ebc1c9ae170623356887c2b5a511e9de34f9b"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.collectMessagePeerRefs (cognitive 21): rpc.collectMessagePeerRefs has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"23ab547551086b7fa4a7f61efaa98ed284f2a3ff704b514cb2ea109e31efecd1"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSendInlineBotResult (cognitive 21): Router.onMessagesSendInlineBotResult has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18 (19 pts), boolean chains 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca1039b72b71cae439f59fa87655bc788b609a5c631b578ff76ed538fdfc1c73"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.syncSessionChannelMemberships (cognitive 21): Router.syncSessionChannelMemberships has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_interest.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"e021b51ce13bdd83e0e4044712d745392dd080e654ad334bb50e5205d65c1b25"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.deliverEphemeralPushLocal (cognitive 21): Router.deliverEphemeralPushLocal has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 6, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral_push.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"f08ea29f7cf2a30b6feb44efa25f1647d2c847eb8256d5007cd2044fc98f9d8e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.loadLiveLocationMessage (cognitive 21): Router.loadLiveLocationMessage has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 2 (4 pts), boolean chains 2, match/switch 1 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd2f3bbc16194a9b81499129a627c9f99e4b640b4c3005658037b94d97116a19"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.loadMessagePoll (cognitive 21): Router.loadMessagePoll has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 2 (4 pts), boolean chains 2, match/switch 1 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls_updates.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"a194a585db5df567d8e5427529155e3a03732309c6964b90e744916d913400fc"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.channelPollUpdates (cognitive 21): Router.channelPollUpdates has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12 (20 pts), boolean chains 1 (nesting depth added 8). Most of this is not in the body itself: 10 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 226). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls_updates.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"7892599fa81bca45ace2c44320e76f281a146be6b560975b28a980c4e738f05a"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSendQuickReplyMessages (cognitive 21): Router.onMessagesSendQuickReplyMessages has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 2, loops 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_quick_replies.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d4c34154675232bece3de7f6cfd5c0c2b8fde3efcba6ef685357c5ee0094b5f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetSavedDialogs (cognitive 21): Router.onMessagesGetSavedDialogs has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15 (20 pts), boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_saved_dialogs.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"b447ec776fc1342f2a58bfa1a041119693e90e7910a9904dac5f3c32cf853528"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesToggleTodoCompleted (cognitive 21): Router.onMessagesToggleTodoCompleted has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 5, boolean chains 2 (nesting depth added 5). Most of this is not in the body itself: 5 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 151). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_todos.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"a640ceb40d9b14101b6ea1cde6a4906c8b47558c6c50b9c4e052dda414d54e00"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.loadTodoMessage (cognitive 21): Router.loadTodoMessage has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 2 (4 pts), boolean chains 2, match/switch 1 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_todos.go"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"6114dd61767fb31cacb5c500b4199d71c83689879e28f72b457d2823684da86b"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesRequestAppWebView (cognitive 21): Router.onMessagesRequestAppWebView has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14 (20 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f313bf6e146e9746f82083ef3e39103d6b91d8b816669833639601774eb3595"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsGetSavedStarGift (cognitive 21): Router.onPaymentsGetSavedStarGift has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 2, loops 1 (nesting depth added 7). Of this number, 19 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1152}}}],"partialFingerprints":{"codehealthFindingId/v1":"57cf74582b84e6d335d5cf3f1ab3bb0d710b84b9089e65b2ff1a5002d9f5b77e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onUsersGetSavedMusicByID (cognitive 21): Router.onUsersGetSavedMusicByID has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 4, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":733}}}],"partialFingerprints":{"codehealthFindingId/v1":"22699462f8cac8133f442621612e09b0d08bb36e8036a0051a87021d95882566"}},{"ruleId":"D2","level":"warning","message":{"text":"CodeStore.VerifyLogin (cognitive 21): CodeStore.VerifyLogin has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14 (20 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"30919ae077afa9996509ad537a2efce59854634368719c5dfd71caa5ff56797f"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListExportedInvites (cognitive 21): ChannelStore.ListExportedInvites has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 4). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"29cb49416a1023c2825edb5db36615757b745e675e7c347aa45143d4bdb9afa4"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.FilterActiveChannelMemberPairs (cognitive 21): ChannelStore.FilterActiveChannelMemberPairs has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (14 pts), loops 4 (6 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":910}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfa369bb11eda0203720335d23139431584117b6ed1b6f489dacba9dce5de016"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ResolveDiscussionReadTarget (cognitive 21): ChannelStore.ResolveDiscussionReadTarget has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 6, match/switch 1 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":529}}}],"partialFingerprints":{"codehealthFindingId/v1":"861784a75e093b61abcaa4555ac959ea76e239cefa00d6f6e4751202a70fbb59"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetPaidMessagesPrice (cognitive 21): ChannelStore.SetPaidMessagesPrice has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 7 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_settings.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"148f53bd1e7dc71376e53b06f8c705c643808340236bb528b4e0503929d822f5"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListMessageReadParticipants (cognitive 21): ChannelStore.ListMessageReadParticipants has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 6, loops 1 (nesting depth added 4). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"de847bf0e457e44cfb331e53790fe1c047fccb0b8be6e0b8cbb3931f0574527c"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelMessagePublicForwards (cognitive 21): ChannelStore.ListChannelMessagePublicForwards has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 3 (4 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"772a74e6de8661051a8e51afab5f5465d6919b13513a6a7ab90e0f9693634c0e"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.CreateForumTopic (cognitive 21): ChannelStore.CreateForumTopic has cognitive complexity 21 (threshold 15). Drivers by points: if/else 15 (17 pts), boolean chains 4 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a1fd857a268efd2a7f802870d4a68dfdfe38773cbeb67417f917596412573fb"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ReorderCommunityPinned (cognitive 21): CommunityStore.ReorderCommunityPinned has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 3, loops 3 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":1052}}}],"partialFingerprints":{"codehealthFindingId/v1":"09eae5a35c3b9822bc706871633bac0bd7949e2457b679b6adc0ff21bde54f67"}},{"ruleId":"D2","level":"warning","message":{"text":"EphemeralMessageStore.PruneExpiredEphemeralMessages (cognitive 21): EphemeralMessageStore.PruneExpiredEphemeralMessages has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 4 (6 pts), boolean chains 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ephemeral.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f2a74c55546df6a61ed2cbfaa7c1cc485a7b78a4177bd3c80229a28371b5787"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.SearchPrivateMedia (cognitive 21): MessageStore.SearchPrivateMedia has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 5, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"af8d957593b504790d3e631e297c7e57451fd23496da7bc852d984463eb91608"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.ListModerationCases (cognitive 21): ModerationReportStore.ListModerationCases has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 5, loops 2 (nesting depth added 6). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0f66eec2c10de86bc4e77fa05cb350b0c06e9e8f303bb1e9a591bc971d16a65"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.lockRawAuthKeyInIdentityOrder (cognitive 21): postgres.lockRawAuthKeyInIdentityOrder has cognitive complexity 21 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 5, match/switch 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_identity_lock.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"4923016d4b8d269d36cb0935862b139169d22b77e6f79058cca7bc7946c08922"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.bindAuthorization (cognitive 21): postgres.bindAuthorization has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18 (19 pts), boolean chains 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authorization.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"3877388941b0e784d953130fc1aa7c2e087af83e049202e213775a9d471719b1"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.MigrateAndStatus (cognitive 21): postgres.MigrateAndStatus has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/postgres.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ad97c2690aae9836821877eb4241b9a485442fec6795134629910fb7fd1af29"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EnsurePermanentInvite (cognitive 21): ChannelStore.EnsurePermanentInvite has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17 (19 pts), boolean chains 1, loops 1 (nesting depth added 2). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"971e0023d09fa7bccc02629375627e21c1a56f4239e2f2b7eb8939524cd78b20"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.readChannelHistoryOnce (cognitive 21): ChannelStore.readChannelHistoryOnce has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17 (19 pts), boolean chains 2 (nesting depth added 2). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":916}}}],"partialFingerprints":{"codehealthFindingId/v1":"b77ecef0e490e59d3f6d11033823a8d1c5ff35734260f203469a123d67b41fbf"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetChannelWallpaper (cognitive 21): ChannelStore.SetChannelWallpaper has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16 (20 pts), boolean chains 1 (nesting depth added 4). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"b96f7d4c99defd58be00c19afc7c62df11aca7939b44aceaf144683a7205dcba"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetChannelPhoto (cognitive 21): ChannelStore.SetChannelPhoto has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17 (19 pts), boolean chains 2 (nesting depth added 2). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"68d91f3d36a81d1314ce67c9341c84bfa427e1c8c53d782ac5b12baeeeac4b7e"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteForumTopicHistory (cognitive 21): ChannelStore.DeleteForumTopicHistory has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17 (18 pts), boolean chains 2, loops 1 (nesting depth added 1). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"d62c5e935491c461ec5464800ffae9b8e8b5a62312eafcd432dc5a6f2f317e9c"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.mutateMessagePoll (cognitive 21): MessageStore.mutateMessagePoll has cognitive complexity 21 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 2, loops 1 (nesting depth added 2). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_polls.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba357a41a137d844ebd6b961791a5197eb565e653d0572ec7d07f5d242ac89a2"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.EditScheduledMessage (cognitive 21): MessageStore.EditScheduledMessage has cognitive complexity 21 (threshold 15). Drivers by points: if/else 17 (18 pts), boolean chains 3 (nesting depth added 1). Of this number, 20 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"590b3ba71e0cdf32771f93fc3b517d56f6e039912036f1cf3c46c23b0ecaef69"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.ImportLegacyEphemeralReport (cognitive 21): ModerationReportStore.ImportLegacyEphemeralReport has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18 (20 pts), boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"06377a9ec0816d47d9936b8ce4721f90e4b3ebde57cec07e1622ba520b07bdac"}},{"ruleId":"D2","level":"warning","message":{"text":"StoryStore.CreateStory (cognitive 21): StoryStore.CreateStory has cognitive complexity 21 (threshold 15). Drivers by points: if/else 14 (19 pts), boolean chains 1, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"88969df3841e3204062dfeda8c77233a611411d11b658e84e5c9707c3f09cdcc"}},{"ruleId":"D2","level":"warning","message":{"text":"main.runLoop (cognitive 20): main.runLoop has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (14 pts), match/switch 2 (3 pts), boolean chains 2, loops 1 (nesting depth added 8). Of this number, 13 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botdemo/main.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d0bea09865e19366dba435d49a956cfe7509ccb8583ccf2ec14ab38db8400a9"}},{"ruleId":"D2","level":"warning","message":{"text":"main.cmdRun (cognitive 20): main.cmdRun has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (20 pts) (nesting depth added 7). Most of this is not in the body itself: 2 of the 20 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 113, 145, 139). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/owpengram-ctl/main.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"43778cd1af92911312ef663267f51d9857158279f9ecc982896ee6bdc95e212a"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.handleBotFatherCommand (cognitive 20): Service.handleBotFatherCommand has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 1, match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d7a261b9319594eb3b5be0d387a50d94a13bd73d695efe49fc5e76da4daeedd"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.premiumBotDepositReply (cognitive 20): Service.premiumBotDepositReply has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/premiumbot.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3cabaa735da67bb68feaf06ebf07c5bceaf097fab2364c90b1887e772d75155"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.filterBotChannelEvent (cognitive 20): Service.filterBotChannelEvent has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (14 pts), boolean chains 3, loops 1 (2 pts), match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ea62f25d377f277fa5eedbfe959eeb0ddcf8141613c9f453d1f80d147f2884a"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.attachArchiveSummary (cognitive 20): Service.attachArchiveSummary has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 4 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":605}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b997cbcad7e7ace5655ee54f4e2a5d121c326a6b6142aa025f9aed593474693"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.RefreshPrices (cognitive 20): Service.RefreshPrices has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/pricefeed.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcbfa908407d06b6436366d2fd4a4d4a9c8535e4f5d8e0b18974def77a1b0f76"}},{"ruleId":"D2","level":"warning","message":{"text":"stargifts.normalizeAndValidateLottie (cognitive 20): stargifts.normalizeAndValidateLottie has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/animation.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc816d92007f1205e2b587564c858f79772154a9b6dad6fc87bb719d541ee255"}},{"ruleId":"D2","level":"warning","message":{"text":"AIProvider.Translate (cognitive 20): AIProvider.Translate has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (10 pts), match/switch 2 (5 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 8). Most of this is not in the body itself: 6 of the 20 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 57, 86). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/ai_provider.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0e5e7f66f46e9656c122ba13293df97e9379beba149815207c7d05b206d1d3c"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.sendMessage (cognitive 20): handler.sendMessage has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e8aef2409049a7b7e22779bccc9f519e15a1de6ff310aafeef9054b8d68222f"}},{"ruleId":"D2","level":"warning","message":{"text":"tdesktop.lookupChatThemeWallpaperAlias (cognitive 20): tdesktop.lookupChatThemeWallpaperAlias has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (14 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/appearance_seed.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf3e79e59b6d91b9683c0081598b6fcfcfee89c350b42587ff15ee3a5dd91e19"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.detectHashtagMessageEntities (cognitive 20): domain.detectHashtagMessageEntities has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"8319c9c99541dbbfdd7710cca936c78bd2f9aea34764ff6fbd377f41b5ac46e9"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.ValidateReplyMarkup (cognitive 20): domain.ValidateReplyMarkup has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 5, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_markup.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"38bd2940cad418a3715822c4a6eb72f76d086d1ba867302de40d489182825e57"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.cloneReplyData (cognitive 20): domain.cloneReplyData has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 4 (8 pts), match/switch 1 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_reply_external.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"5222dd94826f1b2283cf372ab71c1d6d495ae39415f7acdb994ee9bfaae20aee"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelReactionPolicy.AllowsReaction (cognitive 20): ChannelReactionPolicy.AllowsReaction has cognitive complexity 20 (threshold 15). Drivers by points: if/else 4 (11 pts), loops 2 (6 pts), match/switch 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/channel.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"9805aab2b14650ad6333eb0463cc3ad010af001f11d248597a1653d5b571c8dc"}},{"ruleId":"D2","level":"warning","message":{"text":"Conn.setLayerProfile (cognitive 20): Conn.setLayerProfile has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 3, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn_layer_profile.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa34f40527ba2e2119d56ed33875204893c263613eb84339d01120d9a37053a9"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.decodeMessageContainerViews (cognitive 20): Server.decodeMessageContainerViews has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 4, loops 1 (nesting depth added 5). Of this number, 18 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"0807cb57a8ff2a016a9917f22b95479bc635fb66bd1480b3f5f9bceb11fd4f9c"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.applyInheritedLayerForRawAuthKey (cognitive 20): SessionManager.applyInheritedLayerForRawAuthKey has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"a298f82f81d6135d6cac0762848b7f4a918e733b22df0776e03c11815b51d3d4"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.ApplyOrderedRawLayerForSession (cognitive 20): SessionManager.ApplyOrderedRawLayerForSession has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4b5c91df38f3a4a2b2c7b689e178c0c000e7d253d98d4413de64496d29feece"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.ExplicitLayerEvidenceForAuthKey (cognitive 20): SessionManager.ExplicitLayerEvidenceForAuthKey has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 6, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":516}}}],"partialFingerprints":{"codehealthFindingId/v1":"066256ee1355457b3016e4612fd062d9520109b5751557f4ac34c2cea497e7f9"}},{"ruleId":"D2","level":"warning","message":{"text":"progressiveDeadlineWriter.Write (cognitive 20): progressiveDeadlineWriter.Write has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (17 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/transport_compat.go"},"region":{"startLine":331}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2a99db04e0e64a6f97417c853a53b2c9daa5784e533ac48b8aa25f0cd088332"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.defaultProfilePhotoEmojiDocumentIDsFromKind (cognitive 20): rpc.defaultProfilePhotoEmojiDocumentIDsFromKind has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":2131}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e538f0ebf956712538faf41c2b76ac78af1ad27d0b644d9f97b80c9b71cdd7b"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.parseBotAPIRichHTML (cognitive 20): rpc.parseBotAPIRichHTML has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (13 pts), loops 2 (4 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 8). Most of this is not in the body itself: 4 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 60). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_message.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"773301fe5f79f3c8971e593514895deab760fd9487e8f1d3bc8cbd748b7a96d0"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgChannelDifference (cognitive 20): rpc.tgChannelDifference has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 4 (5 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9367501eb430c7faedc035eb214e45924841dba12670ad4c14b5a06c8d7b3e9"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.applyMonoforumPeerOverlays (cognitive 20): rpc.applyMonoforumPeerOverlays has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 4, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_monoforum.go"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc1abf51615397ceb5da7b3dd1d2fd5ff87032cc6111bdaaf6f690aaa6fb85ff"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.domainPhotoVideoMarkup (cognitive 20): rpc.domainPhotoVideoMarkup has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (15 pts), match/switch 2 (3 pts), boolean chains 2 (nesting depth added 10). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"f72057cf3114b174e5477ec162e452e063199716e7980cfde7e9b6834e70ca17"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.storyViewPeers (cognitive 20): rpc.storyViewPeers has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (17 pts), boolean chains 2, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_peer_projection.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f41adb1bec994392bd0831e3eaed76868effab56a65689c54ac0fc2877ba22c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onAuthBindTempAuthKey (cognitive 20): Router.onAuthBindTempAuthKey has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15 (19 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed7e9b3e52c9d0d6e688cd629647b937b22c22e441f85b6ed2204b66dc8a9ad9"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.BotAPISendRichMessage (cognitive 20): Router.BotAPISendRichMessage has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15 (16 pts), boolean chains 4 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2bc265d9123c229b2db849d7e09250aaea2b54763c7a1d5e541bf4d29eaf987"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.tgAttachMenuIcons (cognitive 20): Router.tgAttachMenuIcons has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 2 (4 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_attach_menu.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"2df5b100a6420bd27df7375c0a4f68ff87b37773a52f4d1eb34546e082f2aafd"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.mentionUserIDsFromDomain (cognitive 20): Router.mentionUserIDsFromDomain has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 9). Of this number, 17 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1222}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f6137023c02b4b359aafcbdbbb9069b561b4685c7fe7a126a64a9a59ae8275f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.stickerCollectionDocuments (cognitive 20): Router.stickerCollectionDocuments has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_stickers_personal.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"df2bdeedb041f4c6a8d85e2ba58336cf04bc48d5a21fdb3420a6aeae517df3fd"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.createProfilePhoto (cognitive 20): Router.createProfilePhoto has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (18 pts), boolean chains 1, match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"86865b573bafb0a769277fb7c7c23c389c62e242583f6549bea7d4e9f42818e1"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhotosGetUserPhotos (cognitive 20): Router.onPhotosGetUserPhotos has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14 (15 pts), boolean chains 4, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":426}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8aa07a48341258ea31acb20e58bc4423ac34b42a95d3c7c3cba9dfeba9b843e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.resolveInputChatPhoto (cognitive 20): Router.resolveInputChatPhoto has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (17 pts), match/switch 2 (3 pts) (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":773}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f08840b103e958a2f44c45e486daab53f403921ebb5968f05c55d860b01623d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onStoriesEditStory (cognitive 20): Router.onStoriesEditStory has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15 (18 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1366}}}],"partialFingerprints":{"codehealthFindingId/v1":"74c6cacc359c16a74bf8108712ccacbe45708652630b04d07b9b79c6f9c69212"}},{"ruleId":"D2","level":"warning","message":{"text":"endpoint.run (cognitive 20): endpoint.run has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 2, loops 1, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b22395ad9c08c8ff23941685bdbe3f6f13c9f6cf2772551e3d0dffe280eb8d5"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.adjustStoryReactionCounts (cognitive 20): memory.adjustStoryReactionCounts has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 2 (4 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1736}}}],"partialFingerprints":{"codehealthFindingId/v1":"394671a7f89466f5a06ae510037af32ad0b1555e3e9490c81402ab940dfa5466"}},{"ruleId":"D2","level":"warning","message":{"text":"CodeStore.VerifyScoped (cognitive 20): CodeStore.VerifyScoped has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12 (18 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c86521bf7a9f01b1281f46111d8983f995a6fad59ef4290057d131bafcd422a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteChannelMessages (cognitive 20): ChannelStore.DeleteChannelMessages has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 5, loops 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":8}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f459717733c4641767c61e14686995ff6daa46f89a7fff3dc41031c7f305653"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelUnreadMentions (cognitive 20): ChannelStore.ListChannelUnreadMentions has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 6, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b582ef8d5abe570e1504c2f6697dfe6d4cd247a8572150e50bcf4820858b337"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.addChannelUnreadMentionsLocked (cognitive 20): ChannelStore.addChannelUnreadMentionsLocked has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 4, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddf1785b2781297fcc1d69b37537fb2e23ca7ec481d1712486a0685f76193907"}},{"ruleId":"D2","level":"warning","message":{"text":"LoginCodeDeliveryStore.DeliverLoginCodeMessage (cognitive 20): LoginCodeDeliveryStore.DeliverLoginCodeMessage has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 2, loops 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code_delivery.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6eb66bf50d1e0249765f6f686f08b8a574464433716ccf45aa7eff8d75150ec"}},{"ruleId":"D2","level":"warning","message":{"text":"StarsStore.ListTransactions (cognitive 20): StarsStore.ListTransactions has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 4, loops 2 (4 pts) (nesting depth added 4). Of this number, 12 points are the body\u0027s own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/stars.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"c18b58a6f6a86c5e37f69a76fb1eebd99d6b26e735fb0e29add3122026a1add5"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.revokeByUserExceptTx (cognitive 20): postgres.revokeByUserExceptTx has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (16 pts), loops 4 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authorization.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d9d311ce915b6c05ad119dd6d061cee02ac3b0ef2b04ca7133a91839a9f67dd"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.validateCommunityPeerForLink (cognitive 20): postgres.validateCommunityPeerForLink has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 4, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cbf8967236ecab19905d6c0e3afa3fe382126af371a26acf4f32ad765e7d5cc"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.getModerationReport (cognitive 20): postgres.getModerationReport has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 2, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0e71732b97e7159534fb2eb82f0bd448c5492724e9a472ace408361732c9410"}},{"ruleId":"D2","level":"warning","message":{"text":"BotStore.DeleteBotAccount (cognitive 20): BotStore.DeleteBotAccount has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16 (17 pts), boolean chains 3 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9b90f23dc01a3c4cd5539c71584dc70192014bd46cbc96f97af8c8bb01b913f"}},{"ruleId":"D2","level":"warning","message":{"text":"BotVerificationStore.DecideCustomVerificationRequest (cognitive 20): BotVerificationStore.DecideCustomVerificationRequest has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15 (16 pts), boolean chains 4 (nesting depth added 1). Most of this is not in the body itself: 9 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 876). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":855}}}],"partialFingerprints":{"codehealthFindingId/v1":"86013e147aeb24b69c8c02bc6f56576f3536d3fd495a33de960ccb55db6e583d"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.getChannelDialogs (cognitive 20): ChannelStore.getChannelDialogs has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 2 (4 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1725}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac1edfd8635526e6daa7b5b92aed97fab180d492900840910573a77d07ec3c18"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.CreateForumTopic (cognitive 20): ChannelStore.CreateForumTopic has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 4 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cf8af7953376067210c3fd3fdcb360f990de027ea48d4376587a5528ecbe197"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ReorderPinnedForumTopics (cognitive 20): ChannelStore.ReorderPinnedForumTopics has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 3, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":341}}}],"partialFingerprints":{"codehealthFindingId/v1":"67bd0c8bca5deab035886dbfdbcd06cc22124d6159cbc4f56a3ebde3f46105cc"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ToggleCommunityPeerLink (cognitive 20): CommunityStore.ToggleCommunityPeerLink has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (20 pts) (nesting depth added 7). None of this is in the body itself: all 20 points belong to one function literal inside it that branches (line 532). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc789e1adb33c71ebd742386b5f6770aed5595ebc85a066ed7d3fb564ba612f6"}},{"ruleId":"D2","level":"warning","message":{"text":"ContactStore.ContactProjectionForViewers (cognitive 20): ContactStore.ContactProjectionForViewers has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"20c33b65ec54815461ebd3d795e395647461837e3ddde64a5ebd7fecd016a410"}},{"ruleId":"D2","level":"warning","message":{"text":"MediaStore.GetDocuments (cognitive 20): MediaStore.GetDocuments has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 3 (4 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":437}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0d4d7735309ae852f0abba13e0c18d5b7be004e8b198f5bc032a249cd7c519a"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.PurchaseStarGift (cognitive 20): StarGiftLifecycleStore.PurchaseStarGift has cognitive complexity 20 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 3 (nesting depth added 3). Of this number, 15 points are the body\u0027s own statements and 5 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"298a5e5a3326a564faec2aeae6dc008a8badd2c562ceffbbe77f46b191468e7e"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.loadStarGiftPurchaseReplay (cognitive 20): StarGiftLifecycleStore.loadStarGiftPurchaseReplay has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 6 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"00e6bea66195a959b9c5509656c3537043596a74d6608c8c03c2e9c0fca158d0"}},{"ruleId":"D2","level":"warning","message":{"text":"VerificationStore.DecideVerificationApplication (cognitive 20): VerificationStore.DecideVerificationApplication has cognitive complexity 20 (threshold 15). Drivers by points: if/else 16 (19 pts), boolean chains 1 (nesting depth added 3). Most of this is not in the body itself: 9 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 502). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":479}}}],"partialFingerprints":{"codehealthFindingId/v1":"a811b61e4647b2aecd9b0849fad97b2418e3b7093112ab36d2534c1caeb39505"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.authorizationStatus (cognitive 20): Handler.authorizationStatus has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 1, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"62f5eb19f4781da661d30e8823c6b6ea662729482d88b57aea35620f4b8eb98b"}},{"ruleId":"D2","level":"warning","message":{"text":"readStore.DashboardActivity (cognitive 19): readStore.DashboardActivity has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (13 pts), loops 5 (6 pts) (nesting depth added 5). Of this number, 11 points are the body\u0027s own statements and 8 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/activity.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ce6f2b8b8edee7e2c7256111328bcddcf5f0db0d9391cdec9ab3b2811dd06f7"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.UpdatePasswordSettings (cognitive 19): Service.UpdatePasswordSettings has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cd8c6bfaa5f4b65e38313cac72d534f992961a578d3be56acea28eff90e35b8"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SendCode (cognitive 19): Service.SendCode has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e224b61162a8ca8abc424ae1c1c93a3ef955da8c925ec5424929f6e17f49f19"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.createPhoneCode (cognitive 19): Service.createPhoneCode has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13 (19 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":599}}}],"partialFingerprints":{"codehealthFindingId/v1":"55e0d136a74afacba151024d0994a612fdefd03f6782bc2af15cdcde8fc76451"}},{"ruleId":"D2","level":"warning","message":{"text":"broadcast.normalizeRequest (cognitive 19): broadcast.normalizeRequest has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 2, loops 1 (2 pts), match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/broadcast/service.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"406acfdc23367e62e6f20fa9eef7f9e8dfb71a8755d98ec9d2d3e4669a6123ba"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.cachedActiveChannelIDsForUser (cognitive 19): Service.cachedActiveChannelIDsForUser has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/active_ids_cache.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"40ce62517f369a53b5ab3ec55e962a97dd877805a7d91c088115aff84ddfa220"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ExportInvite (cognitive 19): Service.ExportInvite has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13 (18 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"66d361106923011272d93282112ebe9f724468bc775890c7a592338d27dcc47d"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.JoinInvite (cognitive 19): Service.JoinInvite has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16 (19 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"50760a1718fa664fa7bc2ee7628123b298583f7dc654ada3491f0a6eb2c2a2b8"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.dialogDraftsReadModel (cognitive 19): Service.dialogDraftsReadModel has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (12 pts), loops 5, boolean chains 2 (nesting depth added 3). Of this number, 10 points are the body\u0027s own statements and 9 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/draft_read_model_cache.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"38b123ae4a7f37b44d96c1dda62a88e76378ff1d55040d281c809e3b456bc9dc"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.loadDialogOwnerSnapshotHeaders (cognitive 19): Service.loadDialogOwnerSnapshotHeaders has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e3f9a1960c72f7489c7bc9f0f626452ca7849c3471ba0549283cca6a8ab1d60"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.seedAppearanceDocument (cognitive 19): Service.seedAppearanceDocument has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"014627097fad2b4a1032f9f7c6dd7999b4d55e2a75b93c56412ad704c946702f"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.AdminDeleteUncategorizedGifs (cognitive 19): Service.AdminDeleteUncategorizedGifs has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (16 pts), boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_admin.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf726816f1b9c41cfcc963aa531dc904dc4dee8c432dc22930a563029856def1"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.avatarMarkupBytes (cognitive 19): Service.avatarMarkupBytes has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":1210}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0caba3173c98852a9878af56615ddc6f543f83e0634d3cef5b4ce158823d0e6"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.accountAppConfig (cognitive 19): Service.accountAppConfig has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 3, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/help/service.go"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c21a55f852a8b5200df068ead88380a6abdf9dc89e8dfe86c48bb523246b213"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.deliverConnectedBusinessBotAutomation (cognitive 19): Service.deliverConnectedBusinessBotAutomation has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 6, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"161213c13f9b14d04426d03455339df7c0e093d81757734d257d8fababdf003e"}},{"ruleId":"D2","level":"warning","message":{"text":"stargifts.containsLottieExpression (cognitive 19): stargifts.containsLottieExpression has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (13 pts), loops 2 (4 pts), boolean chains 1, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/animation.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"0eb82dc613eabadd1a3e5ba059c9c62865ae226532a360b91d1d19dcf2f1c004"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.AuthorizeMessageButton (cognitive 19): Service.AuthorizeMessageButton has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14, boolean chains 5. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f891ab5e8cedf5c3db84757a4700721cb2c85ba4c7c3e281623882dbfc63873"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.recordEventCore (cognitive 19): Service.recordEventCore has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12 (18 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":755}}}],"partialFingerprints":{"codehealthFindingId/v1":"59e9d91dc9e595d8ad5ad2becf2b9c695130d1b571518e40a1400374d618dc62"}},{"ruleId":"D2","level":"warning","message":{"text":"CachedContactStore.GetReverseContacts (cognitive 19): CachedContactStore.GetReverseContacts has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 2, boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"111beec4d9ced75ff6e97a98c03f1996f761eb84c10384f4cc854446ddde18f8"}},{"ruleId":"D2","level":"warning","message":{"text":"CachedContactStore.loadContactProjectionForViewers (cognitive 19): CachedContactStore.loadContactProjectionForViewers has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 3 (8 pts), boolean chains 1 (nesting depth added 10). Most of this is not in the body itself: 7 of the 19 points are its own statements and the rest belongs to one function literal inside it that branches (line 430). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"d180cca0ee0935caf08ec1cf026856c33435c63e9f7096349a930ed5df1b7242"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.sendEphemeralLocation (cognitive 19): handler.sendEphemeralLocation has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 5 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"90ff202a84589ab184b464727f22e3bf524046452bb4e6d397f9338ba8d49b75"}},{"ruleId":"D2","level":"warning","message":{"text":"config.validateAdminRBACConfig (cognitive 19): config.validateAdminRBACConfig has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1866}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6849930c9995d583eed9c6e85f4842b7576f6b465f9c8faccb1a96c8c26a87f"}},{"ruleId":"D2","level":"warning","message":{"text":"config.parseAdminScopedTokens (cognitive 19): config.parseAdminScopedTokens has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1908}}}],"partialFingerprints":{"codehealthFindingId/v1":"98fade93e7d26b4ba1ac530f162913258397b9e0de9bd500a6b1d2d1042bd1b6"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.ApplyPremiumBoostSlot (cognitive 19): domain.ApplyPremiumBoostSlot has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (12 pts), boolean chains 7 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/boost.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c5be560938f6164f897f6a0d97f0aebcabdaca6ffad10a47087137dac271499"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationDecisionRequest.Validate (cognitive 19): ModerationDecisionRequest.Validate has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 9, if/else 8 (9 pts), loops 1 (nesting depth added 1). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation_case.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"155d5db3d0f0666767598c82eb5e43f4c1d4da8acbd66e379c895e5ad0dd5f2b"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.runSeedAccountPhase (cognitive 19): loadharness.runSeedAccountPhase has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 4 (5 pts), match/switch 1 (2 pts) (nesting depth added 7). Of this number, 11 points are the body\u0027s own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b5718b79073f1e758df100cde916d908b55ccf65121bdb54ea41013b49e4d64"}},{"ruleId":"D2","level":"warning","message":{"text":"Manifest.Validate (cognitive 19): Manifest.Validate has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 3, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/types.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"de9efa9121e35492f1e7ff4549e377c7e56bada78e92e9e6bc7da4bafcdcd9a9"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.initialLayerRPCAdmissionCursor (cognitive 19): Server.initialLayerRPCAdmissionCursor has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b41976b4ddc5fafa0db64a11e6d311ba66807fe76b14cddf99fc6b813cab0fe"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.CloseSessionsForBusinessAuthKey (cognitive 19): SessionManager.CloseSessionsForBusinessAuthKey has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (9 pts), loops 5 (6 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":947}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dc0bc8631f377ad973cf96d24ad504504b10742c3e6eadb6ad6861d7883df8b"}},{"ruleId":"D2","level":"warning","message":{"text":"Sender.Deliver (cognitive 19): Sender.Deliver has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 4 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/otpdelivery/webhook/sender.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"717f6a0a3c263a08fd4514b5520ae0e27d69c705da6c1b297d98bb763490c48a"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.validateChannelSearchPostsRequest (cognitive 19): rpc.validateChannelSearchPostsRequest has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"0116229f0e9147ca111180e53cc9ee62c0876fefb7c2822c47272739689c4744"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.domainMessageEntitiesForViewer (cognitive 19): rpc.domainMessageEntitiesForViewer has cognitive complexity 19 (threshold 15). Drivers by points: if/else 3 (7 pts), boolean chains 6, match/switch 2 (5 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":673}}}],"partialFingerprints":{"codehealthFindingId/v1":"dde5b6bdafc980e137137ca4ce037ed7b73eefff5618bfc562ef19cb3759cfc2"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.applyUsernamesFromRegistry (cognitive 19): rpc.applyUsernamesFromRegistry has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 4, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/fragment.go"},"region":{"startLine":336}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cebe8b5eba39a410ca09277f9d3b408803da8451a6d48788097db05c33824cd"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.channelMemberHasRequestRights (cognitive 19): rpc.channelMemberHasRequestRights has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 17, if/else 2. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":392}}}],"partialFingerprints":{"codehealthFindingId/v1":"66a3b1badb6ddb0ff114f44ce0d07bae169a5d4e93f19359147eed6bb6903033"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.mergeByteSpans (cognitive 19): rpc.mergeByteSpans has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":871}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c2cd2fa38c02dd5d5cf4adc87a940a22ff7e1d841a34780dfa1a8d531746f90"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.validateStoryInputPrivacyRulesShape (cognitive 19): rpc.validateStoryInputPrivacyRulesShape has cognitive complexity 19 (threshold 15). Drivers by points: if/else 3 (10 pts), loops 3 (7 pts), match/switch 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":882}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4a929fc6cc47b60d8b74ef542a85de1d32df359adecf9708b0d908e98547591"}},{"ruleId":"D2","level":"warning","message":{"text":"presenceTracker.statusFor (cognitive 19): presenceTracker.statusFor has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa4952d2a6674acc859e722d2f59e0f80ca576eddd89a043a99421c9991199a6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onAccountUpdateEmojiStatus (cognitive 19): Router.onAccountUpdateEmojiStatus has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14 (19 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1786}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f77914ef91224f57cebe440d01252657fd5cff19d4a2aa1f25317833d770642"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onAccountDeleteAccount (cognitive 19): Router.onAccountDeleteAccount has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac0f176b39d87c73b9aa2da0d9c2fd938a8be85b27b94da1ae4b6ff4eb2dd8c2"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.BotAPISendEphemeral (cognitive 19): Router.BotAPISendEphemeral has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 5 (nesting depth added 3). Most of this is not in the body itself: 9 of the 19 points are its own statements and the rest belongs to one function literal inside it that branches (line 375). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"e702c7955c06353bc38b656a23ac5e82cf89632aebd6c412d01ee3c915965488"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetChatInviteImporters (cognitive 19): Router.onMessagesGetChatInviteImporters has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 2, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"f79a3fb14bf13ad44c57d8e73ea9e8d4e7d13ba9cde124a731bf5e006e0cf0b3"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onChannelsEditAdmin (cognitive 19): Router.onChannelsEditAdmin has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"97985a63daf876a0b858c2d0ac177385c3daf79ef6c7fcaaa687eb8596519b23"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.communityPeerFromInput (cognitive 19): Router.communityPeerFromInput has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 5 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"85cadfe75c6c4d9f1f31838e2aef0879e9b367fea4f0c834ff9f5fb685b117f5"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.resolveRichMessagePhotos (cognitive 19): Router.resolveRichMessagePhotos has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 3 (5 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_rich_message.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"1dd05459f60968d0dbecd173dc5f56de3c884f1ba1ad55fc004c2d2b006de871"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetSavedHistory (cognitive 19): Router.onMessagesGetSavedHistory has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12 (16 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_compat.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"50fe9ca4b939f1b5da6f3c5ea73eb5c3a42eb065fa9444fa422e1106ec4fb040"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesDeleteHistory (cognitive 19): Router.onMessagesDeleteHistory has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_delete.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"72e57f3d992864dfc0d627cd2d4e95db3f6492f067a63861d8779f9b9a93b466"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.inputPeerForDomainPeer (cognitive 19): Router.inputPeerForDomainPeer has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 4, match/switch 2 (3 pts) (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_helpers.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ec2dbf41fbb53be618a5c7381ab48b1b5d0b45d680d88c806617f00a0ac47a7"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetMessagesViews (cognitive 19): Router.onMessagesGetMessagesViews has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a8f820b00a44fccc00a63756c09e1c0046da1c78499f136932a8fef806572fd"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.availableReactionCatalog (cognitive 19): Router.availableReactionCatalog has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (15 pts), loops 1 (3 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_catalog.go"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"114566ec4d9bcdfbf947d17d332f7043d4bcb8bc58cc5e29cad9c5a3a3462411"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesReadMessageContents (cognitive 19): Router.onMessagesReadMessageContents has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (16 pts), loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba7696f065f9324af248d66fab00c08850848e4a15fbf8b8d46f640cc2c3baef"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsValidateRequestedInfo (cognitive 19): Router.onPaymentsValidateRequestedInfo has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":486}}}],"partialFingerprints":{"codehealthFindingId/v1":"68bf54f14479a94fa8c35541ab14606773b884c244aeb990348ad5b80738bf07"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.tgSavedStarGiftsResponse (cognitive 19): Router.tgSavedStarGiftsResponse has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (16 pts), loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1454}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c6636e649622ef22a3a478e8056ea5c7487796b117b28d4571972bba8f0f9fe"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhotosUpdateProfilePhoto (cognitive 19): Router.onPhotosUpdateProfilePhoto has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 2, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fd34ed2ce9b7c66fc8277dafa8b7bc84f44df7ec164794bd0ed952e7f7a40ea"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetStickerSet (cognitive 19): Router.onMessagesGetStickerSet has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fb29626f8452bb2c95be3d37f88a3b9a319d1b553728f438db8d887c0a1cd2e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.tgBotInfos (cognitive 19): Router.tgBotInfos has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 2 (4 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":880}}}],"partialFingerprints":{"codehealthFindingId/v1":"01b81f96063a46746af82245ce0bb6eab4608b2328ee8dee538d4e1a64fa4bce"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.welcomeDeliveryUpdates (cognitive 19): Router.welcomeDeliveryUpdates has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/welcome_delivery_dispatcher.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff30553e5d32e54c52a3ecbdbd74563033b0e33de5a8461e816972df1c54eacf"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.premiumMyBoostsLocked (cognitive 19): ChannelStore.premiumMyBoostsLocked has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 3, loops 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf776150de26631d1b6d352502d7f0aeb3ceeba6cd2bf9c58bc63a40feb5ed64"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ReorderChannelPinnedDialogs (cognitive 19): ChannelStore.ReorderChannelPinnedDialogs has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 3, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"522fade0e9e1128faf7da3b441873a34fb090a27b1e1265e2bb4996ecdfc18eb"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelInviteAdminMemberIDs (cognitive 19): ChannelStore.ListChannelInviteAdminMemberIDs has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 4, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":939}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c3bb77f678846d16eca2b0f591c1b7ce863ec8e9f431d98681597cbb18c5146"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListMonoforumDialogs (cognitive 19): ChannelStore.ListMonoforumDialogs has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 5, loops 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"a97e2bc1126951c0dc6130f1b3b025c5858e5b68d1394ced8c18136ab3fc79ee"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelUnreadReactions (cognitive 19): ChannelStore.ListChannelUnreadReactions has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 5, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec26a07a4aa36feb8a944b5117d9e912b73dc423caab3c0ce3db6d536808dc9e"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.channelMessageReactionsLocked (cognitive 19): ChannelStore.channelMessageReactionsLocked has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3, loops 3 (nesting depth added 3). Of this number, 15 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":769}}}],"partialFingerprints":{"codehealthFindingId/v1":"64292b752d9574ef02f12453175a71cf41b45f09eadb1344269da870358b87c7"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.UpdateUsername (cognitive 19): ChannelStore.UpdateUsername has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 3, loops 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"416b1dbc699cb6314619a6c598753668532e11227bc0de666df5962fe48c99d3"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteForumTopicHistory (cognitive 19): ChannelStore.DeleteForumTopicHistory has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 4, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1af152d810a6ddd01dfcf4ba6455952955d4a3f31eda82746bf2c417e0d21a8"}},{"ruleId":"D2","level":"warning","message":{"text":"ContactStore.Delete (cognitive 19): ContactStore.Delete has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 3 (6 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"dea5871df49c7f1ba22649b0975b8d707e32156e37de37aaaaa0414c0f920751"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.UnpinAllPrivateMessages (cognitive 19): MessageStore.UnpinAllPrivateMessages has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 3 (4 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"21a2ef850133c9f7336760b6041885bcc4418096233d58bc5b789565655ee6ab"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.ListSavedReactionTags (cognitive 19): MessageStore.ListSavedReactionTags has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 4 (5 pts), boolean chains 3 (nesting depth added 5). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_saved_reactions.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"4db7a0857c90fd1430476b2bb47019ec5aeb2d8e8954fb571585654dd3d22abb"}},{"ruleId":"D2","level":"warning","message":{"text":"PasswordStore.SaveMusic (cognitive 19): PasswordStore.SaveMusic has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (15 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":432}}}],"partialFingerprints":{"codehealthFindingId/v1":"1475033341bc8ea2837f365ce71c43f990d793c3a3a65e524f4b8d604728748b"}},{"ruleId":"D2","level":"warning","message":{"text":"PollStore.ListPollVotes (cognitive 19): PollStore.ListPollVotes has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 4). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/poll.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ed52e8f81ae0e970809f7da9fde7322f77cb42aecfaa41ab590cce3eb645ce8"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.SetUnsaved (cognitive 19): StarGiftStore.SetUnsaved has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (11 pts), loops 2 (5 pts), boolean chains 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"deabc0f6f027e6645d49b7258cb0358063717ad8655eae531e79265ed83fa83b"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.loadDeleteUnreadCorrections (cognitive 19): postgres.loadDeleteUnreadCorrections has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 3 (4 pts) (nesting depth added 8). Of this number, 17 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_read.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d40964cbce448ab85fc4607556068f1aec3ea918792b036c465bb3fe10169da"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.enrichPollMediaRefs (cognitive 19): postgres.enrichPollMediaRefs has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 4 (5 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/poll.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"e19dc6f442b871c9d1001f2a1634f60d6a07f78fd413f0f26f3e8c5f006c107d"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.listActiveChannelIDPages (cognitive 19): ChannelStore.listActiveChannelIDPages has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 4, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa9fea8297479984d0616f6a1fdf97dd71eec619276f98247098175033bc0931"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SearchPublicPosts (cognitive 19): ChannelStore.SearchPublicPosts has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (12 pts), boolean chains 3, loops 2 (3 pts), match/switch 1 (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"b043e9bc06ac9e65479452ba6c6b4a6cd62b24a5bbfb25069163104092ce3338"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.HideAllChatJoinRequests (cognitive 19): ChannelStore.HideAllChatJoinRequests has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 2, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_requests.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"7843a0e851dc0dd4995ff0f246a1f238687e7245e3ebc4f99340aee3febfa933"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.getLinkedDiscussionGuest (cognitive 19): ChannelStore.getLinkedDiscussionGuest has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_helpers.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"4427be25cf504b32a56969a7caef3db97f1b3a8cf9da28247c1ba855c99a3e16"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ChannelPollFanoutViews (cognitive 19): ChannelStore.ChannelPollFanoutViews has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 4, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_polls.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7f77ac4eabcd53726cb31db61d94e64768ced98b69b1a7dabe21e1244039a4c"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetChannelScamFake (cognitive 19): ChannelStore.SetChannelScamFake has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 3 (nesting depth added 2). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":294}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eff20365c275a92f23ce1e66b7c40e28ec5b5b45db3cc3d34f4e754b8bdb86a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.SetForum (cognitive 19): ChannelStore.SetForum has cognitive complexity 19 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 5 (nesting depth added 1). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d80cc6204cc7c979c9be376db1debae0c955015610090c5dc9c7b7d0631d2c0"}},{"ruleId":"D2","level":"warning","message":{"text":"EphemeralReportStore.ListUnmigratedEphemeralReports (cognitive 19): EphemeralReportStore.ListUnmigratedEphemeralReports has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ephemeral_report.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"50fe7e84c9010aff4e8638c8ddf6fc6d1116fa820d0eb570933675470aacaff1"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupCallStore.JoinGroupCall (cognitive 19): GroupCallStore.JoinGroupCall has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14 (15 pts), boolean chains 4 (nesting depth added 1). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":273}}}],"partialFingerprints":{"codehealthFindingId/v1":"1335f0058bd648e27fae1f41d08137b87d8427505dcedcddab76c1ce1797855c"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.DeleteMessages (cognitive 19): MessageStore.DeleteMessages has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 1 (nesting depth added 2). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"a85bbff52225ef0e678c1b97c17f600f06be5d0936865d6f8b527542e22dd5c2"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.setSavedMessageTags (cognitive 19): MessageStore.setSavedMessageTags has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15 (18 pts), loops 1 (nesting depth added 3). Of this number, 18 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_saved_reactions.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e21246a890ac94eb86ece79d0fa1f8ede8768dd64f62526c238c99a7423032"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.DropStarGiftOriginalDetails (cognitive 19): StarGiftLifecycleStore.DropStarGiftOriginalDetails has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 5 (nesting depth added 3). Of this number, 13 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_entitlements.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ec192bc4ddd88308308acbf9acaaeb9760ba3fde9dd3c9354fe7cb16194056d"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.SendStarGiftOffer (cognitive 19): StarGiftLifecycleStore.SendStarGiftOffer has cognitive complexity 19 (threshold 15). Drivers by points: if/else 15, boolean chains 4. Most of this is not in the body itself: 7 of the 19 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 802, 852). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":778}}}],"partialFingerprints":{"codehealthFindingId/v1":"88a27b30e7e5a629056ca21643da3410943478ccfc616e98b4928ff0f3dc18d4"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftUpgradeStore.loadAdminStarGiftGrantReplay (cognitive 19): StarGiftUpgradeStore.loadAdminStarGiftGrantReplay has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bd2ac8e443c99cda311f217013ff634f98ae792d75d3ccaf4d02703a5422b6a"}},{"ruleId":"D2","level":"warning","message":{"text":"echo.parse_args (cognitive 19): echo.parse_args has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 7, error handling 1 (2 pts) (nesting depth added 2). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"f482aca0d7657b85bf5ebb03a0ca5d253b185a293ac7776f1c7b7688b7a1e107"}},{"ruleId":"D2","level":"warning","message":{"text":"main.resolveTarget (cognitive 18): main.resolveTarget has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 2 (5 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botdemo/main.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffaa16ed1d92617eae4fb1398985a8bdfe3be4b85eedf6afe20e49df2d72a2c5"}},{"ruleId":"D2","level":"warning","message":{"text":"main.deploy (cognitive 18): main.deploy has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12 (15 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerseeddeploy/main.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"60c1d770372443737aa40e55b0931be670647232ddeaa22ceb2e2928fb98ec04"}},{"ruleId":"D2","level":"warning","message":{"text":"admin.revokeTargets (cognitive 18): admin.revokeTargets has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 3 (5 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":4092}}}],"partialFingerprints":{"codehealthFindingId/v1":"c86cba46074c3f228b30d184ff6e8b8fd883505bd3b4c7412fbb179c9874bdc6"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SetCustomVerification (cognitive 18): Service.SetCustomVerification has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":511}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ca5d55f9a46445caeec1ff79e6ebda391eab8ab7d1f4ed72a944ce232d700ec"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.resolvePeer (cognitive 18): Service.resolvePeer has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 2, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1313}}}],"partialFingerprints":{"codehealthFindingId/v1":"e79ca09bbe614788e5472ec7802025c11ca7758f8a4ac756cb075af6e4a30d7c"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.AddContact (cognitive 18): Service.AddContact has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4bfaea0565bb8d5ff3b4763be84a360c22f86afcd55b751540723ca3d4fd6b9"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.EditCloseFriends (cognitive 18): Service.EditCloseFriends has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"be1a2b63015a16593cabf000fa4427c486d0a926aaa97977827292643f693ee3"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.EditPeerFolders (cognitive 18): Service.EditPeerFolders has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (10 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":1232}}}],"partialFingerprints":{"codehealthFindingId/v1":"d91977319e4de3ee21bb69c094e40fc20088a57722bd6d57ae420a1e68a9fdae"}},{"ruleId":"D2","level":"warning","message":{"text":"files.stickerSetShortNameBase (cognitive 18): files.stickerSetShortNameBase has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 5, match/switch 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1a1f5da672e7c733912a8110bad670b63334f38d063d363e8f14b1a20b50690"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.availableReactionSeedNeedsRepair (cognitive 18): Service.availableReactionSeedNeedsRepair has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"1163d4ee29c131c4ced5aa851671a81303c45b5bbbb91569669a67f152613fb9"}},{"ruleId":"D2","level":"warning","message":{"text":"giftpack.Summarize (cognitive 18): giftpack.Summarize has cognitive complexity 18 (threshold 15). Drivers by points: loops 4 (10 pts), if/else 4 (7 pts), boolean chains 1 (nesting depth added 9). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/giftpack/summary.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd59e6cdc30d5a12b9c2f4fc281e38655f5667a8fe809bc66f37e3ba2936bcb9"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ReportPeer (cognitive 18): Service.ReportPeer has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 4, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6421ffffdb1e8cd8e20b564924e9f034062efec2bbb14dc9e6b3650695b4dbc"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.MigrateLegacyEphemeralReports (cognitive 18): Service.MigrateLegacyEphemeralReports has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/legacy.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d810810721718985ee51efdaaf4646bb70f0da8d744f209e710722c61c30d9b"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.GetDifference (cognitive 18): Service.GetDifference has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbd1b0b1db5c3c316a2d10d5241dc285e84493160c0d64b8150c48a92387adab"}},{"ruleId":"D2","level":"warning","message":{"text":"CachedContactStore.loadSparseContactProjection (cognitive 18): CachedContactStore.loadSparseContactProjection has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 3 (5 pts), boolean chains 1 (nesting depth added 8). Most of this is not in the body itself: 8 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 121). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache_sparse.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa5cd2de04d185d28878c6b66c1c7cf6e9e7dc295c6aa312722f289be79707c5"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.replyMarkupFromAPI (cognitive 18): botapi.replyMarkupFromAPI has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 3, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bb2e0a0281cf22da320c2870851f7bbb54891997bf45a2b42e78b56dc18964e"}},{"ruleId":"D2","level":"warning","message":{"text":"botapi.markupButtonFromAPI (cognitive 18): botapi.markupButtonFromAPI has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16 (17 pts), boolean chains 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"f70f7203f5a290a033aed69d916881eef4fee9ff2dadbdfcf5de2ca483ee81f3"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.getWebhookInfo (cognitive 18): handler.getWebhookInfo has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 1 (4 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":454}}}],"partialFingerprints":{"codehealthFindingId/v1":"d775773e9ac789fda80086e30cceb8e86d58b80a67da6e573f76b3ab3f26de18"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.sendRichMessage (cognitive 18): handler.sendRichMessage has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 4 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"c458b1f4c2cbad102de27b4ff200f3a873877f95250ff29b34b9bedaec80347e"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.setUserEmojiStatus (cognitive 18): handler.setUserEmojiStatus has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 4 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1162}}}],"partialFingerprints":{"codehealthFindingId/v1":"eed5d9badf8bea6147754dda6aa54233ea34de6ce139d3052afc78e66c5902f0"}},{"ruleId":"D2","level":"warning","message":{"text":"config.validateBlobStorageConfig (cognitive 18): config.validateBlobStorageConfig has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 3, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1575}}}],"partialFingerprints":{"codehealthFindingId/v1":"559f5d92ea46753735fc809f2f57e7535970ed76a229cb91ea73c36326b4951b"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.BusinessBotRecipientsMatch (cognitive 18): domain.BusinessBotRecipientsMatch has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 4, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/business.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"292ea96038b5c66694138b2bfefe65f42bf643bbf14acded996859e7beb88ac5"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.ValidatePollVote (cognitive 18): domain.ValidatePollVote has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 3, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/poll.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"14184e02a230a32c3675bac9d2cd64747de5da2b0ea0df7b6e4cd4ace9739bfc"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.validateVerificationHost (cognitive 18): domain.validateVerificationHost has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (7 pts), boolean chains 5, loops 2 (3 pts), match/switch 1 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/verification.go"},"region":{"startLine":465}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fe223496a366e9ce49f7a1346cac5b8f43c8908b15e69c3dfe9e893618349c1"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.provisionPhase (cognitive 18): loadharness.provisionPhase has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 4 (5 pts), match/switch 1 (2 pts) (nesting depth added 6). Of this number, 10 points are the body\u0027s own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/provision.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"950e6a5c986f4b7c7ca3dfe357eff3457049ff94cb5708b89217f71d0d3fbec1"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.runFixedMessageSchedule (cognitive 18): loadharness.runFixedMessageSchedule has cognitive complexity 18 (threshold 15). Drivers by points: match/switch 4 (9 pts), if/else 4 (6 pts), loops 2, boolean chains 1 (nesting depth added 7). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1032}}}],"partialFingerprints":{"codehealthFindingId/v1":"f49129189ac6a5701077ee12be5f7491db65676c79ddd58399eeba7e6252f6b1"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.botAPIRichText (cognitive 18): rpc.botAPIRichText has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 1 (2 pts), match/switch 1 (nesting depth added 8). Of this number, 16 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"423d8a02b1e70766905b59ff5bb6314faaba0be70619b1123675211a456bd200"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.domainOutgoingReplyMarkupForSender (cognitive 18): rpc.domainOutgoingReplyMarkupForSender has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 2 (5 pts), boolean chains 1, match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdd010f447abd7cf015ad1c39b3a299ab1de002e187fed820319e424b3b5e7a0"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgMessageReactions (cognitive 18): rpc.tgMessageReactions has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":515}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4b9a5bccc7e03f67ce9ee1730a94aae717e42f96c1700910cb8219e70d22581"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.validateStoriesGetAllStoriesRequest (cognitive 18): rpc.validateStoriesGetAllStoriesRequest has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"a77e1de0741f9e733bed2c33f32b8e83f23fb5df9a48b4200361b1709eb2d922"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.validateStoryCaptionEntities (cognitive 18): rpc.validateStoryCaptionEntities has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 2, match/switch 1 (2 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1463}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ecd6cf96a6447a1098164ae87f992aabf22c130147b3329f9d55fb863ae935a"}},{"ruleId":"D2","level":"warning","message":{"text":"presenceLastSeenBatchDispatcher.executeWithRetry (cognitive 18): presenceLastSeenBatchDispatcher.executeWithRetry has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (10 pts), match/switch 2 (6 pts), boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence_last_seen_batch.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e2a4eecf45d12da9a8674ffb98a5b7d1d5990f420dc9976ca4b2d4cc3662796"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.registerAccount (cognitive 18): Router.registerAccount has cognitive complexity 18 (threshold 15). Drivers by points: if/else 18. None of this is in the body itself: all 18 points belong to 10 function literals inside it that branch (lines 281, 298, 311, \u2026). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"e118c7be3dc79a84fecd6b59f50be7e796d3ed93d9b30ab66737f5c533b85c56"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.BotAPIEditRichMessage (cognitive 18): Router.BotAPIEditRichMessage has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":875}}}],"partialFingerprints":{"codehealthFindingId/v1":"02cc59d14cf63e21c899372355d30d31685526138e35a4ba2856f633fd7ba6b5"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesCreateChat (cognitive 18): Router.onMessagesCreateChat has cognitive complexity 18 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a3a244e504c79a493a606e20518e6c501868896e71d779f80fc5b54c8018a21"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSetChatTheme (cognitive 18): Router.onMessagesSetChatTheme has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea10a8ccc478187f9ced49032f24409b0fb94918e9227b478dce44b119dd9c00"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onFoldersEditPeerFolders (cognitive 18): Router.onFoldersEditPeerFolders has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 1, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/folders.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9c0235317c6fd7cc2630f64872f3569d387d82cd486e823c27f833ac801ac2c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.resolveAuthKeyLayerDefault (cognitive 18): Router.resolveAuthKeyLayerDefault has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13 (17 pts), boolean chains 1 (nesting depth added 4). Most of this is not in the body itself: 7 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 466). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_inheritance.go"},"region":{"startLine":453}}}],"partialFingerprints":{"codehealthFindingId/v1":"e58ff1869717f99a97a7815f1de7f401ea28de927b0d9fa3d5ab90bf9cc267bb"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesMarkDialogUnread (cognitive 18): Router.onMessagesMarkDialogUnread has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12 (18 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":843}}}],"partialFingerprints":{"codehealthFindingId/v1":"e51bf60a190ff63aa6431b96cb12f40a1131a18fbb72263b7fa860801ebefdf6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.forwardSourcesFromPrivateMessages (cognitive 18): Router.forwardSourcesFromPrivateMessages has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 2, loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":687}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5779e7953b5609daca7849f3302c412fdc7592f273ca57047139198210f3bc9"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.updatePrivatePinnedMessage (cognitive 18): Router.updatePrivatePinnedMessage has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_pin.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f46b01e433305802f04edbe03aa8a996a1f5ae95d5fe1bff4c133ee01fc09d7"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSendVote (cognitive 18): Router.onMessagesSendVote has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 1 (2 pts), boolean chains 1, match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"e548100bf887f07c644f99082623e8fa36e85db85bedd4d0013e3ec4d1cc8bcb"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetUnreadReactions (cognitive 18): Router.onMessagesGetUnreadReactions has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_lists.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"c34c207ed48b5618ad48ff652749c718821697d5b0fc73f94fabe65e1df061d7"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.validateDefaultReaction (cognitive 18): Router.validateDefaultReaction has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2 (4 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_privacy.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"07015b867364952bfbad0e4b4fe08304c2c68bcc6fecc5cf26165a5a90f0a5d3"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.mutateTodoMedia (cognitive 18): Router.mutateTodoMedia has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 6 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_todos.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"172d69cca1011f69715312af001b2cf158221f97d352f12dd5babebf5437e582"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSetHistoryTTL (cognitive 18): Router.onMessagesSetHistoryTTL has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 4, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_ttl.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe9adeae32e39b7983f938ffc2ae0ab5dddf80e7e28aa615178f548e8c9df7a6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsUpdateStarGiftPrice (cognitive 18): Router.onPaymentsUpdateStarGiftPrice has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 4, match/switch 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":565}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8ff47483e825fbf19f8b54dee72597fc6b03aecc9877832aed0300cdee072dc"}},{"ruleId":"D2","level":"warning","message":{"text":"storySparseProjectionCache.activePeers (cognitive 18): storySparseProjectionCache.activePeers has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (11 pts), loops 5, boolean chains 2 (nesting depth added 3). Of this number, 16 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_sparse_projection_cache.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c4b239893b3a2f821b3783c9f29a1cddde5f3d044e0ba3bbaf71768c21e95ae"}},{"ruleId":"D2","level":"warning","message":{"text":"BatchedReverseContactStore.execute (cognitive 18): BatchedReverseContactStore.execute has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 5 (8 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bff4110fca72c2e8e6f4902960f17136d7747cd540ccacdf7f95ca2c368a931"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.channelDialogAfterOffset (cognitive 18): memory.channelDialogAfterOffset has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 4 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"b28743434443e1a5a0f644ea32ff81bbfe4c7cb2f3651e82373ac103114fc647"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.dialogMatchesFolder (cognitive 18): memory.dialogMatchesFolder has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 6 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"49b42739bd08d0d92a0f848e9667eda2674d00d8b0b605fc99c86593e66c433e"}},{"ruleId":"D2","level":"warning","message":{"text":"AuthKeyStore.AdvanceSessionLayer (cognitive 18): AuthKeyStore.AdvanceSessionLayer has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/authkey_session_layer.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"70d461aa843b95823f8cb6789055263b5d7c6e01b0fa0584fed82b8eeee1e55b"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListCommonChannels (cognitive 18): ChannelStore.ListCommonChannels has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 5, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"4340f3841023e281f6ac8b2aadbd4f47cc61346ee107fc741aa72c395d79344b"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListActiveChannelIDsForUser (cognitive 18): ChannelStore.ListActiveChannelIDsForUser has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 5, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":281}}}],"partialFingerprints":{"codehealthFindingId/v1":"f707d488d31cb67a427ef939113e54a848a4fc39222bc70eba052bef7d199b6f"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.channelForViewerLocked (cognitive 18): ChannelStore.channelForViewerLocked has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 6 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b72cbb4dc92dbfdbf4365ac8768ad423da891ddbf842188fbe8bca91f5518c9"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ReorderPinnedForumTopics (cognitive 18): ChannelStore.ReorderPinnedForumTopics has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4519d80b2cb006736e6d0408b4e3741cf91a9495244fcf036e2a3c53a14608f"}},{"ruleId":"D2","level":"warning","message":{"text":"DialogStore.ReorderPinned (cognitive 18): DialogStore.ReorderPinned has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 3, loops 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"2eb46a687228b98c7db5559e06261c2a057d95125c695e25ef047232723e309b"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupCallStore.SweepStaleParticipants (cognitive 18): GroupCallStore.SweepStaleParticipants has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 3 (5 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":500}}}],"partialFingerprints":{"codehealthFindingId/v1":"965997a35120821d4c8cdecdd0c27bd9a0b961ff85e38c8cf3f5cc1feca28977"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.SubmitModerationAppealByLink (cognitive 18): ModerationReportStore.SubmitModerationAppealByLink has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 5, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":690}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ea9b38c5b660a34d8c535a01d838eea1e5cd84261ec03b0ceee5e2e1a6ce453"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.UpdateCollection (cognitive 18): StarGiftStore.UpdateCollection has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (13 pts), loops 3, boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":656}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4b4afa90704c0bc3d6aef077799c3915799e3c364d76534e716de0dab0bf81d"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.channelDialogAfterOffset (cognitive 18): postgres.channelDialogAfterOffset has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 4 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":2174}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fede23be1dddd5f7c8053a79660fc4de50a8dc833b1ebf1453c2f52c8c4836c"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.validateAppealSanctionOwnership (cognitive 18): postgres.validateAppealSanctionOwnership has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (14 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":934}}}],"partialFingerprints":{"codehealthFindingId/v1":"f786a127b87e498a5420d6b72b86a31385b6e2df98ee968d0856c168e6c868b1"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.premiumMyBoosts (cognitive 18): ChannelStore.premiumMyBoosts has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"f49038bebb389f0aa8cdcf4b9f7224e8bdedc9d217c3b8789e50f61bf88ec936"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListDirtyActiveChannelsForUser (cognitive 18): ChannelStore.ListDirtyActiveChannelsForUser has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (13 pts), loops 3, boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":368}}}],"partialFingerprints":{"codehealthFindingId/v1":"eafbd77cd9692475f0e4801eb5d4e4516370b3266e73d7814ef4cfd5057920fc"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.HideChatJoinRequest (cognitive 18): ChannelStore.HideChatJoinRequest has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15 (17 pts), boolean chains 1 (nesting depth added 2). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join_requests.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaa635ef10532a65f2c8688f3f9e23d03882a461d67ab175bbe090dd2e7065ee"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.UnpinAllChannelMessages (cognitive 18): ChannelStore.UnpinAllChannelMessages has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15 (16 pts), boolean chains 1, loops 1 (nesting depth added 1). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d5fe1e8a170ef13e11e1f6f764ae970c78bba991d3a3006cac856f0670db9b4"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListStoryMessageForwards (cognitive 18): ChannelStore.ListStoryMessageForwards has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 2, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":583}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbe62018fd18e76bd493bf7bb1385f604e16673dddbfb244701b2b4da16e4ebb"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelMessageReactions (cognitive 18): ChannelStore.GetChannelMessageReactions has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 2, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"632ced6d6e756c8f2f424875e50c0fa76a5ed101835faeda3c32c989f2992090"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.GetMessageReactions (cognitive 18): MessageStore.GetMessageReactions has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 3, loops 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"2edd66d50957a53463cecda194453cab1c2c434560ca320209d9cace54e96449"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.IssueModerationAppealLink (cognitive 18): ModerationReportStore.IssueModerationAppealLink has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 4 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":447}}}],"partialFingerprints":{"codehealthFindingId/v1":"571868f886cefb8758a7af5d5d7fc72e6befbb07a9fabf198993802d49f49dd8"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.CreateSponsoredModerationReport (cognitive 18): ModerationReportStore.CreateSponsoredModerationReport has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15 (17 pts), boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"33c243315e413e2a93ddb73d5790acef5f7a455021dc0f82356d1957f99e5f99"}},{"ruleId":"D2","level":"warning","message":{"text":"postgresAdmissionController.reserve (cognitive 18): postgresAdmissionController.reserve has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/postgres_connection_admission.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"41662ce9c0e8274ec64a3614dd3ce72f9e99b3f081066757fdae9cf397a300b6"}},{"ruleId":"D2","level":"warning","message":{"text":"UserStore.SetScamFake (cognitive 18): UserStore.SetScamFake has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 2 (nesting depth added 4). Of this number, 17 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":658}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff2f2dc2dca3d2eac3899a4d042a349a3a5fe9dacdf7c6a7ac4a2f28b3208d57"}},{"ruleId":"D2","level":"warning","message":{"text":"VerificationStore.RevokeVerification (cognitive 18): VerificationStore.RevokeVerification has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 1, match/switch 1 (nesting depth added 4). Most of this is not in the body itself: 6 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 603). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":584}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6079a726626f5e14f1f134beb2655d2b91968c885eb72f8817164c77315b5fe"}},{"ruleId":"D2","level":"warning","message":{"text":"BatchedReadModelVersionStore.execute (cognitive 18): BatchedReadModelVersionStore.execute has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 5 (8 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/read_model_batch.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"74d19a4b84c929259d0192fa5749ff0e352d3b8856aad94d469e4e20f56e710d"}},{"ruleId":"D2","level":"warning","message":{"text":"server.callAdminCollectibleMultipart (cognitive 17): server.callAdminCollectibleMultipart has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 1, loops 1 (nesting depth added 3). Of this number, 12 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/star_gift_catalog.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"8498fb2d26c4638c74448315a423255973f24722c69ada489e936bdd5cd9c6ba"}},{"ruleId":"D2","level":"warning","message":{"text":"main.parseWebAppSession (cognitive 17): main.parseWebAppSession has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"de5c0554a22dd4c1f44f1643f7837701a45e834a6a11f00fefed09e2da372068"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.DeletePrivateHistory (cognitive 17): Service.DeletePrivateHistory has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 4, loops 1 (nesting depth added 2). Most of this is not in the body itself: 8 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 3249). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3233}}}],"partialFingerprints":{"codehealthFindingId/v1":"852e75dc06174f86cf9085d80dfcd72d4bb57c596aab435e05aee964b62e9373"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.RevokeVerification (cognitive 17): Service.RevokeVerification has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 3 (nesting depth added 1). Most of this is not in the body itself: 7 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 272). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/verification.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b30706dab2483b6f7bca69d4e186bc2dfea152cae7ec20977fb73d6394cc87e"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.UpdateTone (cognitive 17): Service.UpdateTone has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":240}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7a2955cf97b7e07657707107f90ab4a4910eca3e7dc9d97002bb65482783d1d"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ConsumeLoginEmailReset (cognitive 17): Service.ConsumeLoginEmailReset has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, boolean chains 5. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":999}}}],"partialFingerprints":{"codehealthFindingId/v1":"7775d1196a37a9376364ab2130a1e12ffe56a16a20088cb9da4069ab7f496068"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.bind (cognitive 17): Service.bind has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1625}}}],"partialFingerprints":{"codehealthFindingId/v1":"0683cc9a918fa954478bf319a2f223a950f2b7182fcf723da8ffc5aec1827858"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.submitVerifyApplication (cognitive 17): Service.submitVerifyApplication has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifybot.go"},"region":{"startLine":648}}}],"partialFingerprints":{"codehealthFindingId/v1":"143185eb5f410714c9855ea238c8c772fdc924e6bd178cd89cfa4dbbfc26b784"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.SendMessage (cognitive 17): Service.SendMessage has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1430}}}],"partialFingerprints":{"codehealthFindingId/v1":"061f848b01fc4eb464eabc1efc8bbcfc10dcf0a9e131a625ffce349704faf0f8"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.maybeFaststartVideoBlob (cognitive 17): Service.maybeFaststartVideoBlob has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 4 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":551}}}],"partialFingerprints":{"codehealthFindingId/v1":"303c44cf3a19e5a2b41312963e1fd0bfe53990d9b223da14d4caa03221fb5320"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.EvictOldestMediaOverBudget (cognitive 17): Service.EvictOldestMediaOverBudget has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (10 pts), loops 2 (3 pts), boolean chains 2, match/switch 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"b812299734f3880d3aec8738d7cbdec3ae2e946ca3377ce316d97fab4d57972d"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.importStickerSetDir (cognitive 17): Service.importStickerSetDir has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 1, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a8b9f8f5535b9d3bcd02fd7475c327dc014d1d0d352a55cd855f8c69ac9a4ee"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ReviewAppeal (cognitive 17): Service.ReviewAppeal has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 4, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/cases.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"db888e20850cd12a7f11365658b04640c5418d732d93214b0783fbd75f560290"}},{"ruleId":"D2","level":"warning","message":{"text":"stargifts.prepareAnimationWithPolicy (cognitive 17): stargifts.prepareAnimationWithPolicy has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 5 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/animation.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"575411d4e20d643c527dd80f2e1ac90185fc909e01d4d67c389223584c5972a6"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.deepLinkToken (cognitive 17): Service.deepLinkToken has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 10, if/else 5 (6 pts), match/switch 1 (nesting depth added 1). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":914}}}],"partialFingerprints":{"codehealthFindingId/v1":"77481ae48d2fc24abaa8742bbee2916c44db60797e01b370b1346984f7c7d2a7"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ByIDsForViewerUserIDs (cognitive 17): Service.ByIDsForViewerUserIDs has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service_sparse.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6874814a64df03346df755b5655e6d94e774043597979b6265dca7e2e8f32dc"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.controls (cognitive 17): Service.controls has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 1 (2 pts), match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":1044}}}],"partialFingerprints":{"codehealthFindingId/v1":"88ee78aa56d942b5232b463449bdb25db7bb087e9c3860268160529f801cf22e"}},{"ruleId":"D2","level":"warning","message":{"text":"config.validateTelegramLoginConfig (cognitive 17): config.validateTelegramLoginConfig has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 5, loops 1, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1680}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6cfe4f3b33147375257a1bad9db739948cccba7ce361da68810e48846064677"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.DetectAutomaticMessageEntities (cognitive 17): domain.DetectAutomaticMessageEntities has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (7 pts), loops 6, boolean chains 4 (nesting depth added 2). Of this number, 10 points are the body\u0027s own statements and 7 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc63c7584ed12eb6d811ecc7e5708e632558e0511b097563bb6ab60fc8c809f2"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.detectCashtagMessageEntities (cognitive 17): domain.detectCashtagMessageEntities has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (8 pts), boolean chains 6, loops 2 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"afbce982a27c6bf88cc10cf1e4f591592f459ba14fd84ef903ffabc831f661d3"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.publicVerificationIP (cognitive 17): domain.publicVerificationIP has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 8, if/else 5 (7 pts), match/switch 1 (2 pts) (nesting depth added 3). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/verification.go"},"region":{"startLine":502}}}],"partialFingerprints":{"codehealthFindingId/v1":"b96ea2be074b246fd54d3b5d09654ba91e0d2adc0a6fa73198d73370de2d348b"}},{"ruleId":"D2","level":"warning","message":{"text":"layerRPCGZIPExpansionBudget.expand (cognitive 17): layerRPCGZIPExpansionBudget.expand has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7893d1dc060f8835e091449ad587c15eac57133ecf84a24073c9a63be59281b"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.ClearInheritedLayerForRawAuthKey (cognitive 17): SessionManager.ClearInheritedLayerForRawAuthKey has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"4899825b9689451b8fe864bbc7e784c252b2707b39c55945998da65632c47964"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.SeedInheritedLayerForBusinessAuthKey (cognitive 17): SessionManager.SeedInheritedLayerForBusinessAuthKey has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"73d1db92ef2e73c58c402e66e7bb45fb75c03ef06722d785955cf55b326b1453"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.pushToBusinessAuthKeyBestEffort (cognitive 17): SessionManager.pushToBusinessAuthKeyBestEffort has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 4 (nesting depth added 2). Of this number, 10 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition. This shape REPEATS in the file: one other method here (SessionManager.pushToUserBestEffort) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1635}}}],"partialFingerprints":{"codehealthFindingId/v1":"b20a4362e907e856ca47659740d6f7e8eec6984536ab8ec93086928be2d7455c"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.pushToUserBestEffort (cognitive 17): SessionManager.pushToUserBestEffort has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 4 (nesting depth added 2). Of this number, 10 points are the body\u0027s own statements and 7 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition. This shape REPEATS in the file: one other method here (SessionManager.pushToBusinessAuthKeyBestEffort) has the same decision points, in the same order, at the same nesting depths \u2014 so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1801}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d953f1d6b0956239ebc16de645766e808950e0e1a886ea31ae2a81f7ed24992"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.onlineChannelSubscriberUserIDsExcluding (cognitive 17): SessionManager.onlineChannelSubscriberUserIDsExcluding has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2214}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfee909b7df0ade6af0c063b6d50b65e561d75c297fc3aa8d04fdb7f70df5778"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.domainSuggestedPost (cognitive 17): rpc.domainSuggestedPost has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_suggested_post.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bb95479cc32aae424ff0a9d50c59ce590858adfc2bad8f2e0fb75d7f58aa676"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgBoosts (cognitive 17): rpc.tgBoosts has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (16 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/premium.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"55dbf1f653f4b0ac04213701cc802b1f53c35ba6b3b1bddfa80fa5d40a1f278d"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.validateStoryInputMediaClass (cognitive 17): rpc.validateStoryInputMediaClass has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (16 pts), match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2966}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bc73d56b115c919af0e3bc5acbdf617153af0a747bdc2092199c20d29f370ec"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onAccountGetThemes (cognitive 17): Router.onAccountGetThemes has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (11 pts), loops 1 (4 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_themes.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"53436873347693aa09488f1c3a37c812c782179fd1051df8df890ad706466617"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.fanoutStoryBlocklistChange (cognitive 17): Router.fanoutStoryBlocklistChange has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2c945005717069a2e4bbc7c0cf194424992cb7c682282bf82c62ba787ce9399"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.snapshotLayerRPCWrapperEffects (cognitive 17): Router.snapshotLayerRPCWrapperEffects has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 4, match/switch 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_dispatch.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"28da7978910566162581c5b0f0c5e2004ec04d457e383b5e33d45d16b1a9adc7"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesToggleBotInAttachMenu (cognitive 17): Router.onMessagesToggleBotInAttachMenu has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_attach_menu.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"b44e56e629d6e4a18e8ce656df550ad55756c8f7b83e5e0e30f6851b76bbcff7"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.dialogDraftFromSaveDraft (cognitive 17): Router.dialogDraftFromSaveDraft has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"01fca68bdcdf94c46604ffb1e83b2a53de72224d10197ab6793d4bdbd2ca9693"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetForumTopicsByID (cognitive 17): Router.onMessagesGetForumTopicsByID has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 2, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"b262213ec46c8b0942ab403955d820c55050de405539967fbee4cac2afe793d4"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSetTyping (cognitive 17): Router.onMessagesSetTyping has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_helpers.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab48b86caa853cd3a7878918d4209dd31a71719ed80872cd71cbf0163bc10057"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.resolveMonoforumForAdmin (cognitive 17): Router.resolveMonoforumForAdmin has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_monoforum.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"1553f7c3778f1bb0f38819727e1f70734434f6c65b10023b2fbdf4b9c404ea45"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesReadReactions (cognitive 17): Router.onMessagesReadReactions has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 5 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_lists.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f7a571c8315732fabb6d34cf5b31035112453f3e93fc5c5102a5c6b8f6a4474"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.suggestedPostApprovalUpdatesWithPeerCacheAndOverlaysStrict (cognitive 17): Router.suggestedPostApprovalUpdatesWithPeerCacheAndOverlaysStrict has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_suggested_post_updates.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"450eb9f0ed081ae434c9fe344e1432e2fb79c5661499396054d45b7860fae53c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsGetPremiumGiftCodeOptions (cognitive 17): Router.onPaymentsGetPremiumGiftCodeOptions has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 2, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_premium.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"6801d7ad64dcfb37ae7d197ba896f7b1b9d3f69e93e46917a70be487d75745d5"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.storyProjectionMaps (cognitive 17): Router.storyProjectionMaps has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 1 (3 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_projection_cache.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"6812dd16e33772ebb4171139a1a024a92205e4a83027b0a39b9f30a4be7b307c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onAccountGetWebAuthorizations (cognitive 17): Router.onAccountGetWebAuthorizations has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (13 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":345}}}],"partialFingerprints":{"codehealthFindingId/v1":"66fff78e584d4de610e1e86621fceb36608721baa433502546494629ab6d5685"}},{"ruleId":"D2","level":"warning","message":{"text":"AccountRatingStore.ListAccountRatings (cognitive 17): AccountRatingStore.ListAccountRatings has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 2, match/switch 1 (2 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/account_rating.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"0683093848cbf488a117e47c722defd1d1740836e87ea494e3a942c1a7a4ec77"}},{"ruleId":"D2","level":"warning","message":{"text":"BotStore.UpsertBotApp (cognitive 17): BotStore.UpsertBotApp has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 5, loops 1 (2 pts) (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"327d4e241e15e7f1fb9c5e3bc4991ade004bed128001ae2d06cdb9fa15db5918"}},{"ruleId":"D2","level":"warning","message":{"text":"BotAPIUpdateStore.ListTailBotAPIUpdates (cognitive 17): BotAPIUpdateStore.ListTailBotAPIUpdates has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 4, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"25722fd7b0b5f6cd6cc254853484b2d9df53c21510bbccf4a993a17fda81db50"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListInactiveChannels (cognitive 17): ChannelStore.ListInactiveChannels has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 4, loops 2 (nesting depth added 3). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"21441e5ed965e90e5b54a70bcade6a6d1db96c755e895f2d30e24deabee2768a"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EditChannelPeerFolders (cognitive 17): ChannelStore.EditChannelPeerFolders has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 3, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"00704a652bd77665c668ab907929c56a877b65cac2465edb8664eee79d0507b6"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.FilterChannelMessageAudienceIDs (cognitive 17): ChannelStore.FilterChannelMessageAudienceIDs has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 6, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":949}}}],"partialFingerprints":{"codehealthFindingId/v1":"57a3a838558cc3baf6669601cd7b7d849a798145323298e2bfeeb27ac14317d0"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetDiscussionMessage (cognitive 17): ChannelStore.GetDiscussionMessage has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"e382f3b19aa633790ab835b60a9a27626e324bece36273d764e9c485b5aa80fd"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelMessageReactions (cognitive 17): ChannelStore.GetChannelMessageReactions has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 3, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":286}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb1982de4f8b36b7e15ea0c3bc9e1ad2c26a1a729164c7d3ae48fffc34646f23"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelRecommendations (cognitive 17): ChannelStore.ListChannelRecommendations has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 4, loops 1 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":638}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cbfe79408507c155c93342de6966c9371359d81b7812a84beca26a2ece78b4d"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.GetChannelMessageStats (cognitive 17): ChannelStore.GetChannelMessageStats has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (8 pts), loops 4 (5 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"87fc762c45b7890dba94bf4f11ae67a111f4f7fa7462b3c986292e3af364d83a"}},{"ruleId":"D2","level":"warning","message":{"text":"CollectibleUsernameStore.ListCollectibleUsernames (cognitive 17): CollectibleUsernameStore.ListCollectibleUsernames has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 5, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/collectible_username.go"},"region":{"startLine":563}}}],"partialFingerprints":{"codehealthFindingId/v1":"849e137c4857c3e75802e90a4dfcf298636f31d82c7b0bdbe5449fd5ae78fbae"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ToggleCommunityPeerLink (cognitive 17): CommunityStore.ToggleCommunityPeerLink has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (17 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"f83e9a333495a4c813ec0fc324e078eb91deb8d75add4bfad9c19d707e7f6981"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupCallStore.JoinGroupCall (cognitive 17): GroupCallStore.JoinGroupCall has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 5, loops 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"3305501473093f9f08ccf1bc9f98f85d45d14baec3a9c2df114c9434976af4e1"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupCallStore.ListParticipants (cognitive 17): GroupCallStore.ListParticipants has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 5, loops 2 (nesting depth added 3). Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":391}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa327481a1307d5693b834d40472ba3cae4b482d24891f3c723b9e52ff3d2c4e"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.setSavedMessageTagsLocked (cognitive 17): MessageStore.setSavedMessageTagsLocked has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 2, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_saved_reactions.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"8df5c831f73a89d32bcf072fbe948fdfe80fe9bdb2c63b6a8c37f5c3cdf35fc9"}},{"ruleId":"D2","level":"warning","message":{"text":"TelegramLoginStore.PutTelegramLoginAuthorizationCode (cognitive 17): TelegramLoginStore.PutTelegramLoginAuthorizationCode has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 6, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"188971416bb6b2734575f9af8c4416129df7fbb9b185351739973ec0d4634e7c"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.privateMessageReactionsFromRows (cognitive 17): postgres.privateMessageReactionsFromRows has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (12 pts), loops 3, boolean chains 2 (nesting depth added 3). Of this number, 13 points are the body\u0027s own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a35df6661d371a40b3ab3f57afb0ab7ef837daf97ffca15236862bca9d78535"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.persistPlainPrivateSendProjection (cognitive 17): postgres.persistPlainPrivateSendProjection has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12, boolean chains 5. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_hotpath.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"7406a1187dc8d792ec23da00c34d031b7efe66b9b364eb1d8869c6f8bc88553c"}},{"ruleId":"D2","level":"warning","message":{"text":"PasswordStore.GetPeerNotifySettings (cognitive 17): PasswordStore.GetPeerNotifySettings has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (15 pts), loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"6958b029d654fc1d2544d825a095804eceae6f3bd11df95c6156c15969ea5b37"}},{"ruleId":"D2","level":"warning","message":{"text":"PasswordStore.ListNotifyExceptions (cognitive 17): PasswordStore.ListNotifyExceptions has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e135614e9f037c9033686dfd8905a1c44cd71e70ec4899857ad9fdca9d473f8"}},{"ruleId":"D2","level":"warning","message":{"text":"BotVerificationStore.GrantCustomVerification (cognitive 17): BotVerificationStore.GrantCustomVerification has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12 (14 pts), boolean chains 2, match/switch 1 (nesting depth added 2). Most of this is not in the body itself: 7 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 553). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"10e0d1b0dc0717272a6ee5b83c161fe2d7ea61bc3514e68788371cac06090694"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListAdminLog (cognitive 17): ChannelStore.ListAdminLog has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 2, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_admin_log.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"093b302adbd140993995c8e46a319865402f2a5b3ec100cdb308776ec8325220"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.getChannelForViewer (cognitive 17): ChannelStore.getChannelForViewer has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"647a5aa7c28ed4c7396503ab9d3e709f42fded3bf3c73d06962bd669712a65b5"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.UpdatePinnedMessage (cognitive 17): ChannelStore.UpdatePinnedMessage has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2. Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6b296dc8add2aac0e3c2209abf43913801f386122c1b39f47198de92b67bb59"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.mutateChannelMessagePoll (cognitive 17): ChannelStore.mutateChannelMessagePoll has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 3. Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_polls.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fb212f10b61518b6dd8d9d2c0c259c9331ffac3f32896dfdeb6f653e4431a80"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteChannelParticipantReaction (cognitive 17): ChannelStore.DeleteChannelParticipantReaction has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2. Of this number, 16 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"c423edfdaadd23106f4ef04254d03465e8bf322845ab973ba674d4ee31fc87ee"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListMessageReadParticipants (cognitive 17): ChannelStore.ListMessageReadParticipants has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (11 pts), boolean chains 5, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":413}}}],"partialFingerprints":{"codehealthFindingId/v1":"e846280baa9cdf34765facd6c9e82379cdab031b4e0d563b0d3793e619127d72"}},{"ruleId":"D2","level":"warning","message":{"text":"CollectibleUsernameStore.TransferCollectibleUsername (cognitive 17): CollectibleUsernameStore.TransferCollectibleUsername has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2. Most of this is not in the body itself: 4 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 308). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":294}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a8608b2c7ca566f050d93d68ef5f70718fde1664c39c87a7e701dd661b4e5e1"}},{"ruleId":"D2","level":"warning","message":{"text":"ContactStore.ContactProjectionForViewerUserIDs (cognitive 17): ContactStore.ContactProjectionForViewerUserIDs has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (15 pts), loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3df9a94b27c5a423bd3a349020fe53555ebb732aa418354bec197eba97f6ca9"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.CreateModerationAppeal (cognitive 17): ModerationReportStore.CreateModerationAppeal has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, boolean chains 4. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"8767e3861b6c8e65cdff8ce888a51382be3df711d0482b93f5c4978c24e7bb86"}},{"ruleId":"D2","level":"warning","message":{"text":"ModerationReportStore.CreateAntiSpamFalsePositiveReport (cognitive 17): ModerationReportStore.CreateAntiSpamFalsePositiveReport has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"108f8e68ce6c083b3bef28306a259eed430d0d6e9ce406e0d5371feebe2f1eae"}},{"ruleId":"D2","level":"warning","message":{"text":"PremiumStore.RefundPremiumPayment (cognitive 17): PremiumStore.RefundPremiumPayment has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, boolean chains 3. Most of this is not in the body itself: 4 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 633). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c0372c35d70720efc37d325c5d3f7cb25beeb26fd5f4c84f77bd8e9fa5966c0"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.ListCraftStarGifts (cognitive 17): StarGiftLifecycleStore.ListCraftStarGifts has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 2, loops 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"422e7fc15cc95e300352d20853ca8600b511ce656cdaffa00dc4f497d97a1c03"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.debitLifecycleAmount (cognitive 17): StarGiftLifecycleStore.debitLifecycleAmount has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (17 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1319}}}],"partialFingerprints":{"codehealthFindingId/v1":"f77063343eaf29497f64cb9acddfc139824cc3242198dad8717165d190469624"}},{"ruleId":"D2","level":"warning","message":{"text":"StoryStore.ListStoryViews (cognitive 17): StoryStore.ListStoryViews has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 3 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1188}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ef98a20b35cde4c08be63dab254722f6bba89762040f67594cc112f4012a03a"}},{"ruleId":"D2","level":"warning","message":{"text":"UpdateEventStore.DeleteConfirmedPrefix (cognitive 17): UpdateEventStore.DeleteConfirmedPrefix has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 1, loops 1 (nesting depth added 6). Of this number, 15 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event_retention.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff5129f8f284bf2cb062a3f8159f63b7b817f525e12add280a769e7cd5389776"}},{"ruleId":"D2","level":"warning","message":{"text":"WelcomeMessageStore.CreateWelcomeMessage (cognitive 17): WelcomeMessageStore.CreateWelcomeMessage has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14 (15 pts), boolean chains 2 (nesting depth added 1). Most of this is not in the body itself: 4 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 47). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d4679db075dfbe5aa6d8ec2141a0622fbf36e89804007a834e8d1f3817dbf8b"}},{"ruleId":"D2","level":"warning","message":{"text":"Handler.inApp (cognitive 17): Handler.inApp has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"b654592e80e9c5057fb2cafb30f749f5cd280477a3aa5c6bfc88dfee49ac76c9"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.channelToPublicPeer (cognitive 17): handler.channelToPublicPeer has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":824}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f29a8e521293c74101cfe134682879510d4fe3ee91dc762aaa6288e7c17f635"}},{"ruleId":"D2","level":"warning","message":{"text":"main.evidenceToChat (cognitive 16): main.evidenceToChat has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 4, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/report_evidence.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b28de20cfa82ab82140a5655b04075972a7b3e7fda1c5c7a7b8a84f9e08f1bf"}},{"ruleId":"D2","level":"warning","message":{"text":"server.streamStoredFile (cognitive 16): server.streamStoredFile has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a93907b0dd8b8e039113d2be9b72c85619f4f43555423b47145c014e5f7f883"}},{"ruleId":"D2","level":"warning","message":{"text":"server.handleModerationReportEvidenceAPI (cognitive 16): server.handleModerationReportEvidenceAPI has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 3, boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/report_evidence.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"25004c15bac12dc70750982a2c08c42b36a7427bf0da4097b0a6858249c2a56c"}},{"ruleId":"D2","level":"warning","message":{"text":"main.render (cognitive 16): main.render has cognitive complexity 16 (threshold 15). Drivers by points: loops 9 (11 pts), if/else 2 (3 pts), boolean chains 2 (nesting depth added 3). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd81ec7185c8eeface5a18fff50ed9c15a57cfb775b73d66e48256173bece031"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.GrantBotVerifier (cognitive 16): Service.GrantBotVerifier has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 1 (nesting depth added 2). Most of this is not in the body itself: 5 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 301). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"238bc8f43e07b4c2c456868d053f557d4c860e235d6d65afb852aaca3b41cb8c"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.handleModerationCases (cognitive 16): Server.handleModerationCases has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1455}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3c907d9830fdc3d3f9e554e09dfeb274d84daaaa7f4f63c0bc8b794a374ba05"}},{"ruleId":"D2","level":"warning","message":{"text":"ai.NewProviderFromConfig (cognitive 16): ai.NewProviderFromConfig has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 1, match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"860abc667f882932760579fc76f40f15a58873d736a31d5f83b5005d433f054d"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.createEmailLoginCode (cognitive 16): Service.createEmailLoginCode has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13 (16 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":723}}}],"partialFingerprints":{"codehealthFindingId/v1":"438edd764cb2d6eb19d15d7d3ecf12df210c3ec69ba6bec150fd4552ea5e69e3"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.cancelCode (cognitive 16): Service.cancelCode has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1071}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4ae87449f03424e6140806157ebadd27380e322f7c8e5db9d3a7f19456bb97f"}},{"ruleId":"D2","level":"warning","message":{"text":"bots.serviceBotURLByteSpans (cognitive 16): bots.serviceBotURLByteSpans has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service_bot_entities.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"181086515ceaa09393122d17bd43604faf5f0d0d0bdbb9c2403092e7f2bcd1da"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.getBotParticipants (cognitive 16): Service.getBotParticipants has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 2, loops 2 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"05c559a2940a87835628782003636b94c51a0a1827ce64bb4311f93a5773e846"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.filterBotChannelDifference (cognitive 16): Service.filterBotChannelDifference has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 3, loops 2 (3 pts), match/switch 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"531a27a5c2526efe34a86bc05ddb3c6750ff47e1f59377e049bcfe337869b4c8"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.botCanSeeChannelMessage (cognitive 16): Service.botCanSeeChannelMessage has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 3, loops 1 (2 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"5da0d8acdb8adaf60889ad76dc860def7eb40363587be48f43d28e36f04a8ce7"}},{"ruleId":"D2","level":"warning","message":{"text":"dialogs.dialogListSnapshotPageHeaders (cognitive 16): dialogs.dialogListSnapshotPageHeaders has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 4, loops 1 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"c11bc1f814c2ea81714b07ae8df913a3170377b1f5e18f7037ae3ff5f67386ee"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.cachedPeerDialogsReadModel (cognitive 16): Service.cachedPeerDialogsReadModel has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 2, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fdcd3b1aa015afefdca548694389aec9ea9e6e7fd031fd1895137bda16d8835"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.loadDialogs (cognitive 16): Service.loadDialogs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":544}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfbd287bd993242b5aa7643f10a2ec519155cae1ea13e678e5f8a6dc8d7352d5"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.GetPeerDialogs (cognitive 16): Service.GetPeerDialogs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":686}}}],"partialFingerprints":{"codehealthFindingId/v1":"98ab13eb776f2751b362c820e6f8512d3cf136462a4d313668a3b466dd85c972"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.loadDialogListSnapshotAtOwnerHash (cognitive 16): Service.loadDialogListSnapshotAtOwnerHash has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13 (16 pts) (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/shared_list_snapshot.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c4ebf71d37ddf0a3436ce6d22c09c676b5c046d8ee4ac32ddff124f3610c691"}},{"ruleId":"D2","level":"warning","message":{"text":"files.validatePremiumPromoAttributes (cognitive 16): files.validatePremiumPromoAttributes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (10 pts), boolean chains 3, match/switch 1 (2 pts), loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/premium_promo_seed.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"15e65314c9ac761a464917df769119648f2ea6e79b67da6e1b5adc360c5088ce"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.seedReactions (cognitive 16): Service.seedReactions has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 6). Of this number, 11 points are the body\u0027s own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7dda5bcf0e24d756b55da20e75834f3d8e37654a76a4fadc0a51f9f7bef97e4"}},{"ruleId":"D2","level":"warning","message":{"text":"langpack.packFromFilename (cognitive 16): langpack.packFromFilename has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 6 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/parser.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"711db25b511c5fd6738862eab55d8c5420f237ae1b8e8e1712145df1d450026d"}},{"ruleId":"D2","level":"warning","message":{"text":"messages.businessWorkHoursOpen (cognitive 16): messages.businessWorkHoursOpen has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"e38d437717ae963c23cabdc1575bb09282050a3acb1bac4eecfd0e844772d271"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.ReportStories (cognitive 16): Service.ReportStories has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 3, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":368}}}],"partialFingerprints":{"codehealthFindingId/v1":"eae22081540356ceb23396f512aa696b9aa340d255e2787ede781f4d41ffae45"}},{"ruleId":"D2","level":"warning","message":{"text":"privacy.validateRules (cognitive 16): privacy.validateRules has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (9 pts), loops 3 (5 pts), match/switch 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":515}}}],"partialFingerprints":{"codehealthFindingId/v1":"c55ba85bb73a35978b62902a8e5ae3421604d96e0edc1c5505860bfaaf66a6f6"}},{"ruleId":"D2","level":"warning","message":{"text":"Service.RequestEncryption (cognitive 16): Service.RequestEncryption has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12 (13 pts), boolean chains 3 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/secretchat/service.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b3e155d317f65e8e8ff0830d196108697692120627c9118c451f6ac90080399"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.ValidateUsernameReorder (cognitive 16): domain.ValidateUsernameReorder has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/collectible_username.go"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"9af435fc48bfa812c56dc10bbd75b1d94f32bb7102ae57d6def6a335eeebb923"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.classifyDocumentCategory (cognitive 16): domain.classifyDocumentCategory has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (11 pts), match/switch 2 (3 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/media_category.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"a04fa4a161ccbd2b314c1d5ada9f4330038f7757e5f5b614b69b1ae1dbdfee40"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.ValidateExternalReplyQuote (cognitive 16): domain.ValidateExternalReplyQuote has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 4, loops 2 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_reply_external.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bba352c02689acec47945118bb11f6a279df451c753efadfa0b88bca4615e67"}},{"ruleId":"D2","level":"warning","message":{"text":"domain.NewModerationReport (cognitive 16): domain.NewModerationReport has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 3, boolean chains 1 (nesting depth added 4). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation.go"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"81228d394c9a6bed6f53db8be67637d48dbc5aac2fa6622b20f6a7ac126ff2e6"}},{"ruleId":"D2","level":"warning","message":{"text":"ClientTelemetryEvent.Validate (cognitive 16): ClientTelemetryEvent.Validate has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (9 pts), boolean chains 6, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/client_telemetry.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"f44a3745e1feb8f79efbf25cd440e574d1c92bf679de203bf708d1a45dcad74d"}},{"ruleId":"D2","level":"warning","message":{"text":"loadharness.provisionOne (cognitive 16): loadharness.provisionOne has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14 (15 pts), boolean chains 1 (nesting depth added 1). Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 210). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal\u0027s work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/provision.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e7e2545cd1b839ecf1e7088ed487886cf89f1ae7b8178a679abbbc3f6576257"}},{"ruleId":"D2","level":"warning","message":{"text":"mutationJournal.assertComplete (cognitive 16): mutationJournal.assertComplete has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":736}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9fb62e5a6e314d489a24f7599007e236b62e677cf4db4dfac0d72ad6cb9dca4"}},{"ruleId":"D2","level":"warning","message":{"text":"rpcResultDeliveryCoordinator.claimReplayDeliveredHook (cognitive 16): rpcResultDeliveryCoordinator.claimReplayDeliveredHook has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 2, match/switch 1 (2 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":498}}}],"partialFingerprints":{"codehealthFindingId/v1":"885223cedfb7ee736e159f5dee1ffbfbe3bb75146f2b26475ce9022de34c985e"}},{"ruleId":"D2","level":"warning","message":{"text":"rpcExecutionLedger.completeOnce (cognitive 16): rpcExecutionLedger.completeOnce has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 2, loops 2, match/switch 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_ledger.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"51a87addef5e6cf205c73d929c2b26ac1d8c18f619d80d9ef493f69e7b6492a5"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.encodeRPCResultWithoutSlot (cognitive 16): Server.encodeRPCResultWithoutSlot has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 3 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":1308}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f28f6191869d3f2fec43dae71b6b3f1469ac755fb6d73df68d006ce4b01f706"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.admitInboundLayerRPCAt (cognitive 16): Server.admitInboundLayerRPCAt has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 1 (nesting depth added 8). To reduce it, flatten the nesting: this score is depth rather than breadth \u2014 most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language\u0027s equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":909}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dafc2f349d9c92e962d0d2329e585efdf449affb64d25230e116babba9c370f"}},{"ruleId":"D2","level":"warning","message":{"text":"Server.newInboundLayerRPCTask (cognitive 16): Server.newInboundLayerRPCTask has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 5 (nesting depth added 2). Most of this is not in the body itself: 4 of the 16 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 165, 137, 157). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals\u0027 work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/layer_rpc_execution.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"8079f1f8bef24f55a6443e201f04da5fae5657f89b9ef8b3c0aaf8db4de13103"}},{"ruleId":"D2","level":"warning","message":{"text":"SessionManager.DestroySessionForAuthKey (cognitive 16): SessionManager.DestroySessionForAuthKey has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":756}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c60ad208d91891c0108ecb71a557212407879666b0e1fed3aa91289f4c8025a"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.botAPIUnorderedRichList (cognitive 16): rpc.botAPIUnorderedRichList has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (13 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce3d68a0daefabd7111704d5c206f5de00a78902b743de6b15eac3a6f8d23b74"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.tgChannelParticipant (cognitive 16): rpc.tgChannelParticipant has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (15 pts), match/switch 1 (nesting depth added 8). The drivers above price the dispatch low by construction \u2014 a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full \u2014 so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":726}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7c309b27d6d97259911b745b0a5910b2e9cb77b3df75df0a1e1777d4abdf2f0"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.mergeReactionCatalogFallback (cognitive 16): rpc.mergeReactionCatalogFallback has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_catalog.go"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"37ed91f6ed61deaa7052df894770bf245d13b4e483527fefefcc8a64dfa1e9be"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.sliceTGEntitiesForChunk (cognitive 16): rpc.sliceTGEntitiesForChunk has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"39fd685daed3857ec94db6199cfc3f198c713dc6ca828a81c1750190256084ce"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.validateTodoItems (cognitive 16): rpc.validateTodoItems has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_todos.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e6f97d96d245444ae969abebd48f07d74ce01df1dff659b0dc06c1127dfa45c"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.combineSendUpdates (cognitive 16): rpc.combineSendUpdates has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 3 (5 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_replay.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"63ca5aebac4f81d558b8df477d72b6e7234137526c61736515a86de025ecf913"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.applyContactNoteToUserFull (cognitive 16): rpc.applyContactNoteToUserFull has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 2, match/switch 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d555324a958d31dd42fdc4e54218f7d061546551d5c0850d470d17d1c0c6a9a"}},{"ruleId":"D2","level":"warning","message":{"text":"rpc.domainWallpaperSettings (cognitive 16): rpc.domainWallpaperSettings has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 2. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/wallpaper.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"300cf4cc64d6b2101ae902b42d2ebfc019a9494633b7f525293b253d56c43521"}},{"ruleId":"D2","level":"warning","message":{"text":"presenceLastSeenBatchDispatcher.drain (cognitive 16): presenceLastSeenBatchDispatcher.drain has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 2 (3 pts), match/switch 1 (3 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence_last_seen_batch.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"7984b531633f98ef2c8dcdccb4725d3779798dfb3e75983920a8c320759c0986"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onAccountVerifyEmail (cognitive 16): Router.onAccountVerifyEmail has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (15 pts), match/switch 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":791}}}],"partialFingerprints":{"codehealthFindingId/v1":"440cc0aae393a51d95663990e03c1f7e0408ae515cc31cdfc7749d5f988a0343"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.runAccountLifecycleOnce (cognitive 16): Router.runAccountLifecycleOnce has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_lifecycle_worker.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"988b933a3a6d7dde64d0fa7c3359615f8af1fbfccb4dd3e547819071dcf79a10"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.BotAPISendMessage (cognitive 16): Router.BotAPISendMessage has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"330d98f8db17778afe1474a44bcf0b1199751ca54bd98c35d4532231100db3df"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.BotAPISendMedia (cognitive 16): Router.BotAPISendMedia has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":294}}}],"partialFingerprints":{"codehealthFindingId/v1":"1abdd0dcdd353bd461e621ce3c293e46daec2a5decb73afa2546e16c9fba7c2e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.BotAPIEditEphemeral (cognitive 16): Router.BotAPIEditEphemeral has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 4 (nesting depth added 3). Of this number, 13 points are the body\u0027s own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":404}}}],"partialFingerprints":{"codehealthFindingId/v1":"a75f287859a9e3a7b61f2abb351fa46c8052e4f412e4a448797aecb60c7441c7"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.botAPIQueuedChannelMessages (cognitive 16): Router.botAPIQueuedChannelMessages has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"253c8b45ece7f02d5e4b210516ddd7b2fabf274a4029304ba40014764ab86ccf"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.channelInlineMessageIDFromSendUpdates (cognitive 16): Router.channelInlineMessageIDFromSendUpdates has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline_message_id.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"da1c70babe63ec17ef449dd0db7db6a53c79065e2e06927e80fc1df8ffdcaa91"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesSetChatWallPaper (cognitive 16): Router.onMessagesSetChatWallPaper has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 2, match/switch 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2f50a5a706fe6b0729ac292080c7b20b0861e4e9bd769b476785fb1c9d8662c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onChannelsDeleteChannel (cognitive 16): Router.onChannelsDeleteChannel has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 3). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b525f31b5cd64df703d7aa9a83b14e8295d3e2e37bd736bad6098f484f5fe72"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.tgUsersForIDs (cognitive 16): Router.tgUsersForIDs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 3, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e6c4459e16b007bd146b5706b22c184d5a9d061525d81ebc8dd29842266b653"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onCommunitiesToggleAllPeerLinkRequestApproval (cognitive 16): Router.onCommunitiesToggleAllPeerLinkRequestApproval has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), loops 2 (5 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"406036f3cddf5ded105edef26bd499264d41b3d5dfe21b6018b10340be83716e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onCommunitiesToggleParticipantBanned (cognitive 16): Router.onCommunitiesToggleParticipantBanned has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 3, loops 2 (nesting depth added 3). Of this number, 10 points are the body\u0027s own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":413}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5877df7c0dc40af592de246aa9ed04857fc67af250b945317a4f21b46347e04"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onContactsAddContact (cognitive 16): Router.onContactsAddContact has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14 (15 pts), boolean chains 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":678}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a618dcc36febfd2dd5a0dea3afb99a023f23bfe6a900885bedf3389b93b6d4d"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.domainEphemeralInputContent (cognitive 16): Router.domainEphemeralInputContent has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"2356213d8d0563a733a1a3d7a133147fe45586e95587a212822cb6da4168ddc6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onHelpGetPremiumPromo (cognitive 16): Router.onHelpGetPremiumPromo has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/help.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c762fcfc286d90bc88ee557d91d9fcbb0fc78bc733f499ca93b1f3cf385d722"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.chatsForDrafts (cognitive 16): Router.chatsForDrafts has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 3, boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"1facb9ed116ea08cbac636098b39aab30221074938452093ea03e4cb3ec3b60b"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesUpdateDialogFilter (cognitive 16): Router.onMessagesUpdateDialogFilter has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (16 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"47d31dcb339b16c99dc52d0ea602e3c0bb974a2fbd315b8359eb4985f8d60f85"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.dialogPeersFromInput (cognitive 16): Router.dialogPeersFromInput has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (13 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":1010}}}],"partialFingerprints":{"codehealthFindingId/v1":"c15af6bab90ee710cf7c12ce691525a19f02750284e8458a93d727047236cea8"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesGetForumTopics (cognitive 16): Router.onMessagesGetForumTopics has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":274}}}],"partialFingerprints":{"codehealthFindingId/v1":"49205f91c6b9446fcbc9c44eb6c5d3a219b22f1198cb0eb1e69fc80979099d49"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesReport (cognitive 16): Router.onMessagesReport has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 2, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reports.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"244c00e83eed8e427a126c7f66f1279b34cb094d34125d187a118350686a496b"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.sendClaimedScheduledMessages (cognitive 16): Router.sendClaimedScheduledMessages has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_scheduled.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"14e757f8583e7ab07e1d90b2e47236ea66d10cc9199158d72e3b6451daf961a7"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPaymentsUpdateStarGiftCollection (cognitive 16): Router.onPaymentsUpdateStarGiftCollection has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_collections.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"b867d04c934e62d13e2d63f3b67885c6c16f1595f99d4ad773736293e8ad927c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhoneDiscardCall (cognitive 16): Router.onPhoneDiscardCall has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_calls.go"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"a30790fe647750cc5ae6843a207b9d352d7a6e2ef96b65226e065183152c70f0"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhoneInviteConferenceCallParticipant (cognitive 16): Router.onPhoneInviteConferenceCallParticipant has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12, boolean chains 4. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_conference.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbae5c9ec2dfd34e469140e726ca71a234ff4a78d39ff4db877b002b50bf960e"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onPhoneInviteToGroupCall (cognitive 16): Router.onPhoneInviteToGroupCall has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (12 pts), boolean chains 3, loops 1 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_edit.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e3cffa7a20effa8f6e072cd52f85bcd17a61e44dbca2da7531dae881c646bf6"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.filterChatInvitePrivacy (cognitive 16): Router.filterChatInvitePrivacy has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 3 (5 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/privacy_invites.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0c5792829b4177ca5d9131da153f796f10d1aba91856461c7a7e5d443617b0c"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onStatsGetStoryStats (cognitive 16): Router.onStatsGetStoryStats has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c04a5da73a7a2ffaf56f73642f3b62f07785e6d2ed838658e2e3521dd139d6f"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onStatsGetStoryPublicForwards (cognitive 16): Router.onStatsGetStoryPublicForwards has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (11 pts), boolean chains 5 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"4082651527fb47827e9ad1161fcd131b5e9d31acf29afdf36804657bc10b1863"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onStickersCreateStickerSet (cognitive 16): Router.onStickersCreateStickerSet has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 2, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers_creator.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"9946ed0cc1c7c02200a2b5407aa7203949148f4a4f2ca6656a9f565062381349"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.onMessagesRequestURLAuth (cognitive 16): Router.onMessagesRequestURLAuth has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 5 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"02e4382e36dc9ff55a38a6c5d17107fff2cc81dd56204d32e8cdab38a7bd7841"}},{"ruleId":"D2","level":"warning","message":{"text":"Router.resolvePendingWebPage (cognitive 16): Router.resolvePendingWebPage has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (15 pts), match/switch 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/webpage_resolver.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a7857501eca14f8d9c62e017aa0f4a028ce1a5e7d7b36650f6b22608a443bd0"}},{"ruleId":"D2","level":"warning","message":{"text":"sfu.buildMediaPlan (cognitive 16): sfu.buildMediaPlan has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (7 pts), loops 4 (5 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ba3a6b3e1703c863db2ef86c1d8795a6fa0bd3a2e3c90d528291f9398cff6c9"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.adminRightsSubset (cognitive 16): memory.adminRightsSubset has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 16. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ecc44e369ae2f3f1e91c3054418c75ac77429986383b18ce98b03da2448257e"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.filterDialogList (cognitive 16): memory.filterDialogList has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 2, loops 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"e59e88958299215be08d4b85238248b44a2235500ed2b903d33da2099e9dd76f"}},{"ruleId":"D2","level":"warning","message":{"text":"memory.projectCollectibleAttributes (cognitive 16): memory.projectCollectibleAttributes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (8 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":896}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c0db2cbe50d10390c934089a5cf2f269d3ef7c7840a3de1d5e4f2ff13e3d7ab"}},{"ruleId":"D2","level":"warning","message":{"text":"AIComposeStore.ListAIComposeTonesForUser (cognitive 16): AIComposeStore.ListAIComposeTonesForUser has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 3 (5 pts) (nesting depth added 7). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ai.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"b21190d32d1e8f9584790ca7bfb6512c33a161ee3c920df11497c92952e559fb"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.EnsurePermanentInvite (cognitive 16): ChannelStore.EnsurePermanentInvite has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 4, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"29601b7136a13bd4ba858fb44548f2affcee16830bde38de73350aee3febb1e5"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ReadChannelMentions (cognitive 16): ChannelStore.ReadChannelMentions has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 4, loops 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"640e5e9561c80be02a728e055b93a4448ef9616c3a1e619a5d9536362f476fe5"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteExpiredChannelUpdateEvents (cognitive 16): ChannelStore.DeleteExpiredChannelUpdateEvents has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 3 (4 pts) (nesting depth added 7). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"0589210c72d1b6880cc63b1319ad44929b18e5c8ac44d9035e6f25686c28ccf1"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.pruneChannelUpdateEventsLocked (cognitive 16): ChannelStore.pruneChannelUpdateEventsLocked has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 3, loops 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd90e00d9f144c18540c32270b7d970ee5adabd4f760aff1cddb63a333c2756d"}},{"ruleId":"D2","level":"warning","message":{"text":"DialogStore.SetPinned (cognitive 16): DialogStore.SetPinned has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 3, boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"6025dc5fe09e5cad8b9a103bdf91c160cb04b05f1de6348c01bb8e9fb648e713"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.rebuildMemoryDialogLocked (cognitive 16): MessageStore.rebuildMemoryDialogLocked has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_delete.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"f22267e3eb3dafb47eaf39f7d36543b5df11aadbadc328d05bc6178c43a66db7"}},{"ruleId":"D2","level":"warning","message":{"text":"PasswordStore.ListUserStickerSets (cognitive 16): PasswordStore.ListUserStickerSets has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 5). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"b290aa0d0e562875e470e16d419815c0575aa255d9f6a86de8bca7df41e17d23"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftStore.ResolveSavedIDs (cognitive 16): StarGiftStore.ResolveSavedIDs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"26688506129dab11d86d0d8b963ee2894185dc028f75d2d6bb1900cc00ddb618"}},{"ruleId":"D2","level":"warning","message":{"text":"StoryStore.ListPinnedStories (cognitive 16): StoryStore.ListPinnedStories has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 3, loops 2 (nesting depth added 3). Of this number, 14 points are the body\u0027s own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":359}}}],"partialFingerprints":{"codehealthFindingId/v1":"12a46a91fcf68780a58a9ccdf8f0eddeecfb1411663b3d0747492287deb4e3b3"}},{"ruleId":"D2","level":"warning","message":{"text":"StoryStore.ListStoriesArchive (cognitive 16): StoryStore.ListStoriesArchive has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (9 pts), boolean chains 6, loops 1 (nesting depth added 2). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"14d1f956fae001bf290419593e0f26c54946f5ceef831acbe2437f42358ba4c5"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.deleteOrphanedAuthKeysTx (cognitive 16): postgres.deleteOrphanedAuthKeysTx has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (14 pts), loops 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"03dd4323c3864538772815dbe76c38cb1105b2be11063b4285bd2b313959ec47"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.adminRightsSubset (cognitive 16): postgres.adminRightsSubset has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 16. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":959}}}],"partialFingerprints":{"codehealthFindingId/v1":"168fa9c28f3e25b8211e738d408d36dd63384d4a67d61d5452cdd9a766d6eb03"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.populateChannelMessageUnreadFlags (cognitive 16): postgres.populateChannelMessageUnreadFlags has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd6340e1f1ceaeb76ba2c019c2e8d4d21649b15caaa4439e9bf0c6ee42968575"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.createModerationReportTx (cognitive 16): postgres.createModerationReportTx has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"e93a26b5132233639f546abf6e8b8493b7eeb6f85deb6c02f39a765d7c9138a4"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.listAnimatedCollectibleAttributes (cognitive 16): postgres.listAnimatedCollectibleAttributes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (15 pts), loops 1 (nesting depth added 4). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc99b41ad8e6b9a5049a96dce4baccaebf5030c4eb1cf87628cd9abb681a15ed"}},{"ruleId":"D2","level":"warning","message":{"text":"postgres.appendUserUpdateEvent (cognitive 16): postgres.appendUserUpdateEvent has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd3253f3d354e928eb718b28dadff32d949c9a110252c4c28661ce6d9da262bd"}},{"ruleId":"D2","level":"warning","message":{"text":"AccountLifecycleStore.ScheduleAccountDeletion (cognitive 16): AccountLifecycleStore.ScheduleAccountDeletion has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13 (15 pts), boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_lifecycle.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"72cafe1123b188b54f25e8c87d2add14d63fc0f66a1fed7be419a7409e4a22f2"}},{"ruleId":"D2","level":"warning","message":{"text":"AccountRatingStore.SaveAccountRating (cognitive 16): AccountRatingStore.SaveAccountRating has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (12 pts), boolean chains 4 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_rating.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"a416f04f61f93687f1727fc7f3839eddd65dae8ec9052d5e6941806879e4be3c"}},{"ruleId":"D2","level":"warning","message":{"text":"ActiveChannelIDsPageBatcher.run (cognitive 16): ActiveChannelIDsPageBatcher.run has cognitive complexity 16 (threshold 15). Drivers by points: match/switch 2 (7 pts), if/else 2 (4 pts), loops 2 (4 pts), jumps 1 (nesting depth added 9). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9e781bbb122ed0116e0130a545f9cddd2bbd1343352a7498175f0e01355ba0e"}},{"ruleId":"D2","level":"warning","message":{"text":"BatchedBootstrapUpdateJobStore.run (cognitive 16): BatchedBootstrapUpdateJobStore.run has cognitive complexity 16 (threshold 15). Drivers by points: match/switch 2 (7 pts), if/else 2 (4 pts), loops 2 (4 pts), jumps 1 (nesting depth added 9). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bootstrap_update_job_batch.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5b678130425f2db0a1b69d4a3c32108797f50e03a2183e9bacecc1382a5071f"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ExportInvite (cognitive 16): ChannelStore.ExportInvite has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 2 (nesting depth added 1). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3791a860fc8ab09909cb44736af6bf060987e4b7183e4951a1fc92c09e222d7"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ImportInvite (cognitive 16): ChannelStore.ImportInvite has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12 (14 pts), boolean chains 2 (nesting depth added 2). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"05887cf9e0e520baabd456fcc20c94e2cb5d2e1ca8f283bda306e7ef4a2943e0"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.cascadeDeleteDiscussionRootsTx (cognitive 16): ChannelStore.cascadeDeleteDiscussionRootsTx has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 3, loops 3 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3edd43b36aefba9b3c490d662346d3896d6b5a59b2229193605d70d39291c6b"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.DeleteChannelParticipantHistory (cognitive 16): ChannelStore.DeleteChannelParticipantHistory has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 1, loops 1 (nesting depth added 1). Of this number, 15 points are the body\u0027s own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a738211d214e6f86fe52d6de32ce82bdaf67a4f94f9b119518d04e142ab9aba"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.ListChannelMessagePublicForwards (cognitive 16): ChannelStore.ListChannelMessagePublicForwards has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (12 pts), boolean chains 3, loops 1 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a967b7266b98854ffc02b322a1768508375850622490c2b0c288d07c6355961"}},{"ruleId":"D2","level":"warning","message":{"text":"ChannelStore.loadSuggestedPostResultTx (cognitive 16): ChannelStore.loadSuggestedPostResultTx has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"f082be5bbed5fe34a940c0ef1eb139adf32bdb0b03dea5b4c0a6308bb77f1a4e"}},{"ruleId":"D2","level":"warning","message":{"text":"CommunityStore.ListCommunityPeerLinkRequests (cognitive 16): CommunityStore.ListCommunityPeerLinkRequests has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), loops 2, boolean chains 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":640}}}],"partialFingerprints":{"codehealthFindingId/v1":"f13e0e770b46da26cb02f8da09ca7c23f7413fd9197878bf18ea9212eac57350"}},{"ruleId":"D2","level":"warning","message":{"text":"ContactStore.SetCloseFriends (cognitive 16): ContactStore.SetCloseFriends has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 2, loops 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":703}}}],"partialFingerprints":{"codehealthFindingId/v1":"3779dd88210ca159cfb49af17389cfdf3f6aad4e8894b172ea8050e571d8fca9"}},{"ruleId":"D2","level":"warning","message":{"text":"GroupCallStore.ResetAllParticipants (cognitive 16): GroupCallStore.ResetAllParticipants has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":817}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6b6331a272d54336be787be143f4352c1176476d34c0e637ee5589d111c22da"}},{"ruleId":"D2","level":"warning","message":{"text":"MessageStore.enrichSavedMessageTags (cognitive 16): MessageStore.enrichSavedMessageTags has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (13 pts), loops 2, boolean chains 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_saved_reactions.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7ba1e3170416967d506ffab4a698cc8f34b2f0bd013e98a96ec3ab8dc4f1434"}},{"ruleId":"D2","level":"warning","message":{"text":"PollStore.ListPollVotes (cognitive 16): PollStore.ListPollVotes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 2, loops 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/poll.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"abc2bbb824fff9b2274d35bfccb2ec9299fdb123d6d012345bc0bdd008b8757c"}},{"ruleId":"D2","level":"warning","message":{"text":"StarGiftLifecycleStore.dispatchChannelStarGiftNotifications (cognitive 16): StarGiftLifecycleStore.dispatchChannelStarGiftNotifications has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_channel_notifications.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"708847172fe0247fb38a2a1e36243c56ba55ee91538987488196f3587f0f708c"}},{"ruleId":"D2","level":"warning","message":{"text":"StoryStore.ListStoryReactions (cognitive 16): StoryStore.ListStoryReactions has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14 (16 pts) (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1315}}}],"partialFingerprints":{"codehealthFindingId/v1":"649284f95ced3a1f21cbeae3ec2dd2c3e3a17c9fc125840ee03c415e0ab45a30"}},{"ruleId":"D2","level":"warning","message":{"text":"WelcomeMessageStore.ClaimWelcomeMessageDeliveries (cognitive 16): WelcomeMessageStore.ClaimWelcomeMessageDeliveries has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 2, loops 1 (nesting depth added 3). Of this number, 14 points are the body\u0027s own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message_delivery.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"718933fa4266a8aa60d27dd6a264c3f3ca6c97e4064467431d70f47dc1470405"}},{"ruleId":"D2","level":"warning","message":{"text":"web.newHandler (cognitive 16): web.newHandler has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15 (16 pts) (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth \u2014 many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":136}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eb0677210f3c2f09d498a0ecf89eb1bb142a10c1c5d5c969e1b1d45fa434925"}},{"ruleId":"D2","level":"warning","message":{"text":"handler.moderationAppeal (cognitive 16): handler.moderationAppeal has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 3, match/switch 1 (3 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth \u2014 checks laid out side by side rather than stacked \u2014 so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b13a7231df34edbbfd9d064823d79619e1889869bc8ef2e1cc50d01b9b9c3f9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Router: TooManyMethods \u2014 1671 methods, declared across 193 files: rpc/stories.go (60), rpc/account.go (57), rpc/router.go (50), rpc/presence.go (40), \u002B189 more file(s). The bar is 30 methods; this is 1641 over it, 55.70\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fa7db89b091aeaf5264a40f6d2156c21d054207b87b0dde0d43cb66f6f5f316"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: main.run: FunctionTooLong \u2014 run runs 1117 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 1017 over it, 11.17\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb128bc28faa1c51cb3dd16c524d4499a20309ab2155afeb0ea1def0acf3b2a2"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Config: TooManyFields \u2014 309 stored fields beside 1 method. The bar is 30 stored fields; this is 279 over it, 10.30\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbd6279147e35b082950b2c903e7899b12d5de3212df2f1248fd14c94d017c80"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ChannelStore: TooManyMethods \u2014 299 methods, declared across 42 files: postgres/channel_settings.go (25), postgres/channel_dialogs.go (22), postgres/channel_topics.go (20), postgres/channel_helpers.go (15), \u002B38 more file(s). The bar is 30 methods; this is 269 over it, 9.97\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_store.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3ba52998f3dcff7ec8bf54a49c701aa9b3d036bef3d4516e5f7b31cac779987"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ChannelStore: TooManyMethods \u2014 256 methods, declared across 26 files: memory/channel_members.go (30), memory/channel_invites.go (26), memory/channel_settings.go (26), memory/channel_reactions.go (19), \u002B22 more file(s). The bar is 30 methods; this is 226 over it, 8.53\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_store.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"42decfd795035fc50cdea5e6cffca6fab2b37e22b14f2bc82851a9491b07f603"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: server: TooManyMethods \u2014 224 methods, declared across 19 files: telesrv-admin/server.go (96), telesrv-admin/privateview.go (20), telesrv-admin/botverification.go (18), telesrv-admin/serversettings.go (16), \u002B15 more file(s). The bar is 30 methods; this is 194 over it, 7.47\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"86050a7c81ad72615ef40507c2bb9695d3d3f71968385de44012bcb0d78215c7"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.registerMessages: MethodTooLong \u2014 registerMessages runs 691 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 591 over it, 6.91\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_register.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"5946b8672246477910e83c92c488217650c4c4708e435eba8d2d15d941103b76"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 203 methods, declared across 10 files: channels/service.go (170), channels/bot_policy.go (11), channels/media_count_cache.go (5), channels/active_ids_cache.go (4), \u002B6 more file(s). The bar is 30 methods; this is 173 over it, 6.77\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. Most of these members implement rpc.ChannelsService (137 of 203 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"34ea4a95d940539c32a35bb1a63b285e4ff7b781e7e5e51ecf9e46911b1e6410"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 184 methods, declared across 9 files: bots/service.go (39), bots/verifierbot.go (32), bots/verifybot.go (31), bots/botfather.go (26), \u002B5 more file(s). The bar is 30 methods; this is 154 over it, 6.13\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e5ebe404a662c33ad373fd9d725b87999d6959166b54f8a706e50fd7c5632e9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 182 methods, declared across 34 files: files/photos.go (44), files/service.go (18), files/sticker_management.go (14), files/seed.go (13), \u002B30 more file(s). The bar is 30 methods; this is 152 over it, 6.07\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"260850d207bd2f46c466361c09e27e43734e2dc1535f9192bcc7d6977b62db69"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: admin/service.go: FileTooLong \u2014 2701 significant lines (blank, comment-only and punctuation-only lines excluded), about 63% of them inside a single declaration: Service (86 blocks, 624-4071). The bar is 500 significant lines; this is 2201 over it, 5.40\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"12003f4c8b05538bb019cbdca84c63e7112424bf2b1244d28e0666af7d96ab21"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: config.Load: FunctionTooLong \u2014 Load runs 485 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 385 over it, 4.85\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":958}}}],"partialFingerprints":{"codehealthFindingId/v1":"b01d81a2cf27fc349722870167e8a5ceacaa4a0a7ff8a76bd7cad246cea00a53"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/stories.go: FileTooLong \u2014 2391 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1891 over it, 4.78\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae9ecea58af906cd23627c5ed8f6281b37a8ec42d7395e53ccd363acb2f8bbd0"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 140 methods, declared across 7 files: admin/service.go (87), admin/botverification.go (22), admin/star_gift_catalog.go (13), admin/verification.go (11), \u002B3 more file(s). The bar is 30 methods; this is 110 over it, 4.67\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"082d0338180d107cf7646abd0190009cb9845d6ca6ad318fd041ed2bcf0c2d51"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 140 methods, declared across 7 files: admin/service.go (87), admin/botverification.go (22), admin/star_gift_catalog.go (13), admin/verification.go (11), \u002B3 more file(s). The bar is 30 methods; this is 110 over it, 4.67\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. Most of these members implement adminapi.Service (119 of 140 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"0538290978f790514cdc9ed30e9ec78affc07bf295dfa4ead990a25ab1f32f6e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/outbound.go: FileTooLong \u2014 2249 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1749 over it, 4.50\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e8f6509dcbff97aed8382c2d8e219c23b21eda4f2753898dc1c5a7ba1e6f9e3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: telesrv-admin/server.go: FileTooLong \u2014 2204 significant lines (blank, comment-only and punctuation-only lines excluded), about 78% of them inside a single declaration: server (97 blocks, 36-2962). The bar is 500 significant lines; this is 1704 over it, 4.41\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd275bdb62c3beee67f71715455c48fadedfbbbe26a6df7dc9d057986d09af76"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: server: ClassTooLong \u2014 1728 significant lines (blank, comment-only and punctuation-only lines excluded), 224 methods, 97 blocks, lines 36-2962. The bar is 400 significant lines; this is 1328 over it, 4.32\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"974ad373c1fdc193bb79b9793a45978713730f21d8f857d544a713f05252e567"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 1704 significant lines (blank, comment-only and punctuation-only lines excluded), 140 methods, 86 blocks, lines 624-4071. The bar is 400 significant lines; this is 1304 over it, 4.26\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a1002f51e25d8c96f736131c49231b18a25f46096faabb8e678d06623a53053"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: SessionManager: ClassTooLong \u2014 1601 significant lines (blank, comment-only and punctuation-only lines excluded), 110 methods, 100 blocks, lines 175-2863. The bar is 400 significant lines; this is 1201 over it, 4.00\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f935562c89706214f1b97de264f654a10fad714fbf50776af959870e7eb6f39"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 120 methods, declared across 5 files: adminapi/server.go (89), adminapi/botverification.go (15), adminapi/verification.go (8), adminapi/account_rating.go (4), \u002B1 more file(s). The bar is 30 methods; this is 90 over it, 4.00\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"265f0f8c14476adcb16dbcec6aca03f24f10edabc4dd4859af0c1f2582123c5b"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Conn: TooManyMethods \u2014 118 methods, declared across 5 files: mtprotoedge/outbound.go (64), mtprotoedge/conn.go (28), mtprotoedge/inbound_rpc.go (13), mtprotoedge/conn_layer_profile.go (12), \u002B1 more file(s). The bar is 30 methods; this is 88 over it, 3.93\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e68c47b472015b2757ba06c5f45834b49389972731e9c5c77518cb872ca9e7f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: telesrv-admin/readstore.go: FileTooLong \u2014 1894 significant lines (blank, comment-only and punctuation-only lines excluded), about 62% of them inside a single declaration: readStore (64 blocks, 63-3502). The bar is 500 significant lines; this is 1394 over it, 3.79\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"46c8386511121c9d553479993edca4896819def0fc571b4bb2518dbad67ba932"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/session_manager.go: FileTooLong \u2014 1860 significant lines (blank, comment-only and punctuation-only lines excluded), about 86% of them inside a single declaration: SessionManager (100 blocks, 175-2863). The bar is 500 significant lines; this is 1360 over it, 3.72\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"06bc5b12a44cde1ed6592daa183d68feebbe4ba4f93281430e9e3f2377d936cd"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Server.prepareInboundLayerRPCBatch: MethodTooLong \u2014 prepareInboundLayerRPCBatch runs 367 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 267 over it, 3.67\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"173b044ee2cc337418f3e720c96448669f5a8c9e76a258bdcd6f085377f420b0"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: SessionManager: TooManyMethods \u2014 110 methods, declared across 3 files: mtprotoedge/session_manager.go (99), mtprotoedge/logical_session.go (10), mtprotoedge/runtime_metrics.go (1). The bar is 30 methods; this is 80 over it, 3.67\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d25873d6991c8f00c6a882edb20db3107ccce9e44e44c4d6369150e861e307a"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.sendPrivateTextOnce: MethodTooLong \u2014 sendPrivateTextOnce runs 348 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 248 over it, 3.48\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"96e163399f3c08e5ff2849a87058b6eec3b13218c46f8d296568a25f3c474983"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 1355 significant lines (blank, comment-only and punctuation-only lines excluded), 203 methods, 171 blocks, lines 16-2516. The bar is 400 significant lines; this is 955 over it, 3.39\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"4046915b7ee71d6a6fea13408b4a934332290df7c921578c0700621243dbfb45"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 100 methods, declared across 5 files: account/service.go (56), account/business.go (28), account/lifecycle.go (9), account/phone_change.go (5), \u002B1 more file(s). The bar is 30 methods; this is 70 over it, 3.33\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f481f73605bf1c17a685749771f69bcac80fbffacab76ab0b91adba39ec83b6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: domain/channel.go: FileTooLong \u2014 1565 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 1065 over it, 3.13\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/channel.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2e446dba2486771427824e6cbb834da97e0bab998899dfe045a36a2f008825c"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.registerAccount: MethodTooLong \u2014 registerAccount runs 312 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 212 over it, 3.12\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8cf1f326603d57e73a88a28dfbf8850ab4369023fa8d92e961efabf12382c95"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/account.go: FileTooLong \u2014 1556 significant lines (blank, comment-only and punctuation-only lines excluded), about 72% of them inside a single declaration: Router (57 blocks, 27-2121). The bar is 500 significant lines; this is 1056 over it, 3.11\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4671b32ee6144c515cfd6ed0e20e1db470cb160248e459e51451ae5fc926183"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: telesrv/main.go: FileTooLong \u2014 1543 significant lines (blank, comment-only and punctuation-only lines excluded), about 72% of them inside a single declaration: run (600-2092). The bar is 500 significant lines; this is 1043 over it, 3.09\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc7ea3b57c9f9e718b1cf54bb7cc3e74b562fc09b487e75997c796c3c0e4e173"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: StarGiftLifecycleStore: ClassTooLong \u2014 1181 significant lines (blank, comment-only and punctuation-only lines excluded), 73 methods, 35 blocks, lines 21-1871. The bar is 400 significant lines; this is 781 over it, 2.95\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"d367e73673516129a964d3df047679f5a1bb4530076f46a93d9cfac42579e52a"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: readStore: ClassTooLong \u2014 1178 significant lines (blank, comment-only and punctuation-only lines excluded), 79 methods, 64 blocks, lines 63-3502. The bar is 400 significant lines; this is 778 over it, 2.95\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"475222f3fba3dc8d9ca777e8b6aedcc6cd6c1e65f92c0516bb4f21083eaa7976"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: channels/service.go: FileTooLong \u2014 1470 significant lines (blank, comment-only and punctuation-only lines excluded), about 92% of them inside a single declaration: Service (171 blocks, 16-2516). The bar is 500 significant lines; this is 970 over it, 2.94\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"399a05aec64e6b9ff6e6b024b85b7da8cff8acc93c3a57161520fff3e4ea6065"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: adminapi/server.go: FileTooLong \u2014 1437 significant lines (blank, comment-only and punctuation-only lines excluded), about 72% of them inside a single declaration: Server (90 blocks, 202-1811). The bar is 500 significant lines; this is 937 over it, 2.87\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"561ad3b317cbc72af70f3d1040b2de64bea6eb2e6661f63e04d87528cc5792f6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/story.go: FileTooLong \u2014 1435 significant lines (blank, comment-only and punctuation-only lines excluded), about 72% of them inside a single declaration: StoryStore (42 blocks, 21-2103). The bar is 500 significant lines; this is 935 over it, 2.87\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"21c473872454424284ed111cbfe45ff8bcf34c73cfe98d69ef5120fe969e1761"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 86 methods, declared across 3 files: stargifts/service.go (82), stargifts/animation.go (2), stargifts/thumb.go (2). The bar is 30 methods; this is 56 over it, 2.87\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"44f6f90099c5963aff91356195870645c6d2e2589f444d906e35e0bd0327dd07"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: config/config.go: FileTooLong \u2014 1403 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 903 over it, 2.81\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f55f5c9b7f232b4454852d318af718c59d65dc567702cb1ab21eb7ba1fa99b1c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Server: TooManyMethods \u2014 84 methods, declared across 13 files: mtprotoedge/encrypted.go (31), mtprotoedge/inbound_layer_rpc.go (14), mtprotoedge/server.go (13), mtprotoedge/rpc_rewrap.go (6), \u002B9 more file(s). The bar is 30 methods; this is 54 over it, 2.80\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":508}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3234e0a28dd7396d0fd94ff0e183e9aa998db4b6cbcbe9a21caf6d52c79e4e3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Conn: TooManyFields \u2014 82 stored fields beside 118 methods. The bar is 30 stored fields; this is 52 over it, 2.73\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"718693729bd1ce8805d1848e682b846f42ba8fd52b5d6ffa714441a498e98149"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: readStore: TooManyMethods \u2014 79 methods, declared across 4 files: telesrv-admin/readstore.go (64), telesrv-admin/privateview_store.go (10), telesrv-admin/adminusers.go (4), telesrv-admin/activity.go (1). The bar is 30 methods; this is 49 over it, 2.63\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c3c034593f50303f24902d85288f0578cc3bdb9f25a7d38957dadc60daddc0d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/channel_dialogs.go: FileTooLong \u2014 1303 significant lines (blank, comment-only and punctuation-only lines excluded), about 72% of them inside a single declaration: ChannelStore (22 blocks, 46-1838). The bar is 500 significant lines; this is 803 over it, 2.61\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ed71a44364800fcdf1d17ce28e17f2a7eb74d4cebd62bcfec69649aa1c7cfbe"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Server: ClassTooLong \u2014 1041 significant lines (blank, comment-only and punctuation-only lines excluded), 120 methods, 90 blocks, lines 202-1811. The bar is 400 significant lines; this is 641 over it, 2.60\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"61c8266f92e31d2e87f17de74111e6d87c62ed790106c524a1998f8857193981"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/star_gift_lifecycle.go: FileTooLong \u2014 1300 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: StarGiftLifecycleStore (35 blocks, 21-1871). The bar is 500 significant lines; this is 800 over it, 2.60\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d2788f6476042ca64dbf3f8b2af8ffc5fee7d6a67dd7ea08d9dad4a08f36a67"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: StoryStore: ClassTooLong \u2014 1030 significant lines (blank, comment-only and punctuation-only lines excluded), 41 methods, 42 blocks, lines 21-2103. The bar is 400 significant lines; this is 630 over it, 2.58\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d49b63f5e3f6cc17915155af3901adf2989828529eccdf0f27049bc347ace3d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/payments_star_gifts.go: FileTooLong \u2014 1266 significant lines (blank, comment-only and punctuation-only lines excluded), about 77% of them inside a single declaration: Router (37 blocks, 61-1718). The bar is 500 significant lines; this is 766 over it, 2.53\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"875ccd8e16f05b9a4ed4b0a401749716e2a41e652ded356c955a5668bc5f13a1"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.onMessagesForwardMessages: MethodTooLong \u2014 onMessagesForwardMessages runs 250 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 150 over it, 2.50\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"41743073f373936eac3321bbc9611f664aa41055e1853e892834613105c750db"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/story.go: FileTooLong \u2014 1244 significant lines (blank, comment-only and punctuation-only lines excluded), about 65% of them inside a single declaration: StoryStore (49 blocks, 15-1274). The bar is 500 significant lines; this is 744 over it, 2.49\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9014bb8603e42fde810cdfa261f11febacf2659421a35e11570a14f819d25a82"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: StarGiftLifecycleStore: TooManyMethods \u2014 73 methods, declared across 8 files: postgres/star_gift_lifecycle.go (34), postgres/star_gift_craft_auction.go (16), postgres/star_gift_purchase.go (8), postgres/star_gift_entitlements.go (5), \u002B4 more file(s). The bar is 30 methods; this is 43 over it, 2.43\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5def86631eb6c38b64b138f23508f53e7a3413af0bb503df7ced0508d18b05d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/router.go: FileTooLong \u2014 1208 significant lines (blank, comment-only and punctuation-only lines excluded), about 74% of them inside a single declaration: Router (51 blocks, 127-1891). The bar is 500 significant lines; this is 708 over it, 2.42\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e0a8245adea703835de1acbffd3fc04d3ab2ee17ea281a9b4177057f379c87d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MessageStore: TooManyMethods \u2014 72 methods, declared across 19 files: postgres/scheduled_message.go (10), postgres/message_send.go (9), postgres/message_history.go (7), postgres/saved_dialog.go (6), \u002B15 more file(s). The bar is 30 methods; this is 42 over it, 2.40\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_store.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f19f4867fd59408ccd699a6816e1ded9dc28bf811126c576bb2f17659c704b7"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.sendChannelMessageOnce: MethodTooLong \u2014 sendChannelMessageOnce runs 240 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 140 over it, 2.40\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"c661da9d01d4b2bb5dde578b9d9fac1f1bf616edd91dec83e26e4edb18b51587"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MediaStore: TooManyMethods \u2014 69 methods, declared across 4 files: postgres/media.go (47), postgres/media_refs.go (18), postgres/blob_migration.go (2), postgres/web_page.go (2). The bar is 30 methods; this is 39 over it, 2.30\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d858893ed3eb6ec782306c2c490e1dd3178129755febf6c3aff2ac1bc7405dd"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: auth/service.go: FileTooLong \u2014 1134 significant lines (blank, comment-only and punctuation-only lines excluded), about 79% of them inside a single declaration: Service (52 blocks, 81-1806). The bar is 500 significant lines; this is 634 over it, 2.27\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"181d35aaaa68fae33da77987f357ebd78dfece5b7cb0c5d492b82bc92a38c373"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: botapi/server.go: FileTooLong \u2014 1126 significant lines (blank, comment-only and punctuation-only lines excluded), about 69% of them inside a single declaration: handler (22 blocks, 128-1273). The bar is 500 significant lines; this is 626 over it, 2.25\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6939e547af00b8bbf760143974a86199493cbcf099fc723592f3b8650690248"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: main.doFetch: FunctionTooLong \u2014 doFetch runs 225 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 125 over it, 2.25\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/appearancefetch/main.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"55d357ef2d73efee37d8a802e4154af8116db848f1c37e71c1147ae3e3573807"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Router: ClassTooLong \u2014 899 significant lines (blank, comment-only and punctuation-only lines excluded), 1671 methods, 51 blocks, lines 127-1891. The bar is 400 significant lines; this is 499 over it, 2.25\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6d37c3c4cc21f7fa9fc944628ccd70beacfc9367f467a00960bcd92b16b505d"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 891 significant lines (blank, comment-only and punctuation-only lines excluded), 52 methods, 52 blocks, lines 81-1806. The bar is 400 significant lines; this is 491 over it, 2.23\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"aabb2e6cbffded32db6305563394a02dd80236161f7e1b6cc5324a7d618cef2f"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 66 methods, declared across 4 files: messages/service.go (54), messages/business_automation.go (8), messages/private_media_count_cache.go (3), messages/album_group.go (1). The bar is 30 methods; this is 36 over it, 2.20\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbe2b4556e1cee6ef8f16071b7e0099fcf51627407a71f5bd1d2f35ce0a87945"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: MessageStore: TooManyMethods \u2014 66 methods, declared across 17 files: memory/message_send.go (9), memory/saved_dialog.go (9), memory/message_reactions.go (7), memory/message_history.go (6), \u002B13 more file(s). The bar is 30 methods; this is 36 over it, 2.20\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_store.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"68744ab45d7ab18d5b97f865150109f89f596b9792842f1086daa67169c6d352"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/encrypted.go: FileTooLong \u2014 1080 significant lines (blank, comment-only and punctuation-only lines excluded), about 68% of them inside a single declaration: Server (31 blocks, 121-1532). The bar is 500 significant lines; this is 580 over it, 2.16\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a52cb76068e4f8173b0745e7107639d2d9a538d4abf41fc60fa96417eb90727"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loadharness.StartupRun: FunctionTooLong \u2014 StartupRun runs 216 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 116 over it, 2.16\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"03e52889f9647740347784fbe1d326a0867a258d45f19b425ad29b26def10273"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: loadharness/run.go: FileTooLong \u2014 1077 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 577 over it, 2.15\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f350d72935ceb4ea8f334c991b76e6b54b2ccdc9ab5c2d3a41bf23d2f23b21c"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.resolveInputMedia: MethodTooLong \u2014 resolveInputMedia runs 212 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 112 over it, 2.12\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":630}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb455c84ba0ba61640522ae1934bd49d1561e7ad5442dce2fee3637aca48903b"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: rpc.tgOtherUpdateFromEvent: FunctionTooLong \u2014 tgOtherUpdateFromEvent runs 206 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 106 over it, 2.06\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"2742971623e82b7364a006132756c315a5df7de59f33dabe02cca62d80fc2240"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/media.go: FileTooLong \u2014 1024 significant lines (blank, comment-only and punctuation-only lines excluded), about 63% of them inside a single declaration: MediaStore (48 blocks, 25-1607). The bar is 500 significant lines; this is 524 over it, 2.05\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"54a033ad7a239eeceeaaf9531e352b17e82fb22e35d56ef4c58e4be646d47cfc"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.EditChannelMessage: MethodTooLong \u2014 EditChannelMessage runs 204 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 104 over it, 2.04\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fcf75df1bec38e0ccb672a3b5f2e609814518c94c180fc922d2dd78e378d6cb"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: StoryStore: ClassTooLong \u2014 813 significant lines (blank, comment-only and punctuation-only lines excluded), 48 methods, 49 blocks, lines 15-1274. The bar is 400 significant lines; this is 413 over it, 2.03\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fa1f5e8aa2ce50b129895ef39cc1eeafe5cb7f5f3d16d476b5feb8f9f2cb849"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loadharness.Run: FunctionTooLong \u2014 Run runs 203 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 103 over it, 2.03\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":738}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff99f53f7ac4a89c7d10f093051a2ed9945c49f0a5f4526891f925353496a606"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.registerChannels: MethodTooLong \u2014 registerChannels runs 201 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 101 over it, 2.01\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_register.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cb52de66f4381cb27236aa8d1228aca06a960fba17dd69d19daed1bd0644e74"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.ListChannelHistory: MethodTooLong \u2014 ListChannelHistory runs 201 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 101 over it, 2.01\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"11410a6c706ad207dd8ca45e9a950d57efec8eed84c4172ce8944d36ee3217af"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: domain/star_gift.go: FileTooLong \u2014 997 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 497 over it, 1.99\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cbcdffefd82f3743c51436f976ae0e4fe2fdc538022f7d57d80c5989c6b3082"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/message_history.go: FileTooLong \u2014 996 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 496 over it, 1.99\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0c1ff34f074234032a3c96dbd6e87f3119f444829939a309c7ce69c51630389"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.EditMessage: MethodTooLong \u2014 EditMessage runs 198 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 98 over it, 1.98\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"cab5397b65d107491a9ef167522f3504b9d3e27fb7ee8f8328d18c71280b410e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: dialogs/service.go: FileTooLong \u2014 981 significant lines (blank, comment-only and punctuation-only lines excluded), about 72% of them inside a single declaration: Service (38 blocks, 22-1305). The bar is 500 significant lines; this is 481 over it, 1.96\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc113b1ea0a646564130ed0c96770631cd85ca5efed8a1f670d1a5cb7d120748"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: CommunityStore: ClassTooLong \u2014 783 significant lines (blank, comment-only and punctuation-only lines excluded), 33 methods, 34 blocks, lines 16-1112. The bar is 400 significant lines; this is 383 over it, 1.96\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"e77aba039a14e6ade64d502d1e7a107e9452eca61e3bd43a421abc05f6d80280"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: handler: ClassTooLong \u2014 780 significant lines (blank, comment-only and punctuation-only lines excluded), 29 methods, 22 blocks, lines 128-1273. The bar is 400 significant lines; this is 380 over it, 1.95\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c71837fa77ca056b00b4ebae059b44158deebacf6b497505b584ee97ba15494"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: telegramlogin/service.go: FileTooLong \u2014 970 significant lines (blank, comment-only and punctuation-only lines excluded), about 75% of them inside a single declaration: Service (43 blocks, 49-1414). The bar is 500 significant lines; this is 470 over it, 1.94\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4455f3174d9c715bee7ec20d59e3159400d6cd0809cf4eabd2c972d2dc90144a"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: DialogStore: ClassTooLong \u2014 772 significant lines (blank, comment-only and punctuation-only lines excluded), 35 methods, 36 blocks, lines 18-1128. The bar is 400 significant lines; this is 372 over it, 1.93\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2cb4fcb8a7301c7dbc2b845c8f13d756110b045ff71b350c6699195ec28fa7b"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.SendChannelMessage: MethodTooLong \u2014 SendChannelMessage runs 193 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 93 over it, 1.93\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f70203ed30553dbf30c79fe0e1fab0af6ec587005549ccffddf8bdc78d3a28b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/channel_members.go: FileTooLong \u2014 957 significant lines (blank, comment-only and punctuation-only lines excluded), about 88% of them inside a single declaration: ChannelStore (30 blocks, 15-1121). The bar is 500 significant lines; this is 457 over it, 1.91\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc89077b0995ec187e0b225533b9dfd6fbe8a536ec0c5297f2ffe6392b2df079"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Deps: TooManyFields \u2014 57 stored fields. The bar is 30 stored fields; this is 27 over it, 1.90\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":1149}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7955c145c648c1bed10da414c7e2eca73a9c86d3c1038813fcd245edacb0c24"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: DialogStore.listByUser: MethodTooLong \u2014 listByUser runs 188 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 88 over it, 1.88\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"337c694719dbaaed33bb76f16ccdf51a1be7b84812bb4d2cd1d1285a6586895c"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ReadModelChangeListener.handlePayload: MethodTooLong \u2014 handlePayload runs 188 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 88 over it, 1.88\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_listener.go"},"region":{"startLine":381}}}],"partialFingerprints":{"codehealthFindingId/v1":"04eecbdded0ec5ee9dba09b8326d22580eb49b2f50c822939b82f15e24f07d4f"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.finishDeleteMessagesTx: MethodTooLong \u2014 finishDeleteMessagesTx runs 187 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 87 over it, 1.87\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"de58d935288ac636079e9382a795df2420a616d24880424ff783dc9aebfce28c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Router: TooManyFields \u2014 56 stored fields beside 1671 methods. The bar is 30 stored fields; this is 26 over it, 1.87\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"1db8dd1a777ab61504f38d58587ba4a01ed929c01a0e58f580b282fdc79a3b09"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/community.go: FileTooLong \u2014 931 significant lines (blank, comment-only and punctuation-only lines excluded), about 69% of them inside a single declaration: CommunityStore (25 blocks, 20-1383). The bar is 500 significant lines; this is 431 over it, 1.86\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1ac11e80e182e48b8452f8214295453074099d563d8835cfc404c9c4d85dacc"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: account/service.go: FileTooLong \u2014 929 significant lines (blank, comment-only and punctuation-only lines excluded), about 78% of them inside a single declaration: Service (57 blocks, 38-1404). The bar is 500 significant lines; this is 429 over it, 1.86\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"28323c3aac7ae70e529147777684157d10ff2a2036375ffcbb4e1d7db9ec8dab"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: bots/verifybot.go: FileTooLong \u2014 926 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 426 over it, 1.85\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifybot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf3526149713c97131f67d3d23eba0a46558d0c88465a915b61833e902eff65d"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: StarGiftUpgradeStore.UpgradeStarGift: MethodTooLong \u2014 UpgradeStarGift runs 185 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 85 over it, 1.85\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd6ca6be20eda88617e34cb772889bf2c4aa7c2a3ce588b4520ee0d35e40ed38"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: bots/verifierbot.go: FileTooLong \u2014 917 significant lines (blank, comment-only and punctuation-only lines excluded), about 63% of them inside a single declaration: Service (32 blocks, 277-1596). The bar is 500 significant lines; this is 417 over it, 1.83\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a336065baebe9323f65cb90312f93cfa5ee328f88791e146475b701a728c546"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 55 methods, declared across 5 files: dialogs/service.go (37), dialogs/read_model_cache.go (11), dialogs/shared_list_snapshot.go (4), dialogs/list_hash_cache.go (2), \u002B1 more file(s). The bar is 30 methods; this is 25 over it, 1.83\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"64a6f30244b654fae4a3e7f3cb40b73e1df0da5524bc492aaad66a20e09932b5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/dialog.go: FileTooLong \u2014 914 significant lines (blank, comment-only and punctuation-only lines excluded), about 84% of them inside a single declaration: DialogStore (36 blocks, 18-1128). The bar is 500 significant lines; this is 414 over it, 1.83\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a6d309d4226c9b45ae2d61c91312551087ffa511c0a014ad115f558e8d37025"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/inbound_layer_rpc.go: FileTooLong \u2014 913 significant lines (blank, comment-only and punctuation-only lines excluded), about 74% of them inside a single declaration: Server (14 blocks, 105-1329). The bar is 500 significant lines; this is 413 over it, 1.83\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"249e4f8e93f854f9d50a0a8414fc7a81964f498e4b2bb2f2be74363f9afb5192"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 730 significant lines (blank, comment-only and punctuation-only lines excluded), 42 methods, 43 blocks, lines 49-1414. The bar is 400 significant lines; this is 330 over it, 1.83\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"97df4d4f5901f8b11c45dd5e77a461f8e5c42b4f7e6163d441dc2c8c9fdba41d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: files/photos.go: FileTooLong \u2014 912 significant lines (blank, comment-only and punctuation-only lines excluded), about 71% of them inside a single declaration: Service (44 blocks, 31-1278). The bar is 500 significant lines; this is 412 over it, 1.82\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"81d46afccdfa5a82189d5803db3e2c5e4e596c51488d44f7281bfb053b2dbcb2"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: web/server.go: FileTooLong \u2014 910 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 410 over it, 1.82\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5fb740dd428cb77179bdcc2f654e26aacb1a811a501662387357cea26acfa0c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/channel_settings.go: FileTooLong \u2014 909 significant lines (blank, comment-only and punctuation-only lines excluded), about 98% of them inside a single declaration: ChannelStore (25 blocks, 15-1295). The bar is 500 significant lines; this is 409 over it, 1.82\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"de7a0d77e55b591887194e796b0a92c420aedec4b34de07278695615711a2acc"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 727 significant lines (blank, comment-only and punctuation-only lines excluded), 100 methods, 57 blocks, lines 38-1404. The bar is 400 significant lines; this is 327 over it, 1.82\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"36e05c0dc84911a1927db63c1e3b55b084dfc214171b209ea9440dfb576867d9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/deps.go: FileTooLong \u2014 905 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 405 over it, 1.81\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"47f6469735c5e31f70ab1af512f8cd66c5a381cf0a4659096f6f40079c9b474a"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: PasswordStore: TooManyMethods \u2014 54 methods, declared across 2 files: postgres/account.go (27), postgres/business.go (27). The bar is 30 methods; this is 24 over it, 1.80\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"47ffe074154b8a07e91127e3d688d1fa991ceb801c0f2e6c3c2ffd5433e0503d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Channel: TooManyFields \u2014 54 stored fields beside 1 method. The bar is 30 stored fields; this is 24 over it, 1.80\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/channel.go"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"b965e1d793e07a72075b867c2a5d31d87ae270f4182a8bff209a2376e9a1809e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/bots_inline.go: FileTooLong \u2014 900 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 400 over it, 1.80\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"84fee121454f4a19e9fc97b6c2cee3d3e80980fac2cddc504d8ced61b055fddb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/messages_send.go: FileTooLong \u2014 900 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 400 over it, 1.80\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e1ffc82439ec8d2b9e41579db1cc77298f62fa3e808236724b4137d0ed8dacf"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 708 significant lines (blank, comment-only and punctuation-only lines excluded), 55 methods, 38 blocks, lines 22-1305. The bar is 400 significant lines; this is 308 over it, 1.77\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"762f159e526ec6971ff01356f2a5c445458e69037f56cc11e7f8f9a969cfbe2e"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: PasswordStore: TooManyMethods \u2014 53 methods, declared across 2 files: memory/business.go (27), memory/password.go (26). The bar is 30 methods; this is 23 over it, 1.77\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"f52d0442f1f515dadfeb2c00cfccac02fa23b12b0bdf34425716ca1a9bffb23d"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: server.routes: MethodTooLong \u2014 routes runs 176 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 76 over it, 1.76\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"63a3ee92baf22b66018be6c7dfabbcc6bb0cf0ede53f8a17e581ad0239419244"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/contacts.go: FileTooLong \u2014 875 significant lines (blank, comment-only and punctuation-only lines excluded), about 88% of them inside a single declaration: Router (38 blocks, 32-1237). The bar is 500 significant lines; this is 375 over it, 1.75\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d934d96a7f01511f74cefd44734bc8565a6bd13db21521db95bd52ee9dbd293"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/send_media.go: FileTooLong \u2014 873 significant lines (blank, comment-only and punctuation-only lines excluded), about 77% of them inside a single declaration: Router (8 blocks, 56-1213). The bar is 500 significant lines; this is 373 over it, 1.75\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4949919e08037933fcbc5c910e0372e8a5e74d108d41df68f628cb3c5e4f72ff"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 52 methods. The bar is 30 methods; this is 22 over it, 1.73\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c4541b6d65f407ee85a71fb59085229fbc906c98066cfa7fcee3c5b45ef5f8a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/star_gift_craft_auction.go: FileTooLong \u2014 864 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: StarGiftLifecycleStore (16 blocks, 78-1268). The bar is 500 significant lines; this is 364 over it, 1.73\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec61371040448c6eecb3708e1f96295a28a0c4ffd87a30d45c8daac8e5753f2d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/update_event.go: FileTooLong \u2014 862 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 362 over it, 1.72\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2dec2c45cc15f59daf1ecfe8a035cc4ba9bab1f591756d1236454ee12c16fac4"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/messages_dialogs.go: FileTooLong \u2014 858 significant lines (blank, comment-only and punctuation-only lines excluded), about 92% of them inside a single declaration: Router (32 blocks, 14-1192). The bar is 500 significant lines; this is 358 over it, 1.72\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3b655c1aec6f5613d3ac53599f01f0af45eb4be34a8ca27cd191ad5a260934a"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: ModerationReportStore: ClassTooLong \u2014 686 significant lines (blank, comment-only and punctuation-only lines excluded), 31 methods, 32 blocks, lines 16-962. The bar is 400 significant lines; this is 286 over it, 1.72\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"c85b774ea920ded14f0916b87d01a5d3ddbbf44b3dc6c92a67ca77d4171b9e5d"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: GroupCallStore: ClassTooLong \u2014 671 significant lines (blank, comment-only and punctuation-only lines excluded), 33 methods, 34 blocks, lines 19-1303. The bar is 400 significant lines; this is 271 over it, 1.68\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"be635a8e6a7c8990ec2d7960e82451b11197234513add8836e553a727b4cb3b5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: files/seed.go: FileTooLong \u2014 837 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 337 over it, 1.67\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e194771b3947a6585d843845dd327901de8bea945fa51500c75589f58fd3a95"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.EditChannelMessage: MethodTooLong \u2014 EditChannelMessage runs 166 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 66 over it, 1.66\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9eaa7d5a0bf5224e6bf30c86523a583e4a7f6b1b29bf3b8164fc04b8b7914d8"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.ListByUser: MethodTooLong \u2014 ListByUser runs 166 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 66 over it, 1.66\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"a804babefd78db65dcfa4bb6930e0247a89c0e276e9177c17aa0d10a37536293"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/channel_fanout_dispatcher.go: FileTooLong \u2014 828 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 328 over it, 1.66\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b56b9a9b6633f4447682a15978ac91d464efad72a1f5c5b9371366ad984fc82"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/community.go: FileTooLong \u2014 821 significant lines (blank, comment-only and punctuation-only lines excluded), about 95% of them inside a single declaration: CommunityStore (34 blocks, 16-1112). The bar is 500 significant lines; this is 321 over it, 1.64\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ca88442b414774c566940ccc96ebbfc132e6b5516c33789aef31e00b9111677"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/star_gift_upgrade.go: FileTooLong \u2014 817 significant lines (blank, comment-only and punctuation-only lines excluded), about 73% of them inside a single declaration: StarGiftUpgradeStore (8 blocks, 24-1249). The bar is 500 significant lines; this is 317 over it, 1.63\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f479acd9ed14f9f1dcde4c131274b502846b0d0f39d7b2f384042913f741fbf"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: MediaStore: ClassTooLong \u2014 649 significant lines (blank, comment-only and punctuation-only lines excluded), 69 methods, 48 blocks, lines 25-1607. The bar is 400 significant lines; this is 249 over it, 1.62\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"f336aeb3d88b8b143ddd55439803ffd7326ebbe665b2633e54e5dd5ed2fcfc1c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/groupcall.go: FileTooLong \u2014 811 significant lines (blank, comment-only and punctuation-only lines excluded), about 83% of them inside a single declaration: GroupCallStore (34 blocks, 19-1303). The bar is 500 significant lines; this is 311 over it, 1.62\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cb10a63e1493741b1337391d48e6505d203d614d9390e76be8d3bcb7b6332e8"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.GetChannelStats: MethodTooLong \u2014 GetChannelStats runs 162 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 62 over it, 1.62\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7dc77b45a8641a693f66a0e70269ef073eb63fbbd295b58f830d5104096a4e0"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: CommunityStore: ClassTooLong \u2014 646 significant lines (blank, comment-only and punctuation-only lines excluded), 24 methods, 25 blocks, lines 20-1383. The bar is 400 significant lines; this is 246 over it, 1.62\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e2138b703025ea10767a78f9224a3d23a3a6fe63cc51015de1554dacfe9e86e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: userprojection/contact_cache.go: FileTooLong \u2014 806 significant lines (blank, comment-only and punctuation-only lines excluded), about 74% of them inside a single declaration: CachedContactStore (41 blocks, 175-1072). The bar is 500 significant lines; this is 306 over it, 1.61\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d86e92e516b94df0033b9ee03a2f8d62078de1f1635957c34d485b893eb2d9c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: StoryStore: TooManyMethods \u2014 48 methods. The bar is 30 methods; this is 18 over it, 1.60\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea65351d0961cd288c3e699cd828ce380da96298d03c04acc157c0d3fc4aa458"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.ListChannelHistory: MethodTooLong \u2014 ListChannelHistory runs 159 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 59 over it, 1.59\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"949c72f1741a5407cb17acc8f0410dd9048be9b4511c51254912fd2d54650c36"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/payments_star_gift_lifecycle.go: FileTooLong \u2014 793 significant lines (blank, comment-only and punctuation-only lines excluded), about 87% of them inside a single declaration: Router (37 blocks, 17-1157). The bar is 500 significant lines; this is 293 over it, 1.59\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"537d9d50a78a3ae759186ab70948f3fb32c6d54a111592599bab2b0db9628943"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: loadharness/startup.go: FileTooLong \u2014 792 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 292 over it, 1.58\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b84b48a2c51e0be9d775ca39d1f601070ced74e8e0fe877c14f9239ba3ae48a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/moderation_cases.go: FileTooLong \u2014 785 significant lines (blank, comment-only and punctuation-only lines excluded), about 61% of them inside a single declaration: ModerationReportStore (15 blocks, 15-887). The bar is 500 significant lines; this is 285 over it, 1.57\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"15664e9673f09b98e669f1deb060bf7533122425aac16bcb8e4e4587acacfd58"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: botapi.parseBotAPIMarkdownV2: FunctionTooLong \u2014 parseBotAPIMarkdownV2 runs 157 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 57 over it, 1.57\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":645}}}],"partialFingerprints":{"codehealthFindingId/v1":"25964598e3249d250dfb8a0e46e6082f5320b8dbe3595b80160aac9e84b5d62d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/contact.go: FileTooLong \u2014 779 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 279 over it, 1.56\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e7f1598f3f2ef633e4895a45852d12536eb271036b47da66cd5e1ec8e422951"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: verification/service.go: FileTooLong \u2014 770 significant lines (blank, comment-only and punctuation-only lines excluded), about 74% of them inside a single declaration: Service (37 blocks, 166-1341). The bar is 500 significant lines; this is 270 over it, 1.54\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4012ae9b77fdb2565ad8faa42b6ade29dbca606b8cb5b65faab69424aa2ba284"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Service.sweep: MethodTooLong \u2014 sweep runs 154 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 54 over it, 1.54\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/sweep.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"10a4bb7c4b4a739cf27449c978baa48910ae5157b8949e2047528844825dce14"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.domainInlineResultFromTG: MethodTooLong \u2014 domainInlineResultFromTG runs 154 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 54 over it, 1.54\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b8e6d1e65a11468b8ae32cfcb541204d0c2d7b0a507e0f74524cd62de116c51"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.listChannelDialogs: MethodTooLong \u2014 listChannelDialogs runs 154 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 54 over it, 1.54\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"19b5ff2e19334040823667162e79389a56fe4f788b928e8e8f5d30b379b52eb1"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: botapi/formatted_text.go: FileTooLong \u2014 769 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 269 over it, 1.54\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"971cf067cc7455e7fff9e9116267b4d12e7424c026b314d5ae322d024f247ed0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/rpc_rewrap.go: FileTooLong \u2014 768 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 268 over it, 1.54\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_rewrap.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"49e20731c4717b9d3719b0bf7fcac439def81082a0a0004fafba9705b674ff5d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/verification.go: FileTooLong \u2014 763 significant lines (blank, comment-only and punctuation-only lines excluded), about 71% of them inside a single declaration: VerificationStore (19 blocks, 42-1022). The bar is 500 significant lines; this is 263 over it, 1.53\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"30d7579da06dd403f39791d8fbf1e7a3642fad4f2a6cc38d79a6c71d3b75dcd0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: bots/botfather.go: FileTooLong \u2014 760 significant lines (blank, comment-only and punctuation-only lines excluded), about 79% of them inside a single declaration: Service (26 blocks, 89-1061). The bar is 500 significant lines; this is 260 over it, 1.52\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"06313c9f11ef237f007500949af06e50b7879948077ccf57a3688fc433325f0a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/auth.go: FileTooLong \u2014 756 significant lines (blank, comment-only and punctuation-only lines excluded), about 85% of them inside a single declaration: Router (39 blocks, 30-1162). The bar is 500 significant lines; this is 256 over it, 1.51\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c1b67482b21e4b07d44f7e6beb3a608d3fd274e471a0460db679b7cb0820731"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/moderation.go: FileTooLong \u2014 751 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: ModerationReportStore (32 blocks, 16-962). The bar is 500 significant lines; this is 251 over it, 1.50\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"76a6f17d396bf9adec2d02d084e3536feee9623c57c64430af19096fc1eb274f"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 45 methods, declared across 2 files: botverification/service.go (44), botverification/seed.go (1). The bar is 30 methods; this is 15 over it, 1.50\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"b90b6f7c6aab173415421539ac67a7999b22931d4f6fe5b292ac9bae6678acd9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 45 methods. The bar is 30 methods; this is 15 over it, 1.50\u00D7 the bar. Most of these members implement rpc.UpdatesService (33 of 45 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f4203c9aebb28e7783d4902c6649fdbe469c83247f76329fa1539f791ccbdbb"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: BotStore: TooManyMethods \u2014 45 methods, declared across 2 files: postgres/bot_miniapp.go (25), postgres/bot.go (20). The bar is 30 methods; this is 15 over it, 1.50\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. Most of these members implement store.BotStore (39 of 45 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e41736633ec5afc6be55a25f6cdc858c1f1c73bdab9938ed44f070c88be373d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: TelegramLoginRequest: TooManyFields \u2014 45 stored fields beside 3 methods. The bar is 30 stored fields; this is 15 over it, 1.50\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/telegram_login.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0ce8590b3d76fb95795e1ac2f65372550e78607ef9508ad9e8629d3a621f8a3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/botapi_gateway.go: FileTooLong \u2014 750 significant lines (blank, comment-only and punctuation-only lines excluded), about 77% of them inside a single declaration: Router (33 blocks, 22-1073). The bar is 500 significant lines; this is 250 over it, 1.50\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"927bf7ecc34523710972e757ef789cd92e9c52e21c03f1518eb85011f2922fee"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: StarGiftUpgradeStore: ClassTooLong \u2014 598 significant lines (blank, comment-only and punctuation-only lines excluded), 7 methods, 8 blocks, lines 24-1249. The bar is 400 significant lines; this is 198 over it, 1.50\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"0117731ef32535945b39e66311df612ab642adb5cc853fb7cb298bb0cccfe2ed"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: CachedContactStore: ClassTooLong \u2014 597 significant lines (blank, comment-only and punctuation-only lines excluded), 42 methods, 41 blocks, lines 175-1072. The bar is 400 significant lines; this is 197 over it, 1.49\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"011ad6592ac5f9f658f19147af78d9db9bd1f47dc64b957ff2a28c5ed5b5ea29"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.onMessagesSendMedia: MethodTooLong \u2014 onMessagesSendMedia runs 149 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 49 over it, 1.49\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e64be4bf01d99a4f77fa8b93ae2b452c9d4f7fe14d68e12e6b691f6acc8932d"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.SendMonoforumMessage: MethodTooLong \u2014 SendMonoforumMessage runs 149 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 49 over it, 1.49\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_monoforum.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9399ebc02783d95c62a2a6c539c07a890a290f89874ccfea909869fe2b0b3df"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/bot_verification.go: FileTooLong \u2014 740 significant lines (blank, comment-only and punctuation-only lines excluded), about 69% of them inside a single declaration: BotVerificationStore (26 blocks, 54-1108). The bar is 500 significant lines; this is 240 over it, 1.48\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4448ea7492c2d9e60d690aba2e3021bd3ab82ddc7d16ce7538086caeb48b211d"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.ReadMessageContents: MethodTooLong \u2014 ReadMessageContents runs 148 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 48 over it, 1.48\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_read.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"51ceb928dbdfc2ff89e83324dacddebed9c83413ee8c827d7a0f632f85e4748e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/inbound_rpc.go: FileTooLong \u2014 739 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 239 over it, 1.48\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_rpc.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"47aa63c7cc4193d4bd915f9bc89c8bee856b0fd7f44ad1dd2084f6fdeffa3c21"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/messages_history.go: FileTooLong \u2014 739 significant lines (blank, comment-only and punctuation-only lines excluded), about 80% of them inside a single declaration: Router (20 blocks, 13-949). The bar is 500 significant lines; this is 239 over it, 1.48\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d0323e47dbbdd02854919f497cfa5033faf42b09b494ae0a00c4622da9c9bdc"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/channel_invites.go: FileTooLong \u2014 737 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: ChannelStore (26 blocks, 13-981). The bar is 500 significant lines; this is 237 over it, 1.47\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d557e54ba589bc4a65bb3e86ae6c39bf4087a92f45a97466eb421d3c99e15131"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.sendSingleSendMessage: MethodTooLong \u2014 sendSingleSendMessage runs 147 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 47 over it, 1.47\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"2165345bae043aad9e874df577a4cae0a2218bd10fbb753125008379cc731e02"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: StarGiftLifecycleStore.CraftStarGift: MethodTooLong \u2014 CraftStarGift runs 147 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 47 over it, 1.47\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"d01e61ca6e610aefbc2d96f3fc54c15bbeb7e2e8d89a680f2e66a6a9a742cab3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Server: TooManyFields \u2014 44 stored fields beside 84 methods. The bar is 30 stored fields; this is 14 over it, 1.47\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":508}}}],"partialFingerprints":{"codehealthFindingId/v1":"4752535141d101217b3fa6c7ba34a2f9a316d25888755fb4f87a631f5266b964"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: User: TooManyFields \u2014 44 stored fields beside 4 methods. The bar is 30 stored fields; this is 14 over it, 1.47\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/user.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"4198f275107ee8d154c59f3f5d467074a3f0972a0232e25b168ecd53c1b40233"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: savedDialogTopRowFields: TooManyFields \u2014 44 stored fields. The bar is 30 stored fields; this is 14 over it, 1.47\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb0dbdd5053a807635dd6087dbd43a1598d635fd09f7e092948a8fbaec41caf5"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: StarGiftStore: ClassTooLong \u2014 582 significant lines (blank, comment-only and punctuation-only lines excluded), 40 methods, 41 blocks, lines 14-967. The bar is 400 significant lines; this is 182 over it, 1.46\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fb77e848c7c5347f6bc3dbf1f89a083ed67e5380b420d4c61041cde5f381bc8"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.readHistoryOnce: MethodTooLong \u2014 readHistoryOnce runs 145 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 45 over it, 1.45\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea18df6205e2d6182dd3d3fe225dbc344f3a7278de44233874db1d09b8b7e7c5"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: TelegramLoginStore: ClassTooLong \u2014 579 significant lines (blank, comment-only and punctuation-only lines excluded), 29 methods, 30 blocks, lines 18-1093. The bar is 400 significant lines; this is 179 over it, 1.45\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5f704f5fdc94d90ac5c16a43b4e09a0f15cc25e5dc79299433078f54a14c4b2"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 578 significant lines (blank, comment-only and punctuation-only lines excluded), 86 methods, 81 blocks, lines 30-1068. The bar is 400 significant lines; this is 178 over it, 1.45\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd5c3269b03feba4f1e151285adeb01d99c7a90e78f0e954795a49aad766b623"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Server.prepareInboundRPCBatch: MethodTooLong \u2014 prepareInboundRPCBatch runs 144 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 44 over it, 1.44\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"611c7b99167a2904b1d8e100bb6783b906d0afcaa3e6843a38a9e3f7b5981c13"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/inbound_preflight.go: FileTooLong \u2014 719 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 219 over it, 1.44\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d45e955f9972b79a6e2125fee275c593225a9abaa74bf79437cf8ea60331e623"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/message_send.go: FileTooLong \u2014 719 significant lines (blank, comment-only and punctuation-only lines excluded), about 78% of them inside a single declaration: MessageStore (9 blocks, 17-918). The bar is 500 significant lines; this is 219 over it, 1.44\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff18ccbb146fef91224b4a9ca708eb1ac06dfa7ea11a551f5b060c6756f74c90"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: BotStore: TooManyMethods \u2014 43 methods. The bar is 30 methods; this is 13 over it, 1.43\u00D7 the bar. Most of these members implement store.BotStore (39 of 43 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"979ec6e954396d253d9d7928293daaea62358f25ebd1ec3ce725b82b0dc08a18"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Options: TooManyFields \u2014 43 stored fields beside 1 method. The bar is 30 stored fields; this is 13 over it, 1.43\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"de7b9704188bfe61451ddd9eda54616ee5c67960b8a1ab2d8145780145dd4e54"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: botverification/service.go: FileTooLong \u2014 715 significant lines (blank, comment-only and punctuation-only lines excluded), about 78% of them inside a single declaration: Service (43 blocks, 188-1468). The bar is 500 significant lines; this is 215 over it, 1.43\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"da949cd39e506fca15690fe64c171946a93432524ca08042b7bc48ac632ecc14"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/convert_channels_core.go: FileTooLong \u2014 713 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 213 over it, 1.43\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"86045c83432c211c161a01fcb60471c61cc499fe18914f480e050ce2ba0add71"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/channel_topics.go: FileTooLong \u2014 713 significant lines (blank, comment-only and punctuation-only lines excluded), about 89% of them inside a single declaration: ChannelStore (20 blocks, 14-956). The bar is 500 significant lines; this is 213 over it, 1.43\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"acac52254651b11fd1959d47b88e027570601279c3a7763cb91d4562da92d459"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/channels_members.go: FileTooLong \u2014 711 significant lines (blank, comment-only and punctuation-only lines excluded), about 83% of them inside a single declaration: Router (25 blocks, 15-927). The bar is 500 significant lines; this is 211 over it, 1.42\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e56b7cecf9aba20dd9157a3da6becfebda318389b9c285fa5a8916ea26db783"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 568 significant lines (blank, comment-only and punctuation-only lines excluded), 39 methods, 37 blocks, lines 166-1341. The bar is 400 significant lines; this is 168 over it, 1.42\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a94479c095a812dbe0c1db29675db0b7147357ceaa6faf51912c1ea8549513e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/dialogs.go: FileTooLong \u2014 707 significant lines (blank, comment-only and punctuation-only lines excluded), about 64% of them inside a single declaration: DialogStore (33 blocks, 13-679). The bar is 500 significant lines; this is 207 over it, 1.41\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"041af7f0de005436ac17bc7aa31598df8ff950e30ec9a48e4d2b2a019f5c34c4"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/server.go: FileTooLong \u2014 706 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 206 over it, 1.41\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6dd91f95abeb699940f42584654f16b59cb0b2d96c832db33351c13380d62c2"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: GroupCallStore: ClassTooLong \u2014 564 significant lines (blank, comment-only and punctuation-only lines excluded), 32 methods, 33 blocks, lines 37-875. The bar is 400 significant lines; this is 164 over it, 1.41\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e84f7f33ff18418921270f7b3a05a7c8ebe760e214785ad548f4fc8b699f765"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: StarGiftLifecycleStore.PurchaseResaleStarGift: MethodTooLong \u2014 PurchaseResaleStarGift runs 141 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 41 over it, 1.41\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"0be7aa8dd07be0e04c86297ea0d6acc2ecb918f8babf3b57f62c7eabd3514f01"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: StarGiftUpgradeStore.GrantUniqueStarGift: MethodTooLong \u2014 GrantUniqueStarGift runs 141 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 41 over it, 1.41\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebb035eb3002c77cb938ad6e34eede7e719721b459fd87b989d8d4be336beb4d"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: botapi/projection.go: FileTooLong \u2014 704 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 204 over it, 1.41\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"28ae27b495d940d4b671603a73e0750cbf3bf27259335c6ed228b61b0f3af0ab"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/telegram_login.go: FileTooLong \u2014 704 significant lines (blank, comment-only and punctuation-only lines excluded), about 82% of them inside a single declaration: TelegramLoginStore (30 blocks, 18-1093). The bar is 500 significant lines; this is 204 over it, 1.41\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"63f9b31511924db8a960200b25b9c50615fc0dbf64f5dba26e43bfe2253b1e27"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 42 methods. The bar is 30 methods; this is 12 over it, 1.40\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"11282ba708d3fdd3db1ceff5d24bb18af126a27db161f9f1c16d636c1ea0763d"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: CachedContactStore: TooManyMethods \u2014 42 methods, declared across 2 files: userprojection/contact_cache.go (40), userprojection/contact_cache_sparse.go (2). The bar is 30 methods; this is 12 over it, 1.40\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb2e6bbe97544693917018c8efaf61ec639439f3af955a19029bc08b0fd572bd"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/messages_register.go: FileTooLong \u2014 699 significant lines (blank, comment-only and punctuation-only lines excluded), about 99% of them inside a single declaration: Router (15-1005). The bar is 500 significant lines; this is 199 over it, 1.40\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_register.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc1238e6d0e181a87e679eb13458aa63f1a32d9a7394f09e4d65927637446579"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 557 significant lines (blank, comment-only and punctuation-only lines excluded), 45 methods, 43 blocks, lines 188-1468. The bar is 400 significant lines; this is 157 over it, 1.39\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"911204c58ceaf91fd50a4665328ec516aa37d47ff9be42052dd49415cf9187b7"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: UpdateEventStore.BatchByCursor: MethodTooLong \u2014 BatchByCursor runs 139 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 39 over it, 1.39\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"029623ae3aa36db02deb8d5f2bafe09a27b7f69ddc1b3d3ea5d211f48efc20fb"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.GetChannelDialogs: MethodTooLong \u2014 GetChannelDialogs runs 138 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 38 over it, 1.38\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":755}}}],"partialFingerprints":{"codehealthFindingId/v1":"c74d86b78ac836b851f40415606c11b0d67ea9d6fb9c1e618e68a31f09d39b82"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/star_gift.go: FileTooLong \u2014 689 significant lines (blank, comment-only and punctuation-only lines excluded), about 84% of them inside a single declaration: StarGiftStore (41 blocks, 14-967). The bar is 500 significant lines; this is 189 over it, 1.38\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe775b70613c8b6ccf498849028c8a215cfb7989fe9d7e56c382d12fec5ead8e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/presence.go: FileTooLong \u2014 686 significant lines (blank, comment-only and punctuation-only lines excluded), about 70% of them inside a single declaration: Router (40 blocks, 266-1139). The bar is 500 significant lines; this is 186 over it, 1.37\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"40130c9ea968ee7e850d462e44683705d6dad59b637ecc89688f8b092b801c0e"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.DeliverLoginCodeMessage: MethodTooLong \u2014 DeliverLoginCodeMessage runs 137 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 37 over it, 1.37\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/login_code_delivery.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb6fd7f60583796dc239ddd7980fe7625180acad859eb4d9b93d68a45b2aea98"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Registry: TooManyMethods \u2014 41 methods. The bar is 30 methods; this is 11 over it, 1.37\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/observability/metrics/registry.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2b94f6671975d737f593c847ba343649ce6f46c46ab1b4e07ef51230199a6a3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: StoryStore: TooManyMethods \u2014 41 methods. The bar is 30 methods; this is 11 over it, 1.37\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"d25275de3ca5ddfb7d188a998481f6abf075bae569f79204c1183f17b303ad55"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: UniqueStarGift: TooManyFields \u2014 41 stored fields. The bar is 30 stored fields; this is 11 over it, 1.37\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"f369d7aab0f969b855e7443fa0c5783b1111a95d140ed1a61b67658533fb7de7"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: stargifts/service.go: FileTooLong \u2014 681 significant lines (blank, comment-only and punctuation-only lines excluded), about 85% of them inside a single declaration: Service (81 blocks, 30-1068). The bar is 500 significant lines; this is 181 over it, 1.36\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"99ecc4612a10ec9191b03518751fc568ce2d5b17dffdfbbc9e9fce13f9424086"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.GetChannelStats: MethodTooLong \u2014 GetChannelStats runs 135 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 35 over it, 1.35\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ed72371a2c73ca946ac67ee20f2043fb290488001d4839f05bf39107707cd58"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: UpdateEventStore.ListAfter: MethodTooLong \u2014 ListAfter runs 135 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 35 over it, 1.35\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c5f082781a5e3c85dca4df08e2a93bd93dc11dc83d9f7b487d409dc6651e1d4"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: VerificationStore: ClassTooLong \u2014 539 significant lines (blank, comment-only and punctuation-only lines excluded), 18 methods, 19 blocks, lines 42-1022. The bar is 400 significant lines; this is 139 over it, 1.35\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"44ed3c92bcf8d6dcbb37a1fc3abe525a020c5dd485a8700353cde83d20c45683"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: UserStore: ClassTooLong \u2014 534 significant lines (blank, comment-only and punctuation-only lines excluded), 28 methods, 29 blocks, lines 21-947. The bar is 400 significant lines; this is 134 over it, 1.34\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2506669669862b0f22fa6985dae5ffe0a4aa0627992871def92c99145fbf6fe"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/user.go: FileTooLong \u2014 667 significant lines (blank, comment-only and punctuation-only lines excluded), about 80% of them inside a single declaration: UserStore (29 blocks, 21-947). The bar is 500 significant lines; this is 167 over it, 1.33\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"433efa225b634afaf2e5a24d383eb7d9eb80c5bf97e524c5f48692c1f69ed800"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 40 methods, declared across 6 files: donations/service.go (23), donations/watcher.go (7), donations/pricefeed.go (3), donations/pricing.go (3), \u002B2 more file(s). The bar is 30 methods; this is 10 over it, 1.33\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/service.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"aeb82ebfa27ad5269acf4e0954dcb41f7f97f3600120620a643fc5a27e58589c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 40 methods, declared across 2 files: users/service.go (39), users/service_sparse.go (1). The bar is 30 methods; this is 10 over it, 1.33\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc2f081075fc6614092db5ddcdfb8454ad846030fc27019236c708bd17ee91e1"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: StarGiftStore: TooManyMethods \u2014 40 methods. The bar is 30 methods; this is 10 over it, 1.33\u00D7 the bar. Most of these members implement store.StarGiftStore (32 of 40 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"85c35e6765181789f5e148b0373dcd93e987d70e21fa5418d2d60c0fdebe26c9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: RunReport: TooManyFields \u2014 40 stored fields. The bar is 30 stored fields; this is 10 over it, 1.33\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/report.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0b7716166e79bd97757d4ac95a3eb146ad2c235a77523b67ebd08eda866b5ee"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: RuntimeSnapshot: TooManyFields \u2014 40 stored fields. The bar is 30 stored fields; this is 10 over it, 1.33\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/runtime_metrics.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"28f2a9b94d59ff7a618170f0694a881d1010701d26acd5ca178753a635dbd942"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/users.go: FileTooLong \u2014 664 significant lines (blank, comment-only and punctuation-only lines excluded), about 83% of them inside a single declaration: Router (18 blocks, 20-1021). The bar is 500 significant lines; this is 164 over it, 1.33\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"83bb6c006911c2f1bd500b110efccb47e5ad4468ac76887f3dd5dffb02d53846"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/channel_reactions.go: FileTooLong \u2014 661 significant lines (blank, comment-only and punctuation-only lines excluded), about 90% of them inside a single declaration: ChannelStore (19 blocks, 12-861). The bar is 500 significant lines; this is 161 over it, 1.32\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"68684d0d4c06970c90b25558d83bbacc4a0971c0f9d92f320c242f21a6feecc8"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.domainPollFromInputMedia: MethodTooLong \u2014 domainPollFromInputMedia runs 132 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 32 over it, 1.32\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_polls.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"770ff3c2ef85cee8adee97decfacadbae26b14d6be94b36e9de6a611e53501d3"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: PasswordStore: ClassTooLong \u2014 527 significant lines (blank, comment-only and punctuation-only lines excluded), 54 methods, 28 blocks, lines 21-999. The bar is 400 significant lines; this is 127 over it, 1.32\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"98c228bb4db308a7a500304d734b4416ba48053074686afe2a75dd46e1b3440f"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 39 methods. The bar is 30 methods; this is 9 over it, 1.30\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"2785aa6f6c0be06ac6cb54ade1757a148096bf9aff77d673aa03ff65770e6eeb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/star_gift_collectibles.go: FileTooLong \u2014 650 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 150 over it, 1.30\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"64b3cc2ade98bf32492a6f9dc0122458302d38b746f4277d0f8fdba10227776a"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.sendOutgoing: MethodTooLong \u2014 sendOutgoing runs 130 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 30 over it, 1.30\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"d66390cc58964106b36b68f055938a6f9293b3de2bd19e2303a614c2972f814c"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: DialogStore.ListByPeers: MethodTooLong \u2014 ListByPeers runs 130 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 30 over it, 1.30\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3baa0590f869837956db37db014e620e96a9ceef5704874c872b915bbb4febd"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: StarGiftLifecycleStore.retireUserStarGiftMessagesTx: MethodTooLong \u2014 retireUserStarGiftMessagesTx runs 130 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 30 over it, 1.30\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle_projection.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8c542bb8993972e9fc27d1e18664895319697902b3b8eb339e8e1a2a68d96c9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: domain/media.go: FileTooLong \u2014 649 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 149 over it, 1.30\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"201ef0e6a608e327db2cc3c95175974752e6a0c1337c89039b22cd7a4dd8dba8"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/bot_verification.go: FileTooLong \u2014 645 significant lines (blank, comment-only and punctuation-only lines excluded), about 78% of them inside a single declaration: BotVerificationStore (33 blocks, 73-939). The bar is 500 significant lines; this is 145 over it, 1.29\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"66c53e9ea648f7f417478ba2d6f2bd218f1e2193cb8ecbf350db0ca8fa815a75"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: serverExchangeCompat.run: MethodTooLong \u2014 run runs 129 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 29 over it, 1.29\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/exchange_compat.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"a859e826af438f7c292a3b0040b2688efd5ec5a85c827c11daaa3429db190cd5"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: rpc.cloneEntityWithBounds: FunctionTooLong \u2014 cloneEntityWithBounds runs 129 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 29 over it, 1.29\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b37525a000af7594f99df6c419ac66417b2a14ff676382b06f0ad33a96ef5d7"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/groupcall.go: FileTooLong \u2014 643 significant lines (blank, comment-only and punctuation-only lines excluded), about 88% of them inside a single declaration: GroupCallStore (33 blocks, 37-875). The bar is 500 significant lines; this is 143 over it, 1.29\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"17ad68c4a495856cadf6c64348ebc270485859091ae6cb708884ac64322f8277"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: StarGiftUpgradeStore.markPrivateStarGiftSourceUpgradedTx: MethodTooLong \u2014 markPrivateStarGiftSourceUpgradedTx runs 128 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 28 over it, 1.28\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":703}}}],"partialFingerprints":{"codehealthFindingId/v1":"875ba590b8595fcd157b8fa6e635aaeaa496f9288d86aba238bce50d1d494b33"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: botapi/inline.go: FileTooLong \u2014 638 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 138 over it, 1.28\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf1b25408c61af6f30075fa049bcfbaf1e10444784535bb64f1b7b3c30f90d5e"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: VerificationStore: ClassTooLong \u2014 510 significant lines (blank, comment-only and punctuation-only lines excluded), 27 methods, 28 blocks, lines 58-852. The bar is 400 significant lines; this is 110 over it, 1.28\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"636096c19c82f21240dac2a4bc419a7a655ae15d1d9abbfc5345385751a6d771"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/bots_longtail.go: FileTooLong \u2014 637 significant lines (blank, comment-only and punctuation-only lines excluded), about 75% of them inside a single declaration: Router (35 blocks, 21-944). The bar is 500 significant lines; this is 137 over it, 1.27\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9b1ffd1e12cb328cc7e72ff774b228b8fb77e18bd55d01d459cad22789194e1"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/verification.go: FileTooLong \u2014 636 significant lines (blank, comment-only and punctuation-only lines excluded), about 80% of them inside a single declaration: VerificationStore (28 blocks, 58-852). The bar is 500 significant lines; this is 136 over it, 1.27\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c48fe8a4cbbf1ba2f88d128391521ab8ee63334704104c3b86853eeb75c2be02"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: BotVerificationStore: ClassTooLong \u2014 508 significant lines (blank, comment-only and punctuation-only lines excluded), 25 methods, 26 blocks, lines 54-1108. The bar is 400 significant lines; this is 108 over it, 1.27\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"65eb5edfd4d70a5d9f3a2c8713e931592b87e361e7ad1f5c4dc75b04e015f2be"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.ToggleSuggestedPostApproval: MethodTooLong \u2014 ToggleSuggestedPostApproval runs 127 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 27 over it, 1.27\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ce2c4ec43af4c875fa9daec75ed3f0bb5cd1c4330b6d266a24cfa088887a79b"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: StarGiftCatalogWrite: TooManyFields \u2014 38 stored fields beside 3 methods. The bar is 30 stored fields; this is 8 over it, 1.27\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"56c763ecffad9b65a6baf6d01141931cf4dc7f4e219051647bdfb20434803aef"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/channel_settings.go: FileTooLong \u2014 633 significant lines (blank, comment-only and punctuation-only lines excluded), about 97% of them inside a single declaration: ChannelStore (26 blocks, 11-837). The bar is 500 significant lines; this is 133 over it, 1.27\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0adbb61278269b75339c24b93398bbeeebd12abd05d325d5b3080d55ca133596"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: BotVerificationStore: ClassTooLong \u2014 504 significant lines (blank, comment-only and punctuation-only lines excluded), 32 methods, 33 blocks, lines 73-939. The bar is 400 significant lines; this is 104 over it, 1.26\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1ef1cac0037e6c1e460c701d8f25a3beb2280f51f88736612854c45686ba2dd"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: telegramloginhttp/handler.go: FileTooLong \u2014 627 significant lines (blank, comment-only and punctuation-only lines excluded), about 72% of them inside a single declaration: Handler (16 blocks, 49-809). The bar is 500 significant lines; this is 127 over it, 1.25\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac9f4941f71277ca5022f8b0e156d4fe5cd1249f718f82c3a58c655f41203f46"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: rpcRewrapAlias.activate: MethodTooLong \u2014 activate runs 125 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 25 over it, 1.25\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_rewrap.go"},"region":{"startLine":855}}}],"partialFingerprints":{"codehealthFindingId/v1":"278391aa16c773a6684659be83c031ac9c61015fef299d272629308fde955823"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.dispatch: MethodTooLong \u2014 dispatch runs 125 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 25 over it, 1.25\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":675}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa4cb6e506fcba5ee9cda1ec53d9e81b682c6064cf7ec9b05263a023a7eb9ffd"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.sendPrivateTextLocked: MethodTooLong \u2014 sendPrivateTextLocked runs 124 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 24 over it, 1.24\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_send.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"79abd4b95f3f8a8d1ff2c97fca9700f6836b7867df5f30a8c96c81e4481062c6"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: ChannelStore: TooManyFields \u2014 37 stored fields beside 256 methods. The bar is 30 stored fields; this is 7 over it, 1.23\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_store.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"66529aec4fafcf3909a1cd48832dd149e155a10dcbea8814c745c1c15941b035"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Service: TooManyFields \u2014 37 stored fields beside 182 methods. The bar is 30 stored fields; this is 7 over it, 1.23\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"df63b6be41759f7923caab6cdd69ef7b75955f78d7a527320735323d91656aa9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: ChannelMessage: TooManyFields \u2014 37 stored fields. The bar is 30 stored fields; this is 7 over it, 1.23\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/channel.go"},"region":{"startLine":699}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5dd06156b4e642dbc49f85c2187d91b6a5a6e7d91f4026ee8baf273d5e6dbde"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.SetDiscussionGroup: MethodTooLong \u2014 SetDiscussionGroup runs 123 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 23 over it, 1.23\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":1121}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ced7f85bd6eb5203d846dd5bd40b9f9efc24d794aa18e97738a415488058a64"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/messages_forward.go: FileTooLong \u2014 614 significant lines (blank, comment-only and punctuation-only lines excluded), about 80% of them inside a single declaration: Router (9 blocks, 13-774). The bar is 500 significant lines; this is 114 over it, 1.23\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f44399e9f2bbda76e5a62bf450e3d753c1a1fe13b27a0f03eba9759d6b772698"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/channel_message_history.go: FileTooLong \u2014 610 significant lines (blank, comment-only and punctuation-only lines excluded), about 97% of them inside a single declaration: ChannelStore (12 blocks, 14-1051). The bar is 500 significant lines; this is 110 over it, 1.22\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"07c7c3348773af54fe3a80ecf0420b8b6a13be0675783b43815511f085f01405"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Server.publishRPCResult: MethodTooLong \u2014 publishRPCResult runs 122 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 22 over it, 1.22\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":880}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c3e2203d9124503b6bffc9bf2ca81eb7810c7f5b84207583d0de740111a1ccb"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.listChannelDifferenceAttempt: MethodTooLong \u2014 listChannelDifferenceAttempt runs 122 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 22 over it, 1.22\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"05db2b7d3f1891c4d1eaf2f5a3faba5dc4fd378b967351a160df118f9a6b9443"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 487 significant lines (blank, comment-only and punctuation-only lines excluded), 40 methods, 40 blocks, lines 30-969. The bar is 400 significant lines; this is 87 over it, 1.22\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e118caf8c0d7e4c51e6a0ece9d665d28ca6fcf72bbef1904d6a978fddbfde88"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: TelegramLoginStore: ClassTooLong \u2014 487 significant lines (blank, comment-only and punctuation-only lines excluded), 31 methods, 32 blocks, lines 20-721. The bar is 400 significant lines; this is 87 over it, 1.22\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0108eb0054c3fe147a9c2b642b9935488fd335c571f346146ec19bccf839c70"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/channel_helpers.go: FileTooLong \u2014 608 significant lines (blank, comment-only and punctuation-only lines excluded), about 73% of them inside a single declaration: ChannelStore (15 blocks, 15-910). The bar is 500 significant lines; this is 108 over it, 1.22\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"53e49e57a14464ffd4099b7a8a4ec8c7aa51a4ba4a055d4b63104a46a8288c13"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/star_gift.go: FileTooLong \u2014 606 significant lines (blank, comment-only and punctuation-only lines excluded), about 74% of them inside a single declaration: StarGiftStore (20 blocks, 16-964). The bar is 500 significant lines; this is 106 over it, 1.21\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff7fb4ab424f9103c23a3fb7642abe4a947beed391f124c0ec1b7708c6160921"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: SessionManager.pushToUserWithSender: MethodTooLong \u2014 pushToUserWithSender runs 121 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 21 over it, 1.21\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1874}}}],"partialFingerprints":{"codehealthFindingId/v1":"3319f44160c2848592b447007dd95f2dcbe23c662721a5cacb2a1813391caec3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: bots/stickersbot.go: FileTooLong \u2014 604 significant lines (blank, comment-only and punctuation-only lines excluded), about 64% of them inside a single declaration: Service (19 blocks, 73-822). The bar is 500 significant lines; this is 104 over it, 1.21\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bea68d3be4b180ab7cf424023728fddb019274484e0bef2df0c4edae5212c10"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: files/service.go: FileTooLong \u2014 600 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 100 over it, 1.20\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d55441a5328d45692fa1a7ac62cc0dfe1483471b5d7ca557674046afc5623ea"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.onMessagesEditMessage: MethodTooLong \u2014 onMessagesEditMessage runs 120 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 20 over it, 1.20\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe06f7e4d6dfcbbdfa486955f7ae10839acb2790f0981c18ab1eeb22eaf7b61a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: users/service.go: FileTooLong \u2014 598 significant lines (blank, comment-only and punctuation-only lines excluded), about 81% of them inside a single declaration: Service (40 blocks, 30-969). The bar is 500 significant lines; this is 98 over it, 1.20\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff8adbb00362a555852f735e546dee73dc5efdd26cfc3d484350dc4b87e45165"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 478 significant lines (blank, comment-only and punctuation-only lines excluded), 45 methods, 46 blocks, lines 16-821. The bar is 400 significant lines; this is 78 over it, 1.20\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"924620240018f82d6c210537e30ec6b3683b33f588bf4dbb34c8aa279c6d7ee4"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Server.routes: MethodTooLong \u2014 routes runs 119 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 19 over it, 1.19\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8fe77314cc76b97b805f0d4ddcb330fba41de8a26d88ac02a3cd2a6dc8f0931"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: telesrv-admin/privateview_store.go: FileTooLong \u2014 590 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 90 over it, 1.18\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f24d4c5a09662673e86aef25fd829ae913cc22f1a484e4cea6abf45525e25a95"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: mtprotoedge/transport_compat.go: FileTooLong \u2014 590 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 90 over it, 1.18\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/transport_compat.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b0f4d092605b7b3c4cbfd2a72862814d56f587a46d2361a84680cf0d6c324cf"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.EditChannelAdmin: MethodTooLong \u2014 EditChannelAdmin runs 118 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 18 over it, 1.18\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"7248bbaa8b1f23528da9a304f5070ebfca4c807c0886f06188a0d194eb0d26eb"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/account.go: FileTooLong \u2014 584 significant lines (blank, comment-only and punctuation-only lines excluded), about 90% of them inside a single declaration: PasswordStore (28 blocks, 21-999). The bar is 500 significant lines; this is 84 over it, 1.17\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf4e4c0cae0c28d2d2e2fb62790dc23a00d66e07034cbf9921f230d05a381c39"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: DialogStore: TooManyMethods \u2014 35 methods. The bar is 30 methods; this is 5 over it, 1.17\u00D7 the bar. Most of these members implement store.DialogStore (30 of 35 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"0aa4b01e8053fa07afc46a0268762fd036ad037dfe5338292f688c5d6c916a8b"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: StarGiftStore: TooManyMethods \u2014 35 methods, declared across 2 files: postgres/star_gift.go (19), postgres/star_gift_collectibles.go (16). The bar is 30 methods; this is 5 over it, 1.17\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. Most of these members implement store.StarGiftStore (32 of 35 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"608669f8a58efe2b181ed3b47ba19f3e0719c8e527ff1f36ff061c7512d898aa"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: channelDialogProjectionValues: TooManyFields \u2014 35 stored fields beside 2 methods. The bar is 30 stored fields; this is 5 over it, 1.17\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1974}}}],"partialFingerprints":{"codehealthFindingId/v1":"e73fc9c08bc1613d51e2fbc6b0b39227388cd5415e9fc12f7dbef54d388389e7"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: UpdateEvent: TooManyFields \u2014 35 stored fields beside 1 method. The bar is 30 stored fields; this is 5 over it, 1.17\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/update_event.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dbcf4f3657cea189b9e02dae62751c165e3c2bb8cc2ae918263f856a1be0d4d"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Server.handleEncrypted: MethodTooLong \u2014 handleEncrypted runs 116 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 16 over it, 1.16\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"98673bfe5c378267691893502e63f448b90496a0c82455e4c14c9addcc61ae08"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.onMessagesSendMultiMedia: MethodTooLong \u2014 onMessagesSendMultiMedia runs 116 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 16 over it, 1.16\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":464}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9793c752beb625c3cb9ab0e01ac201ef185967dbb49eea34c6184163886c3f2"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: main.main: FunctionTooLong \u2014 main runs 115 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 15 over it, 1.15\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb0188081176192fd65fa564391bd888b35999b72cee4921c42e0bb28c082c8b"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 458 significant lines (blank, comment-only and punctuation-only lines excluded), 66 methods, 55 blocks, lines 13-898. The bar is 400 significant lines; this is 58 over it, 1.15\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e1e979ab1f1b6123343402687f8f408a230cf6574ebf41c7b332e84f1a4076c"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/inline_registry.go: FileTooLong \u2014 571 significant lines (blank, comment-only and punctuation-only lines excluded), about 70% of them inside a single declaration: inlineRegistry (33 blocks, 13-629). The bar is 500 significant lines; this is 71 over it, 1.14\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/inline_registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ffd9524717154b22a62a0a9c219c2f37adec1cd32df1fcebc12f5148a846255"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: DialogStore: ClassTooLong \u2014 456 significant lines (blank, comment-only and punctuation-only lines excluded), 32 methods, 33 blocks, lines 13-679. The bar is 400 significant lines; this is 56 over it, 1.14\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2522bce05b52d21aefdb97a93c32292c7da0549ee27f0d894cc5fe9bb574684"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Server.serveConn: MethodTooLong \u2014 serveConn runs 114 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 14 over it, 1.14\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":997}}}],"partialFingerprints":{"codehealthFindingId/v1":"649b77d1d2230870b0ce9bdd4248f1eb8ab4965cd5fd6322a260f24afe8baae7"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.CreateChannel: MethodTooLong \u2014 CreateChannel runs 114 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 14 over it, 1.14\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"015db10efd0467ebd7d2aa9fc5cf6b751e2608eb0649f570d222f4dd017dbec3"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: postgres.persistPlainPrivateSendProjectionBatch: FunctionTooLong \u2014 persistPlainPrivateSendProjectionBatch runs 114 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 14 over it, 1.14\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_sql.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ba89bebaa4a90c441c720756437053b87e424d98bbfa1c40e60502af81fe1f1"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/convert_messages.go: FileTooLong \u2014 568 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 68 over it, 1.14\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e640b45d323abef7edb7ba1e853078332ccd01e366baa8c6cd81236442d17df0"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/bot.go: FileTooLong \u2014 568 significant lines (blank, comment-only and punctuation-only lines excluded), about 78% of them inside a single declaration: BotStore (44 blocks, 16-747). The bar is 500 significant lines; this is 68 over it, 1.14\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b4c0398912156975f1e782b85d710a2a8d7961283eb5a95c69d02ab5d065067"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: chatlists/service.go: FileTooLong \u2014 567 significant lines (blank, comment-only and punctuation-only lines excluded), about 71% of them inside a single declaration: Service (23 blocks, 16-678). The bar is 500 significant lines; this is 67 over it, 1.13\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c5e9bbd2c3318e698a251a7867aea261e40908bd6c5e4bffa8dbde3d6e397d2"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Manager: TooManyMethods \u2014 34 methods, declared across 4 files: procctl/procctl.go (20), procctl/supervisor.go (9), procctl/bootstrap.go (3), procctl/serverinfo.go (2). The bar is 30 methods; this is 4 over it, 1.13\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/procctl.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"63a80bd1d7ee6ac4c5efee70edd0c89ce24e63935322cdaacbca36af45c65cdd"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: admin/botverification.go: FileTooLong \u2014 565 significant lines (blank, comment-only and punctuation-only lines excluded), about 71% of them inside a single declaration: Service (21 blocks, 180-858). The bar is 500 significant lines; this is 65 over it, 1.13\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ae1188c856b924111dcaa1995f7cca3618505e2f94c884ae079c927be68776b"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.finishMemoryDeleteLocked: MethodTooLong \u2014 finishMemoryDeleteLocked runs 113 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 13 over it, 1.13\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_delete.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"c318c0d17b7e32ffcdcc9c28022dccb54742125ea19b1638753e64e1844ad4ef"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: StarGiftLifecycleStore.ResolveStarGiftOffer: MethodTooLong \u2014 ResolveStarGiftOffer runs 113 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 13 over it, 1.13\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":916}}}],"partialFingerprints":{"codehealthFindingId/v1":"20b6f50805bb1bfd6b4002017b2bedefe0f1b9d31f63ca795ce6eda70be99bc9"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: StarGiftStore: ClassTooLong \u2014 451 significant lines (blank, comment-only and punctuation-only lines excluded), 35 methods, 20 blocks, lines 16-964. The bar is 400 significant lines; this is 51 over it, 1.13\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b392dd9806b1bb22aafdfd95d9ee9ee40499f5c8fd77a2517c25d38144c0ef6"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: ai/service.go: FileTooLong \u2014 563 significant lines (blank, comment-only and punctuation-only lines excluded), about 65% of them inside a single declaration: Service (18 blocks, 54-691). The bar is 500 significant lines; this is 63 over it, 1.13\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d003bac0526beef411fd81ee1cac673423114f6c950c1fc438c57b4f5540eef2"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Handler: ClassTooLong \u2014 450 significant lines (blank, comment-only and punctuation-only lines excluded), 17 methods, 16 blocks, lines 49-809. The bar is 400 significant lines; this is 50 over it, 1.13\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"02c21e7c4d29693af49f959af7133788e726da48d7cb1b2340aebef0e1a3c24a"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: rpc.tgMessageMedia: FunctionTooLong \u2014 tgMessageMedia runs 112 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 12 over it, 1.12\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_media.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"aec7510659e0b9d1116480f519def63a5fb98efe08d9cc0183ec98e04fe6d70e"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.domainStoryMediaAreasFromTL: MethodTooLong \u2014 domainStoryMediaAreasFromTL runs 112 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 12 over it, 1.12\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1671}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbc07f94d942bde1a52fc7f6268ad030f95c3dfb514b802c4587e65198f21b56"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: BotStore: ClassTooLong \u2014 445 significant lines (blank, comment-only and punctuation-only lines excluded), 43 methods, 44 blocks, lines 16-747. The bar is 400 significant lines; this is 45 over it, 1.11\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"1052064b0d29e4cc5e8614fa0819942103945179e34d57b92a12240a47eb028e"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: ContactStore: ClassTooLong \u2014 444 significant lines (blank, comment-only and punctuation-only lines excluded), 18 methods, 19 blocks, lines 18-1256. The bar is 400 significant lines; this is 44 over it, 1.11\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a1178ff7b0780f9a3e2150f59949e8d0bc18054a227f038acbbaaa618d72be4"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/photos.go: FileTooLong \u2014 551 significant lines (blank, comment-only and punctuation-only lines excluded), about 75% of them inside a single declaration: Router (20 blocks, 17-815). The bar is 500 significant lines; this is 51 over it, 1.10\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"78774fba9ab019f8288169535a93face37b5fd1af9acc174e06088ff59fbf02e"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: CommunityStore: TooManyMethods \u2014 33 methods. The bar is 30 methods; this is 3 over it, 1.10\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9634e6d1af9c5bd9ee36bb00b51986649443ce8a70deec7518335f2bd03808e"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: GroupCallStore: TooManyMethods \u2014 33 methods. The bar is 30 methods; this is 3 over it, 1.10\u00D7 the bar. Most of these members implement store.GroupCallStore (31 of 33 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c6b457c7256f2b965b4c025dd747abb0d2dbc519f44373a58347ce908da3186"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: handler: TooManyMethods \u2014 33 methods, declared across 3 files: web/server.go (27), web/serverlanding.go (4), web/assets.go (2). The bar is 30 methods; this is 3 over it, 1.10\u00D7 the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"54e37982014e76bf739f7a78c3fb0be2150a6abf3b5d2f13b0631f9dc567a01b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: bots/service.go: FileTooLong \u2014 550 significant lines (blank, comment-only and punctuation-only lines excluded), about 65% of them inside a single declaration: Service (40 blocks, 152-1025). The bar is 500 significant lines; this is 50 over it, 1.10\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"800e7a61de125af16ad12f4e9dd45e175ac857f3cb09ba1bd579b4cb989270ca"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: loadharness/mutate.go: FileTooLong \u2014 550 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 50 over it, 1.10\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7b91d42b12802166d5c5d77fb2670d5d7b3ddaf58f17edc1a9fe0d0e51d38e3"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/channel_topics.go: FileTooLong \u2014 550 significant lines (blank, comment-only and punctuation-only lines excluded), about 92% of them inside a single declaration: ChannelStore (15 blocks, 11-729). The bar is 500 significant lines; this is 50 over it, 1.10\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"14cf7b32f9f43246742bc0174d84fca9ba28014d385bb7a8ea3398ee06208d90"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Service.CanSeeForViewerUserIDs: MethodTooLong \u2014 CanSeeForViewerUserIDs runs 110 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 10 over it, 1.10\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service_sparse.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f2df5120122b7b473d91e48b8d3280df58bac53d828f039921d9a9fd3736feb"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: StarGift: TooManyFields \u2014 33 stored fields. The bar is 30 stored fields; this is 3 over it, 1.10\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef395c9b57528f2e2d16256ce90d0d9a6f6547584516b2eb1938ac04926a394f"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Config: TooManyFields \u2014 33 stored fields. The bar is 30 stored fields; this is 3 over it, 1.10\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"3da6d7c9c30c72ed036383b4539f380244cf42a43671f572677af56892ad32f7"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: moderation/evidence.go: FileTooLong \u2014 545 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 45 over it, 1.09\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d6a8413b7c4d68b6c57ecf1fb312b4e1ac0790309dbe121987dbb7f4e4fe056"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/channel_message_history.go: FileTooLong \u2014 545 significant lines (blank, comment-only and punctuation-only lines excluded), about 82% of them inside a single declaration: ChannelStore (13 blocks, 11-759). The bar is 500 significant lines; this is 45 over it, 1.09\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"19b7cd60bd5ad7bc4cf091613720645064f1e18f8abb8b0fab2f576b4222b625"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.GetChannels: MethodTooLong \u2014 GetChannels runs 109 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 9 over it, 1.09\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"83801d637ee8a99663edcab14626e2e674965036f480291c77ce6093cc36a065"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.SetChannelMessageReactions: MethodTooLong \u2014 SetChannelMessageReactions runs 109 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 9 over it, 1.09\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cedddc4a742e3930620dd45308eb6ded1123414fdefef53cbd1ffa031937a66"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.DeleteHistory: MethodTooLong \u2014 DeleteHistory runs 109 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 9 over it, 1.09\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":497}}}],"partialFingerprints":{"codehealthFindingId/v1":"642bef52010b5d7e69a76c4eace9af8e66924b91cc60a7590d227c21b945bcf5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/messages_webview.go: FileTooLong \u2014 543 significant lines (blank, comment-only and punctuation-only lines excluded), about 73% of them inside a single declaration: Router (16 blocks, 23-616). The bar is 500 significant lines; this is 43 over it, 1.09\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"97d7ade31cefb9015657616029dbfe5429c704b6ba8e0327800334600e4f6625"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/channel_helpers.go: FileTooLong \u2014 540 significant lines (blank, comment-only and punctuation-only lines excluded), about 68% of them inside a single declaration: ChannelStore (17 blocks, 13-798). The bar is 500 significant lines; this is 40 over it, 1.08\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"de92dc8c33ec5d5ee9bb3791fc5ce481ed9a96f90c24550f178fc65352e44786"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: rpc.botAPIRichBlock: FunctionTooLong \u2014 botAPIRichBlock runs 108 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 8 over it, 1.08\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c028a136fdaf1ff6cc23bb633c0ed6877d1f4b156964b4bcd4ef16c5941a82d"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.UnpinAllPrivateMessages: MethodTooLong \u2014 UnpinAllPrivateMessages runs 108 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 8 over it, 1.08\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7685478409d37ae9be0cd7b0f533efa62d94b2401352fd098560ae48494c798"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: updates/service.go: FileTooLong \u2014 535 significant lines (blank, comment-only and punctuation-only lines excluded), about 89% of them inside a single declaration: Service (46 blocks, 16-821). The bar is 500 significant lines; this is 35 over it, 1.07\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c051c26c57b8edaf1e97eb860c495aba4e6e749eb34b244dd41d1e49e751c68"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.TransferChannelOwnership: MethodTooLong \u2014 TransferChannelOwnership runs 107 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 7 over it, 1.07\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"2113831ea437e8bae09ca20166ac8a9684d03db103ea7a8d2d99143db28ac5b9"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Service: TooManyFields \u2014 32 stored fields beside 184 methods. The bar is 30 stored fields; this is 2 over it, 1.07\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"66de4a70908931fd48536055e0d8bdce50a3286051df35f88509163ef0060524"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Service: TooManyFields \u2014 32 stored fields beside 52 methods. The bar is 30 stored fields; this is 2 over it, 1.07\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"48b9a2242557621a5b6b60b9d1b4244d5d8bba59b64e1b297a5b5acd629a5cd6"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 32 methods. The bar is 30 methods; this is 2 over it, 1.07\u00D7 the bar. Most of these members implement rpc.GroupCallsService (30 of 32 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/groupcalls/service.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0a191007c55aadd124f8bff3f577fb836ac18163f1036538c81c92c1414a8f3"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: Service: TooManyMethods \u2014 32 methods. The bar is 30 methods; this is 2 over it, 1.07\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"951beb7923305bd70da519e7d6484ffcb84c59191d96ceaa690d12abebcbc5c8"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: inlineRegistry: TooManyMethods \u2014 32 methods. The bar is 30 methods; this is 2 over it, 1.07\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/inline_registry.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a353ab66bfe6e09f5e20f61cbddf6b41d00540f6b571fe3ff18eaecb7fa26bc"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: BotVerificationStore: TooManyMethods \u2014 32 methods. The bar is 30 methods; this is 2 over it, 1.07\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0c2aac08f8c19be3ed03d10ec15956dddbb68188d39abb3d7527cbe04699e21"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: DialogStore: TooManyMethods \u2014 32 methods. The bar is 30 methods; this is 2 over it, 1.07\u00D7 the bar. Most of these members implement store.DialogStore (30 of 32 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"bee39295c7ad509ba2a808271bc0bdf9e87b63793dcd9330d433c9c933dd4d34"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: GroupCallStore: TooManyMethods \u2014 32 methods. The bar is 30 methods; this is 2 over it, 1.07\u00D7 the bar. Most of these members implement store.GroupCallStore (31 of 32 members), so moving them onto a smaller type would remove them from that contract rather than reduce it. To reduce it, split the contract instead: give each cohesive group of operations its own smaller interface and its own implementing type. Where the contract has to stay whole, move the work behind these members into collaborator types, so what is left here is a forward per member rather than a responsibility per member."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"17645eb87547fe9a97d6710b17bb3932535d9eedf8b1a31f2e42384cbf25f8e2"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: ChannelMessageAction: TooManyFields \u2014 32 stored fields. The bar is 30 stored fields; this is 2 over it, 1.07\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/channel.go"},"region":{"startLine":650}}}],"partialFingerprints":{"codehealthFindingId/v1":"76792e1d5af85cb1ee86a8f5b299e3ede048c626f2668858fbab978f946b6178"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: CollectibleUsernameStore: ClassTooLong \u2014 425 significant lines (blank, comment-only and punctuation-only lines excluded), 27 methods, 28 blocks, lines 39-731. The bar is 400 significant lines; this is 25 over it, 1.06\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/collectible_username.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3a635e3036b693cb7e2bc269adde563dfcee7405b046b99b71220801ed98683"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: apiKeyboardButton.UnmarshalJSON: MethodTooLong \u2014 UnmarshalJSON runs 106 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 6 over it, 1.06\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e3f222714f4414d2015077c0d3ca1d94abb194ce9d33a27bf3c74e11083f92c"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: rpc.tgMessageServiceAction: FunctionTooLong \u2014 tgMessageServiceAction runs 106 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 6 over it, 1.06\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"70c1aed6bf0e12b9ccd2eda44dde68b01453bb9be2f027fdd505b87f2830731f"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/channels_stubs.go: FileTooLong \u2014 529 significant lines (blank, comment-only and punctuation-only lines excluded), about 65% of them inside a single declaration: Router (18 blocks, 20-710). The bar is 500 significant lines; this is 29 over it, 1.06\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9832f276afcc77534323d0286ab12c4f7c53e6f33de60aa0c0953bd18323c6be"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: rpc/convert_media.go: FileTooLong \u2014 529 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 29 over it, 1.06\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec61e276ec96b294db05a506fd020c20770af6a7757174a5e3843e5959c3708e"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: memory/telegram_login.go: FileTooLong \u2014 526 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: TelegramLoginStore (32 blocks, 20-721). The bar is 500 significant lines; this is 26 over it, 1.05\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe8340107b7d7673fa6d2e4bf53376ffb2901c8b90da91d87408fe470ec6a61b"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/business.go: FileTooLong \u2014 525 significant lines (blank, comment-only and punctuation-only lines excluded), about 73% of them inside a single declaration: PasswordStore (27 blocks, 16-732). The bar is 500 significant lines; this is 25 over it, 1.05\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"27c4e34faaa2ab0a6641494ef5257a71789ab4d3af69f2ea49c7279b4fa4f640"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Router.registerBots: MethodTooLong \u2014 registerBots runs 105 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 5 over it, 1.05\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"44bbe333458a027082918086a671c43ae6a034f1d0032033a64ef68a2b1f2d03"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.DeleteChannelHistory: MethodTooLong \u2014 DeleteChannelHistory runs 105 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 5 over it, 1.05\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f34e2813c8794908c9a2bb1395296f6cfe76194e581b1875cb896d571c5d4ab"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: ChannelStore.populateChannelMessagesReactionsWhere: MethodTooLong \u2014 populateChannelMessagesReactionsWhere runs 105 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 5 over it, 1.05\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_helpers.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"b160da4556deab116f16d460c1b3898791a26f64fc64768c55f44b2814b9dc1a"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: messages/service.go: FileTooLong \u2014 524 significant lines (blank, comment-only and punctuation-only lines excluded), about 87% of them inside a single declaration: Service (55 blocks, 13-898). The bar is 500 significant lines; this is 24 over it, 1.05\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"394fb0572313141e82a79488a098a06463d3cacbd3ec1ba0b47cbc922e0189a8"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: loadharness/snapshot.go: FileTooLong \u2014 521 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 21 over it, 1.04\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b23ad319017dd31e159524845923ca1daf493f2e02d6a71ed87738ae8842076b"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Server.walkInbound: MethodTooLong \u2014 walkInbound runs 104 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 4 over it, 1.04\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2191962b60c1fd35e7362eafa7959842f1e2d02818bb518d479ad899570aafb"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.PinPrivateMessage: MethodTooLong \u2014 PinPrivateMessage runs 104 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 4 over it, 1.04\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"57d2ec40fe2421450d04397aae80a34f3f944e009cb44194e9568786cead5007"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: domain/message.go: FileTooLong \u2014 518 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 18 over it, 1.04\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"40ca45ccfbd7c004272214515611489175feb401ecbd81428db7fb8fb962c445"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: ModerationReportStore: TooManyMethods \u2014 31 methods. The bar is 30 methods; this is 1 over it, 1.03\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"59d656226b408006599fba905a2bf13cdd73f578aa038f37d451d67faf28de35"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyMethods: TelegramLoginStore: TooManyMethods \u2014 31 methods. The bar is 30 methods; this is 1 over it, 1.03\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e48918055b7f0931b7758a7ec129128e1bcdba968a144d537f006a6c7ea952c"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: ChannelRow: TooManyFields \u2014 31 stored fields. The bar is 30 stored fields; this is 1 over it, 1.03\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"9250f25104e8aa07dc839ee30963b238d5415cfd067d8943eeaf9faad719bfb0"}},{"ruleId":"D3","level":"warning","message":{"text":"TooManyFields: Message: TooManyFields \u2014 31 stored fields. The bar is 30 stored fields; this is 1 over it, 1.03\u00D7 the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member \u2014 each reader then names only the group it uses."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c52cda2785321f047d450e0860db282ee77eb415dc4b761745fe0a17bf41d8d"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: Service.CreateAuthorization: MethodTooLong \u2014 CreateAuthorization runs 103 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 3 over it, 1.03\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"c75beb1e64297b95ff6bb672d9739901237c658a8ad69faa5e64cbace06d8f60"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: UpdateEventStore: ClassTooLong \u2014 411 significant lines (blank, comment-only and punctuation-only lines excluded), 15 methods, 13 blocks, lines 17-694. The bar is 400 significant lines; this is 11 over it, 1.03\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9f7d34c324eb196449e8a83bea9e1d94a34c6b3cbaf2d942417d2e4923961b9"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: postgres/premium.go: FileTooLong \u2014 513 significant lines (blank, comment-only and punctuation-only lines excluded), about 79% of them inside a single declaration: PremiumStore (12 blocks, 25-702). The bar is 500 significant lines; this is 13 over it, 1.03\u00D7 the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body \u2014 the parts that share the same inputs and are named together \u2014 into its own unit in a sibling file, and have the original call them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a8aa70a158a4dba31ca3ff502d64660f60e9bbf68bd07ce834af1b909ad24b5"}},{"ruleId":"D3","level":"warning","message":{"text":"FileTooLong: loadharness/seed.go: FileTooLong \u2014 512 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 12 over it, 1.02\u00D7 the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1149130ab6a676f291dce0cc6d42e6bbd49c17f55194b8eb83b444535b5c7531"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loadharness.MutateOffline: FunctionTooLong \u2014 MutateOffline runs 102 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 2 over it, 1.02\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cd0081e5dd722b86087520a48d2fe69cf7450dc899dae58d9310494a4549506"}},{"ruleId":"D3","level":"warning","message":{"text":"FunctionTooLong: loadharness.runStartupAccount: FunctionTooLong \u2014 runStartupAccount runs 102 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 2 over it, 1.02\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"d295fe1a68fce92bffbfda2defe9050600a96ac50f175ac9a7af0682d0d54ade"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.ReadHistory: MethodTooLong \u2014 ReadHistory runs 102 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 2 over it, 1.02\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc39004073fd22af906e2393290c6d0d0ef90d63de345fc0e725809429758ad7"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: MessageStore.TogglePrivateNoForwards: MethodTooLong \u2014 TogglePrivateNoForwards runs 102 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 2 over it, 1.02\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_no_forwards.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"84e56b0338a28259d90badb173f164862e15d0e798cbdcda42cd9c4ecd5f45ac"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 406 significant lines (blank, comment-only and punctuation-only lines excluded), 28 methods, 24 blocks, lines 30-680. The bar is 400 significant lines; this is 6 over it, 1.02\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc13306169f40f1d995afeef90394b384972d3be90120933f0ef93e44bb020de"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: PremiumStore: ClassTooLong \u2014 405 significant lines (blank, comment-only and punctuation-only lines excluded), 11 methods, 12 blocks, lines 25-702. The bar is 400 significant lines; this is 5 over it, 1.01\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3bc33128300ebb6fece004d572474172e44d6d716c77c93e3ca8d5fc5060600"}},{"ruleId":"D3","level":"warning","message":{"text":"MethodTooLong: UserStore.claimOfficialUsernameOnce: MethodTooLong \u2014 claimOfficialUsernameOnce runs 101 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 1 over it, 1.01\u00D7 the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body \u2014 the runs of statements that work on the same values and would earn the same name \u2014 into its own named unit, and have this one call them in order."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"5590d3e4782ee374b9eeefbbfd88df7e0a6c8024e3da37f06a7bb6484c687d8b"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: inlineRegistry: ClassTooLong \u2014 402 significant lines (blank, comment-only and punctuation-only lines excluded), 32 methods, 33 blocks, lines 13-629. The bar is 400 significant lines; this is 2 over it, 1.01\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/inline_registry.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b15818b66164b30fe1ad255afde650f241b9bea3655d17068212dd1045f9eb1"}},{"ruleId":"D3","level":"warning","message":{"text":"ClassTooLong: Service: ClassTooLong \u2014 402 significant lines (blank, comment-only and punctuation-only lines excluded), 22 methods, 23 blocks, lines 16-678. The bar is 400 significant lines; this is 2 over it, 1.01\u00D7 the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"268c2160af5cc0975a8738e2092b967e61ffe82a47bf7c75f821cf960f879c19"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member family (8 members, 18 shared lines): internal/store/postgres/channel_settings.go:573-620 | internal/store/postgres/channel_settings.go:710-757 | internal/store/postgres/channel_settings.go:759-793 | internal/store/postgres/channel_settings.go:795-842 | internal/store/postgres/channel_settings.go:844-891 | internal/store/postgres/channel_settings.go:893-927 | internal/store/postgres/channel_settings.go:929-972 | internal/store/postgres/channel_topics.go:14-78 \u2014 These 8 members are variants of one another: a block of 18 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 8 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 8 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ed8261cca3a7c589e317efa6b390535df9839685229505d776fe2c5e2e3b925"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member family (5 members, 15 shared lines): internal/adminapi/server.go:827-859 | internal/adminapi/server.go:861-893 | internal/adminapi/server.go:904-936 | internal/adminapi/server.go:956-988 | internal/adminapi/server.go:1308-1342 \u2014 These 5 members are variants of one another: a block of 15 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":827}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cefa1fc2f6b8d7596f5dd98d90e2e6ee462ed7cb27215e9e1e761d00974685d"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member family (3 members, 37 shared lines): internal/store/postgres/channel_message_delete.go:196-367 | internal/store/postgres/channel_message_delete.go:369-436 | internal/store/postgres/channel_topics.go:386-470 \u2014 These 3 members are variants of one another: a block of 37 lines reported below appears in every one of them, and the pairwise near-duplicate rows they would otherwise produce are collapsed into this row. Read them as one construct written 3 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5b4336c19a8082aa8e2cb51ae3c724dbb2a6988e56a3e137abc4980ef0a9e40"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (58 shared lines): internal/store/postgres/moderation_cases.go:112-198 | internal/store/postgres/moderation_cases.go:200-318 \u2014 These two members are variants of one another: 58 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"e66770f567ffcf94df4f51b48aa505fe04ae2e36c10e92653d18d9b3c4a13e51"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (48 shared lines): internal/store/postgres/contact.go:220-330 | internal/store/postgres/contact.go:332-423 \u2014 These two members are variants of one another: 48 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f3c32245ffd7f3b767953a7b6f6a99575b5a84a2fae71da4b3938ef1089ed5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (40 shared lines): internal/store/memory/channel_helpers.go:524-583 | internal/store/postgres/channel_helpers.go:808-910 \u2014 These two members are variants of one another: 40 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba6a09e8286690444dc0d346b1f3737fc3079b597143ec605d2f7dbe13986c92"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (37 shared lines): internal/store/postgres/message_pin.go:25-169 | internal/store/postgres/message_pin.go:174-317 \u2014 These two members are variants of one another: 37 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"98377cf6113d3bd36a7608088f485e9871f3ab23e908d8fd94f158db8ab5a5e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (35 shared lines): internal/store/memory/channel_settings.go:708-837 | internal/store/postgres/channel_settings.go:1121-1295 \u2014 These two members are variants of one another: 35 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"32596303d3d7c2053ea6e7e46a3292e5687b60eec7743c19746c678b9f58589a"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (31 shared lines): internal/app/account/lifecycle.go:193-250 | internal/app/account/phone_change.go:23-101 \u2014 These two members are variants of one another: 31 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0cb1c89f211dc4e6e709c468247335bf9ed919e8b5967ca178a698ac8bb5ae5"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (31 shared lines): internal/rpc/messages_edit_geolive.go:16-118 | internal/rpc/messages_todos.go:197-275 \u2014 These two members are variants of one another: 31 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"f76187108e6aa8887aefd4fed48fa5566b621a099a5eaf212aa44c422277b5a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (29 shared lines): internal/store/postgres/channel_invite_import.go:111-233 | internal/store/postgres/channel_member_join.go:14-143 \u2014 These two members are variants of one another: 29 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad5f85be576223c47991a6c2c76ce4920cba1a4ef050cd0ec0927eea13d5b666"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (28 shared lines): internal/store/postgres/channel_member_admin.go:10-163 | internal/store/postgres/channel_member_admin.go:305-367 \u2014 These two members are variants of one another: 28 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"5aea2e6a502ec2761fff431058a3d5f8ec9cf89428372ac01c21d2919fe2e08e"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (28 shared lines): internal/store/postgres/channel_message_edit.go:417-509 | internal/store/postgres/channel_message_edit.go:513-595 \u2014 These two members are variants of one another: 28 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":417}}}],"partialFingerprints":{"codehealthFindingId/v1":"48e1ed9d9e03bd122c7a9351382a98b0bba4bf545f2a0d5be04d48eefc5e73d1"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (25 shared lines): internal/store/postgres/channel_message_helpers.go:20-76 | internal/store/postgres/channel_message_helpers.go:78-135 \u2014 These two members are variants of one another: 25 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_helpers.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"160cea5e53a69e58014c799f9adcd264c0ef925b0b8a3866ab0a89a6a29f1c81"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (24 shared lines): internal/mtprotoedge/encrypted.go:745-870 | internal/mtprotoedge/layer_rpc_execution.go:246-326 \u2014 These two members are variants of one another: 24 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":745}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed64ff56495be80993eabdb911022340c5c64d47411b5db2191a1f32b2037f78"}},{"ruleId":"D4","level":"warning","message":{"text":"Near-duplicate member pair (19 shared lines): internal/store/postgres/telegram_login.go:866-934 | internal/store/postgres/telegram_login.go:936-1002 \u2014 These two members are variants of one another: 19 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members\u0027 grain \u2014 factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":866}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e3ea68648b048e22778927a641303a4e7db08320d17a5ee79d66b1f9e2733e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): internal/app/files/sticker_admin.go:141-181 | internal/app/files/sticker_management.go:10-47 \u2014 These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_admin.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"d619e32518f27835154af2cfec7f2c57eb6ee1a6023cb26118d17ada004bb872"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (15 members, 50\u002B identical tokens): internal/store/memory/channel_members.go:754-771 | internal/store/memory/channel_members.go:773-790 | internal/store/memory/channel_members.go:792-812 | internal/store/memory/channel_message_settings.go:9-50 | internal/store/memory/channel_reactions.go:12-29 | internal/store/memory/channel_settings.go:419-447 | internal/store/memory/channel_settings.go:449-477 | internal/store/memory/channel_settings.go:479-496 | internal/store/memory/channel_settings.go:498-526 | internal/store/memory/channel_settings.go:528-556 | internal/store/memory/channel_settings.go:558-575 | internal/store/memory/channel_settings.go:577-594 | internal/store/memory/channel_settings.go:596-617 | internal/store/memory/channel_settings.go:619-636 | internal/store/memory/channel_topics.go:11-47 \u2014 These 15 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 15 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 15 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":754}}}],"partialFingerprints":{"codehealthFindingId/v1":"942c61a7d6f8c115c241ab6bdb8524488922d820829bf606d36cb553687db170"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (13 members, 50\u002B identical tokens): internal/rpc/stats.go:194-250 | internal/rpc/stories.go:409-429 | internal/rpc/stories.go:550-572 | internal/rpc/stories.go:584-623 | internal/rpc/stories.go:1207-1273 | internal/rpc/stories.go:1366-1443 | internal/rpc/stories.go:2300-2338 | internal/rpc/stories.go:2356-2394 | internal/rpc/stories.go:2456-2487 | internal/rpc/stories.go:2538-2559 | internal/rpc/stories.go:2574-2614 | internal/rpc/stories.go:2646-2690 | internal/rpc/stories.go:2762-2818 \u2014 These 13 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 13 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 13 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"d457794fc9204b0b3e3089989469af3a13b8412613aab6e6c259ed8a9e3996f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (11 members, 50\u002B identical tokens): internal/store/postgres/message_forward.go:119-178 | internal/store/postgres/message_history.go:80-278 | internal/store/postgres/message_history.go:653-723 | internal/store/postgres/message_history.go:725-795 | internal/store/postgres/message_history.go:797-867 | internal/store/postgres/message_history.go:869-939 | internal/store/postgres/message_history.go:941-1011 | internal/store/postgres/message_send.go:1050-1069 | internal/store/postgres/saved_dialog.go:414-484 | internal/store/postgres/update_event.go:326-485 | internal/store/postgres/update_event.go:530-694 \u2014 These 11 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 11 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 11 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a07314d1a5cfcb38e3dff6b5d411784660ba69037b6fb0982a893ec065be0e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (10 members, 50\u002B identical tokens): internal/admin/service.go:1552-1592 | internal/admin/service.go:1898-1931 | internal/admin/service.go:1935-1972 | internal/admin/service.go:1975-2004 | internal/admin/service.go:2006-2037 | internal/admin/service.go:2040-2082 | internal/admin/service.go:2087-2127 | internal/admin/service.go:2133-2181 | internal/admin/service.go:2186-2224 | internal/admin/service.go:2232-2270 \u2014 These 10 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 10 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 10 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1552}}}],"partialFingerprints":{"codehealthFindingId/v1":"4eff385856ffa90c0ffd310ed8be8628e8411c3e7530eb688a162d0c8bd6a719"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (9 members, 50\u002B identical tokens): cmd/telesrv-admin/server.go:960-995 | cmd/telesrv-admin/server.go:1624-1659 | cmd/telesrv-admin/server.go:1669-1705 | cmd/telesrv-admin/server.go:2023-2058 | cmd/telesrv-admin/server.go:2069-2103 | cmd/telesrv-admin/server.go:2146-2180 | cmd/telesrv-admin/serversettings.go:230-271 | cmd/telesrv-admin/star_gift_catalog.go:81-122 | cmd/telesrv-admin/star_gift_catalog.go:364-398 \u2014 These 9 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 9 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 9 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":960}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0d4f7ae5f6d9ab6c072085d28f295f4f35a59bd7ec6823de5312b63d5770acd"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (8 members, 50\u002B identical tokens): cmd/telesrv-admin/readstore.go:430-503 | cmd/telesrv-admin/readstore.go:1038-1093 | cmd/telesrv-admin/readstore.go:1873-1910 | cmd/telesrv-admin/readstore.go:2094-2147 | cmd/telesrv-admin/readstore.go:2529-2588 | cmd/telesrv-admin/readstore.go:2653-2694 | cmd/telesrv-admin/readstore.go:3008-3083 | cmd/telesrv-admin/readstore.go:3354-3424 \u2014 These 8 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 8 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 8 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"35f64b4906caabebf207d4c41ec469098a23dc6f4dffd8cf1761fe11b657eafd"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (7 members, 50\u002B identical tokens): cmd/telesrv-admin/botverification.go:104-144 | cmd/telesrv-admin/botverification.go:146-193 | cmd/telesrv-admin/donations.go:69-95 | cmd/telesrv-admin/server.go:2671-2715 | cmd/telesrv-admin/verification.go:31-73 | internal/adminapi/botverification.go:72-117 | internal/adminapi/botverification.go:120-178 \u2014 These 7 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 7 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 7 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e712a6ecc86d9a8bb8ad09ddd86c3dab0090efcc29ab53d5b04f720ecfa19e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): cmd/telesrv-admin/account_rating.go:56-96 | cmd/telesrv-admin/botverification.go:104-144 | cmd/telesrv-admin/botverification.go:146-193 | cmd/telesrv-admin/donations.go:69-95 | cmd/telesrv-admin/server.go:2671-2715 | cmd/telesrv-admin/verification.go:31-73 \u2014 These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/account_rating.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b5dfdca3af0de197aa5984e2dc2b104b79f30a4dd4ec5884b35659921a4bcf1"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): internal/app/files/botfather_avatar_seed.go:27-54 | internal/app/files/chatbot_avatar_seed.go:26-53 | internal/app/files/gifbot_avatar_seed.go:26-53 | internal/app/files/premiumbot_avatar_seed.go:26-53 | internal/app/files/stickers_bot_avatar_seed.go:26-53 | internal/app/files/verifybot_avatar_seed.go:26-53 \u2014 These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/botfather_avatar_seed.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"19b9cc18ee8f0b21b529fd501fc50955f3408528c089c53f74b3d235fedba379"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): internal/app/usernames/service.go:327-353 | internal/app/usernames/service.go:357-378 | internal/app/usernames/service.go:381-402 | internal/store/postgres/collectible_username.go:182-289 | internal/store/postgres/collectible_username.go:294-380 | internal/store/postgres/collectible_username.go:385-461 \u2014 These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/usernames/service.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8035ffc7991f4708c278a1dcf962c7f272424029ec0adae911cd989d584a40d"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): internal/mtprotoedge/session_manager.go:1617-1633 | internal/mtprotoedge/session_manager.go:1635-1679 | internal/mtprotoedge/session_manager.go:1738-1754 | internal/mtprotoedge/session_manager.go:1761-1777 | internal/mtprotoedge/session_manager.go:1779-1795 | internal/mtprotoedge/session_manager.go:1801-1848 \u2014 These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1617}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f2affc0eb00ca4d5dcb786046a472e5034387329857e25e647b71e77f5778e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (6 members, 50\u002B identical tokens): internal/store/memory/channel_invites.go:334-382 | internal/store/memory/channel_invites.go:562-625 | internal/store/memory/channel_invites.go:627-664 | internal/store/memory/poll.go:52-94 | internal/store/memory/poll.go:148-184 | internal/store/memory/poll.go:190-239 \u2014 These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"70b273e468c7ac44779d99c03df2fa95c987c47258896b107d26c566d1a012c5"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): internal/app/dialogs/list_snapshot_cache.go:193-217 | internal/rpc/channel_interest.go:180-207 | internal/rpc/messages_dialogs.go:312-348 | internal/store/postgres/channel_dialogs.go:957-1046 | internal/store/postgres/channel_dialogs.go:2214-2241 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ea533bb4d666413ef47743f6eaefd0bcef4636f0575137464f629e1874103ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): internal/app/dialogs/service.go:301-331 | internal/app/dialogs/service.go:1458-1474 | internal/store/memory/channel_dialogs.go:10-105 | internal/store/postgres/channel_dialogs.go:293-441 | internal/store/postgres/channel_dialogs.go:446-581 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d47ab24c9e44cdf225b1ff0f5fd6f1432730e5233476a7a10d2c9be157555a1"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): internal/app/privacy/service.go:569-577 | internal/rpc/stories.go:2893-2904 | internal/rpc/story_pinned_stories_cache.go:142-153 | internal/store/memory/story.go:1460-1471 | internal/store/postgres/story.go:2587-2598 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":569}}}],"partialFingerprints":{"codehealthFindingId/v1":"08d5e78b2939ae1f7b0cdc8483b490cccdfd72c37a943f759f0f76b78212c52e"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): internal/loadharness/mutate.go:95-239 | internal/loadharness/run.go:738-994 | internal/loadharness/seed.go:61-150 | internal/loadharness/snapshot.go:105-201 | internal/loadharness/startup.go:138-420 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6ebfad0e55da242db605613a4675d8324faf89240ed58131b4c80734b291b09"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (5 members, 50\u002B identical tokens): internal/store/postgres/message_delete.go:564-576 | internal/store/postgres/message_delete.go:578-590 | internal/store/postgres/message_delete.go:592-604 | internal/store/postgres/message_delete.go:606-618 | internal/store/postgres/saved_dialog.go:253-352 \u2014 These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":564}}}],"partialFingerprints":{"codehealthFindingId/v1":"75c6e09181da44963eaf16421599176cf9fdff9c3e3240c1aa57018b4d5140f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): cmd/telesrv-admin/server.go:854-870 | cmd/telesrv-admin/server.go:1248-1264 | cmd/telesrv-admin/server.go:2348-2364 | cmd/telesrv-admin/server.go:2717-2740 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":854}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce48beb2a9fe5c112882a968b6a1787dc4cb242df4a3c97b15da1dda4073ae98"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/admin/service.go:2578-2654 | internal/admin/service.go:2659-2716 | internal/admin/service.go:2721-2772 | internal/admin/service.go:2778-2822 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2578}}}],"partialFingerprints":{"codehealthFindingId/v1":"f72e8449f82d13433e9deea0e3093e80929060da2a1d4ddbf3c8bdb31797ff3f"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/adminapi/botverification.go:344-363 | internal/adminapi/botverification.go:365-380 | internal/adminapi/botverification.go:382-399 | internal/adminapi/botverification.go:401-435 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"794a3718a572a3e94d75e10ff17e9f372dbf36f8900bfe16f4b1d6c779e904d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/app/channels/service.go:2524-2546 | internal/app/users/service.go:977-999 | internal/config/config.go:1952-1974 | internal/domain/collectible_username.go:299-321 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2524}}}],"partialFingerprints":{"codehealthFindingId/v1":"73c678678bc52f3c2cfbf595ec4f0dbe53b09adb6fda437633b8a241fadba88c"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/app/dialogs/shared_list_snapshot.go:150-179 | internal/rpc/story_projection_cache.go:204-232 | internal/store/memory/community.go:590-652 | internal/store/memory/story.go:577-596 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/shared_list_snapshot.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7b5a0928e7c5f70deadee48e3aa407f4ebfc255e41193ce70398a2321c75139"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/app/stories/service.go:487-498 | internal/rpc/stories.go:3129-3143 | internal/store/memory/story.go:1094-1105 | internal/store/postgres/story.go:2303-2314 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":487}}}],"partialFingerprints":{"codehealthFindingId/v1":"27fe9ac0e3c356b20ab39a3e0c504b7f46f32ee618e469b2030bedb93f1c4554"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/botapi/ephemeral.go:92-133 | internal/botapi/ephemeral.go:135-194 | internal/botapi/server.go:517-583 | internal/botapi/server.go:650-738 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4e17ba597246e359dba166db461416b965aa0c97459efed9021e5f249e619a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/botapi/server.go:517-583 | internal/botapi/server.go:585-648 | internal/botapi/server.go:650-738 | internal/botapi/server.go:740-835 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac120342fc33bfdbaba4c87681b7376bb4a9e38a9b35abc28baebdebcad68202"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/domain/message_entity_autodetect.go:71-95 | internal/domain/message_entity_autodetect.go:97-130 | internal/domain/message_entity_autodetect.go:132-165 | internal/domain/message_entity_autodetect.go:167-194 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cbf4f1eba3e45817418be0ed82346e96d099fa8718eb40c2c2fe7e55bafe545"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/bot_verification_projection.go:109-143 | internal/rpc/fragment.go:309-331 | internal/rpc/messages_monoforum.go:201-220 | internal/rpc/story_peer_projection.go:585-638 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"45b8fdfaf714ae0134943def12ce03de51916c0d648685612f1a5217543c3ee2"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/botapi_gateway.go:178-230 | internal/rpc/botapi_gateway.go:236-290 | internal/rpc/botapi_gateway.go:294-348 | internal/rpc/botapi_gateway.go:875-935 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5a4e8853f1bb12b6e13fac9c05a53c086f90a14498b48c2262a4cc4e951cd88"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/bots_callback.go:30-135 | internal/rpc/messages_edit.go:11-184 | internal/rpc/messages_edit_geolive.go:16-118 | internal/rpc/messages_history.go:545-587 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a7c1587fa2d566773d91ba0118c552496fbf15752a58cf09dcc191bb3dfd8d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/channels_invites.go:374-391 | internal/rpc/contacts.go:179-202 | internal/store/memory/channel_core.go:281-295 | internal/store/postgres/channel_core.go:628-642 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":374}}}],"partialFingerprints":{"codehealthFindingId/v1":"43b0407144075aac1f55c6521bd110fd519920df0f9c3e0197cc50a35ecd1b78"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/channels_legacy_chat.go:284-322 | internal/rpc/messages_suggested_post.go:30-69 | internal/rpc/phone_group_call.go:183-262 | internal/rpc/phone_group_call_rtmp.go:111-146 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"e81e5b44517edaa671ae23d0e5a01822a98bd70eedd2393b32b2b08cbd96f406"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/chatlists.go:54-80 | internal/rpc/chatlists.go:205-225 | internal/rpc/chatlists.go:247-267 | internal/rpc/chatlists.go:298-318 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/chatlists.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"de65c7601b8bc6ca8dcd0acf83fadacd0173391fe414169d8d574944273bed53"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/communities.go:235-278 | internal/rpc/communities.go:349-377 | internal/rpc/communities.go:379-411 | internal/rpc/communities.go:413-457 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a0476c6563e168cf056f7a5c9e6bc59d15af59462452172464f0faac77e6143"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/convert_channels_core.go:11-39 | internal/rpc/convert_channels_core.go:393-407 | internal/rpc/convert_dialogs.go:351-385 | internal/rpc/premium_sweeper.go:204-243 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b8ca1474173057143f0450db9bf811ba5d1e63ac7596785038515c71672877e"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/messages_dialogs.go:728-765 | internal/rpc/messages_dialogs.go:843-900 | internal/rpc/messages_dialogs.go:934-977 | internal/rpc/messages_saved_dialogs.go:151-198 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":728}}}],"partialFingerprints":{"codehealthFindingId/v1":"0191163727afc4588261f17bc7716390a61647caf6c83988bae4bf8eb807b2fc"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/messages_forward.go:13-347 | internal/rpc/messages_quick_replies.go:156-229 | internal/store/memory/message_forward.go:9-98 | internal/store/postgres/message_forward.go:19-117 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"dac48ac9be3a4549ca59de62abe6abeb7803f9f1755fd5ef9f98b85e7675f8d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/rpc/payments_star_gift_collections.go:13-41 | internal/rpc/payments_star_gift_collections.go:43-69 | internal/rpc/payments_star_gift_collections.go:71-116 | internal/rpc/payments_star_gifts.go:1091-1149 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_collections.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"def97ede131379810c7f3cee4c8c1eeda8b6aa2cf135bbbbe70170ca286ae9a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/memory/bot_verification.go:1077-1088 | internal/store/memory/verification.go:984-995 | internal/store/postgres/bot_verification.go:1405-1416 | internal/store/postgres/verification.go:1318-1329 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":1077}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e801db654f2461ba8e3497494fe7076fb2cb5788243e2678a5407ce9d02ae9"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/memory/channel_boosts.go:232-242 | internal/store/memory/channel_reactions.go:334-389 | internal/store/memory/channel_reactions.go:769-839 | internal/store/postgres/message_reactions.go:351-425 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"3742d6b6c6820b40369a4c097ad492a4a9952f37b702c8e535371ac2822caab0"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/memory/channel_members.go:648-671 | internal/store/memory/channel_members.go:673-696 | internal/store/memory/channel_members.go:698-724 | internal/store/memory/channel_members.go:726-752 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":648}}}],"partialFingerprints":{"codehealthFindingId/v1":"47f73080a7adec8e70b9136413aa52444f5b768d45aa5ad100211d4e6a3381d2"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/postgres/account.go:349-373 | internal/store/postgres/account.go:422-474 | internal/store/postgres/account.go:476-518 | internal/store/postgres/account.go:520-570 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2084ff486842a02da4ed5d2bd1b0fb03a52eb98790c6795d91b56092c2c697c"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/postgres/community.go:1084-1104 | internal/store/postgres/community.go:1106-1126 | internal/store/postgres/community.go:1177-1198 | internal/store/postgres/community.go:1200-1226 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1084}}}],"partialFingerprints":{"codehealthFindingId/v1":"790d4c50435a09ad911199c54255cba7ded735e69e3ae16b95ce3195575d87cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/postgres/media_refs.go:223-252 | internal/store/postgres/media_refs.go:348-388 | internal/store/postgres/media_refs.go:393-418 | internal/store/postgres/media_refs.go:451-479 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_refs.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"37cd13cc29b44f9ebd95a3f2078795f67570074c49fa05a4d04ea87013a2e535"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/postgres/moderation.go:22-47 | internal/store/postgres/moderation.go:110-190 | internal/store/postgres/moderation_registries.go:81-144 | internal/store/postgres/moderation_registries.go:206-266 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a1f23b1f56b7c5eb3a3185e2d667746077f9689df79623a7218a231ba928de4"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/postgres/story.go:358-399 | internal/store/postgres/story.go:598-630 | internal/store/postgres/story.go:632-690 | internal/store/postgres/story.go:713-758 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cba5830705bbf48c3dd83c4c16bd44ed0e6ca29eb6ed35e7433b70405527840"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/postgres/story.go:789-839 | internal/store/postgres/story.go:841-892 | internal/store/postgres/story.go:894-956 | internal/store/postgres/story.go:958-1006 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":789}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbc1b6a2de5314406e3569fcafb2b73493edf340a554c83cb3b4ebe7bc60a278"}},{"ruleId":"D4","level":"warning","message":{"text":"Members sharing a duplicated core (4 members, 50\u002B identical tokens): internal/store/storetest/groupcall.go:60-92 | internal/store/storetest/groupcall.go:384-430 | internal/store/storetest/groupcall.go:432-479 | internal/store/storetest/groupcall.go:481-535 \u2014 These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below \u2014 it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members\u0027 grain \u2014 factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/storetest/groupcall.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d47fae6212c50f7e91a3e3314bbeabe4635ec1ee3b08113d140fd8ed24520ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (155 corresponding lines): internal/store/postgres/dialog.go:41-259 | internal/store/postgres/dialog.go:450-604 \u2014 These two members are one piece of code written twice and then edited apart: 155 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f2472f62828868477f9a0a024a9fea2edac07cdc7ba486b83f651f8b4eb98c2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (89 corresponding lines): internal/store/postgres/channel_helpers.go:232-320 | internal/store/postgres/channel_message_history.go:351-480 \u2014 These two members are one piece of code written twice and then edited apart: 89 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"1993a2a7c8ef04af83d40fff4ec612f4be131176d500c8bbc26c8919d712b8bf"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (99 corresponding lines): internal/store/memory/channel_topics.go:179-277 | internal/store/postgres/channel_topics.go:194-293 \u2014 These two members are one piece of code written twice and then edited apart: 99 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae9115805b789b72e62c5b439f1f36086e1c317a1a9b61131b62052586d81da7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (65 corresponding lines): internal/store/memory/moderation.go:437-501 | internal/store/memory/moderation.go:503-585 \u2014 These two members are one piece of code written twice and then edited apart: 65 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":437}}}],"partialFingerprints":{"codehealthFindingId/v1":"48b11ea570da0d2f9dbe708f0587cd0afc7efaa220bbdf7efd47bc8a42bc6c9e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (59 corresponding lines): cmd/telesrv-admin/star_gift_catalog.go:185-253 | internal/adminapi/server.go:1240-1298 \u2014 These two members are one piece of code written twice and then edited apart: 59 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/star_gift_catalog.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"c410b8c30e1d72de6a96c6adb8a94905c8527e6877a915629374c4290da91c97"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (84 corresponding lines): internal/rpc/stories.go:2089-2176 | internal/rpc/stories.go:2178-2261 \u2014 These two members are one piece of code written twice and then edited apart: 84 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2089}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cb3992fe10e09a6cbb946281efa2a4017094cf3af4f78fec76c2db003af2779"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (68 corresponding lines): internal/store/postgres/channel_settings.go:15-82 | internal/store/postgres/channel_settings.go:84-162 \u2014 These two members are one piece of code written twice and then edited apart: 68 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"8981174ee71b5239d822b4592f568470a14cd86ffd22b2092fe696fde1823143"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (36 corresponding lines): internal/store/memory/telegram_login.go:530-565 | internal/store/memory/telegram_login.go:567-603 \u2014 These two members are one piece of code written twice and then edited apart: 36 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f5b432fcd52e5605cbe3f1b0528ab3e881cae57b2fa27771ba3a6129ccfb93a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (64 corresponding lines): internal/app/files/retention.go:111-174 | internal/app/files/retention.go:192-267 \u2014 These two members are one piece of code written twice and then edited apart: 64 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"e65e290f016f184f67083d911292f91e53a6b75ecfb08ccdaca2a93c8806a8f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (52 corresponding lines): internal/store/memory/contacts.go:94-155 | internal/store/memory/contacts.go:157-208 \u2014 These two members are one piece of code written twice and then edited apart: 52 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"89c16762b833b1a0c69d7e59ce047c80ae569d45d3cbe6d1b4a429d9f1ca6237"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (63 corresponding lines): internal/store/postgres/auth_delivery_report.go:23-90 | internal/store/postgres/client_telemetry.go:24-86 \u2014 These two members are one piece of code written twice and then edited apart: 63 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_delivery_report.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ae7e9a64673a9386e0425081d392d238c7cbd55b1835b637d4c5f2fede89a45"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (76 corresponding lines): internal/rpc/messages_bot_no_state.go:113-188 | internal/rpc/messages_bot_no_state.go:190-282 \u2014 These two members are one piece of code written twice and then edited apart: 76 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"557b0945e7af79f4d77850f282f152bc9880ca0c241fd5ad2b04b12252d73ad5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/store/memory/message_reactions.go:236-267 | internal/store/postgres/message_reactions.go:427-458 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcb104a6ae191cf65c0978f29b923da5a90173e7bd91dd1f265893c6a8180fdc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (50 corresponding lines): internal/store/postgres/channel_message_delete.go:13-62 | internal/store/postgres/channel_message_delete.go:64-124 \u2014 These two members are one piece of code written twice and then edited apart: 50 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d66bd8c1b0c8bac768cddf7a961ac414f932f317d3c1bc15d65b7c01cf34223"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (51 corresponding lines): internal/rpc/channels_settings.go:366-422 | internal/rpc/channels_settings.go:424-474 \u2014 These two members are one piece of code written twice and then edited apart: 51 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"2338d0cafdfc8e52e4f87cb0517409139059364cb4fa3da1000e3d4f1b20b346"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (52 corresponding lines): internal/rpc/account_deletion_notifications_worker.go:74-137 | internal/rpc/account_freeze_worker.go:59-110 \u2014 These two members are one piece of code written twice and then edited apart: 52 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion_notifications_worker.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"86b8c4bf204a06f5da5a918ba5cd1c718e51284dbab7ee4ab2265031fe32f72e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (69 corresponding lines): internal/app/auth/service.go:599-667 | internal/app/auth/service.go:723-792 \u2014 These two members are one piece of code written twice and then edited apart: 69 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":599}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7a1a23c3873a1269d609281d8f6c6065576d90e43ce2c7f3b11c585b3d61904"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (44 corresponding lines): cmd/telesrv-admin/server.go:2919-2962 | cmd/telesrv-admin/star_gift_catalog.go:258-312 \u2014 These two members are one piece of code written twice and then edited apart: 44 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2919}}}],"partialFingerprints":{"codehealthFindingId/v1":"0653b4427d58f38e8f2c27910e24a1f417d5a72d31cf5beb04fed5924bdcd96d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (61 corresponding lines): internal/rpc/messages_webview.go:23-83 | internal/rpc/messages_webview.go:138-202 \u2014 These two members are one piece of code written twice and then edited apart: 61 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6048bbfbb111c1ec5469f522e48b1d7fe2d933e30f41a95cf8043030900f061"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (41 corresponding lines): internal/store/memory/botapi_update.go:418-466 | internal/store/postgres/botapi_update.go:684-724 \u2014 These two members are one piece of code written twice and then edited apart: 41 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8959bde2d18ce9b6aeae58afe6a354dcbd5e7c92f4fd683b4658d0c09f5e709"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (37 corresponding lines): internal/store/memory/dialogs.go:978-1014 | internal/store/postgres/dialog.go:1245-1281 \u2014 These two members are one piece of code written twice and then edited apart: 37 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":978}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5d400056ce9dfa7e6cf05a01ff250d9cbfe1e0d2bc0fdc1fdb9bf33bd658b99"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (48 corresponding lines): internal/store/memory/channel_reactions.go:545-592 | internal/store/memory/channel_read.go:148-196 \u2014 These two members are one piece of code written twice and then edited apart: 48 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8c69f2c6c1081677317a09c446cec0e4d803258cb7ba448e967796f20d37317"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (46 corresponding lines): cmd/telesrv-admin/adminusers_api.go:191-242 | cmd/telesrv-admin/adminusers_api.go:245-290 \u2014 These two members are one piece of code written twice and then edited apart: 46 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/adminusers_api.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d6a42eb94a26359d207a3fcc0c3f7cab3469e48d1ad154bce92de445e56f875"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (43 corresponding lines): internal/admin/service.go:3492-3540 | internal/admin/service.go:3542-3584 \u2014 These two members are one piece of code written twice and then edited apart: 43 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3492}}}],"partialFingerprints":{"codehealthFindingId/v1":"668d4e1aeca00cb5e44d6a8ffacd79774a8bd6ac824513070cc850b2cef752d9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (53 corresponding lines): internal/store/postgres/story.go:1636-1688 | internal/store/postgres/story.go:1690-1743 \u2014 These two members are one piece of code written twice and then edited apart: 53 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1636}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca2f6775b16dd92b328d5878d0f3184ecfd56a63cce7738542554bcfc9cf2860"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (50 corresponding lines): internal/store/postgres/channel_invite_import.go:60-109 | internal/store/postgres/channel_member_join_requests.go:123-180 \u2014 These two members are one piece of code written twice and then edited apart: 50 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"524f2204873da81919f3379871ae1c1c6098e1f19613505b1e638405685626cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (68 corresponding lines): cmd/telesrv-admin/readstore.go:626-693 | cmd/telesrv-admin/readstore.go:2872-2978 \u2014 These two members are one piece of code written twice and then edited apart: 68 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":626}}}],"partialFingerprints":{"codehealthFindingId/v1":"331d09cb2dd872cc5dd11fcb8384df6b58d5722da4afbcd569e116f4d3ec3b11"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (72 corresponding lines): internal/store/postgres/authkey_session_layer_batch.go:282-406 | internal/store/postgres/bootstrap_update_job_batch.go:306-377 \u2014 These two members are one piece of code written twice and then edited apart: 72 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_session_layer_batch.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"3641400e633881aa39a05723c4a619d43a1ba5e93f3df7efd02ac2f07c0fbc4e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (37 corresponding lines): internal/app/files/external_media.go:135-171 | internal/app/files/webpage.go:161-201 \u2014 These two members are one piece of code written twice and then edited apart: 37 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c58f8943c5ecaec62c0279e2b4b177b9249cc37ae6f87eadd90456c4d19c43b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 51\u002B corresponding lines): cmd/telesrv-admin/server.go:718-768 | cmd/telesrv-admin/server.go:1010-1069 | cmd/telesrv-admin/server.go:1192-1246 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 51 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":718}}}],"partialFingerprints":{"codehealthFindingId/v1":"54e6c08dbcf1711237f4dd21d5fa36e75dedb5db99a7d3e797dd8b59ebbc80ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (40 corresponding lines): internal/rpc/update_peer_refs.go:332-371 | internal/rpc/update_peer_refs.go:416-468 \u2014 These two members are one piece of code written twice and then edited apart: 40 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a14cd2f1c8b90c19be746894bb2d30d3d54e62c72f84fed7296de6f69ef07a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (46 corresponding lines): internal/store/postgres/channel_settings.go:214-270 | internal/store/postgres/channel_settings.go:405-450 \u2014 These two members are one piece of code written twice and then edited apart: 46 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"80c82760b09e301fae03c7dd614c04c845538c927d51fd968dd169337c0eb611"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): internal/rpc/payments_star_gift_lifecycle.go:27-60 | internal/rpc/payments_star_gift_lifecycle.go:98-134 \u2014 These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"4344b12c8747320e3aada9a97452d6963935c1ac435add8a2f6aa1b9a44c92ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (47 corresponding lines): internal/store/postgres/user.go:259-305 | internal/store/postgres/user.go:658-717 \u2014 These two members are one piece of code written twice and then edited apart: 47 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b63b98a772476fcf391983dfa10ba753697a9866254c8727f0581040add97b8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (44 corresponding lines): internal/store/memory/channel_topics.go:318-364 | internal/store/postgres/channel_topics.go:341-384 \u2014 These two members are one piece of code written twice and then edited apart: 44 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b9005c9017a9d1149476af72d9cc0906cd2a3909377f7948d9f720614a9c5c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (45 corresponding lines): internal/app/stargifts/service.go:206-254 | internal/app/stargifts/service.go:382-426 \u2014 These two members are one piece of code written twice and then edited apart: 45 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":206}}}],"partialFingerprints":{"codehealthFindingId/v1":"1435ef26bcf12b2c73f082ae743288002dd3c63702a524058dd33f8aad21c39a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (47 corresponding lines): internal/store/memory/collectible_username.go:369-426 | internal/store/memory/collectible_username.go:434-480 \u2014 These two members are one piece of code written twice and then edited apart: 47 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/collectible_username.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1fe044eaac38fc18e04e59ead52538d969e14669932d0119152c9b4be6f5e22"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 37\u002B corresponding lines): internal/store/postgres/star_gift_lifecycle.go:1713-1754 | internal/store/postgres/star_gift_lifecycle.go:1778-1814 | internal/store/postgres/star_gift_lifecycle.go:1835-1871 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 37 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1713}}}],"partialFingerprints":{"codehealthFindingId/v1":"325596ac79b1d53b9efa998f791ee75a421e401e40b1c999ec13b5348632806f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (47 corresponding lines): internal/app/userprojection/contact_cache.go:423-470 | internal/app/userprojection/contact_cache_sparse.go:113-159 \u2014 These two members are one piece of code written twice and then edited apart: 47 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca2672b935185c3a2f346887e6493bacac43aeede40606039671e15e5d4da36a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 33\u002B corresponding lines): cmd/telesrv-load/main.go:126-158 | cmd/telesrv-load/main.go:160-196 | cmd/telesrv-load/main.go:198-233 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 33 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-load/main.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fbb353c04058dc98f86fe0fcd4ce38c64231bd9ebd9a00f616e563a7da0f1cd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (45 corresponding lines): internal/admin/botverification.go:355-405 | internal/admin/botverification.go:412-456 \u2014 These two members are one piece of code written twice and then edited apart: 45 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"5225e12ce03e44b9ef61dbbe47e4c646aecaca989bd3352de8cb5e05d9f80631"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/store/postgres/channel_message_send.go:505-544 | internal/store/postgres/channel_suggested_post.go:237-262 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":505}}}],"partialFingerprints":{"codehealthFindingId/v1":"b83bf39df762e615721a71962d939a22dcff37e953501cc1a3b343b1a4c1460a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (46 corresponding lines): internal/store/postgres/channel_reaction_unread.go:38-83 | internal/store/postgres/channel_read.go:302-347 \u2014 These two members are one piece of code written twice and then edited apart: 46 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"666d32e845cb267e6647c96e564506936e48748187e95d7345ef679f311a68e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): internal/store/memory/channel_topic_read.go:106-138 | internal/store/postgres/channel_topic_read.go:107-151 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topic_read.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"0887e586180733707a319bbd9e17e57f30081f2f8ef871c3621a89a111b3445f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 39\u002B corresponding lines): internal/admin/service.go:2277-2318 | internal/admin/service.go:2895-2933 | internal/admin/service.go:2937-2976 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 39 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2277}}}],"partialFingerprints":{"codehealthFindingId/v1":"eeed4b3a08f8e134d32690d0b6c07ae77e1986f04ecdad1b3354c2fbe85d6cc7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (58 corresponding lines): internal/store/contact_reverse_batch.go:185-242 | internal/store/read_model_batch.go:187-244 \u2014 These two members are one piece of code written twice and then edited apart: 58 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"83cad1dea87bd6e49689e62605910d30e12c2da49e5aa41beac66a5ed41c85f9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (41 corresponding lines): internal/rpc/messages_history.go:308-350 | internal/rpc/messages_read.go:95-135 \u2014 These two members are one piece of code written twice and then edited apart: 41 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3761109b64e4112233f2c3ac15f663435b49aa496de4ebfdea8c051c057181b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): internal/store/memory/channel_reactions.go:462-498 | internal/store/memory/channel_reactions.go:500-533 \u2014 These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":462}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4d24162c3c353c0b205dc358fe3490b549b677d2b543bd91f986518f0bf3bf6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (42 corresponding lines): internal/rpc/payments_star_gift_unique.go:28-69 | internal/rpc/payments_star_gift_unique.go:71-113 \u2014 These two members are one piece of code written twice and then edited apart: 42 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_unique.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd52b237a623eb0fedcea06d6bfeca3b31b0b7b110d8c9cc1f5fdd1bff3e5c2e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): internal/rpc/contacts.go:277-309 | internal/rpc/contacts.go:311-343 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"771b07ff0a26ca3f2edea2cf237e25c0765ec3c8b33579fc59e1db6340ee2777"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (52 corresponding lines): internal/store/postgres/channel_history_ttl.go:33-84 | internal/store/postgres/history_ttl.go:84-143 \u2014 These two members are one piece of code written twice and then edited apart: 52 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_history_ttl.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bbe35af5619a8b661b22a2f4c2aa2e300e29ab94fa38f0b54bd10f66ee75853"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (39 corresponding lines): internal/rpc/messages_reactions_lists.go:11-49 | internal/rpc/messages_reactions_lists.go:51-97 \u2014 These two members are one piece of code written twice and then edited apart: 39 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_lists.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"9cb2764193d11b36335c5b770dd634a6fa578ce7a9b002705ef02dd953899085"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (35 corresponding lines): internal/rpc/messages_send.go:1113-1151 | internal/rpc/messages_send.go:1153-1187 \u2014 These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1113}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c76c7bad5358101e022b2a7152e9e263a661de5135bf129d9e508d96e7f0d12"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/rpc/messages_getmessages_trace.go:145-169 | internal/rpc/messages_getmessages_trace.go:171-204 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_getmessages_trace.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"e719fd3039dcf53b5514f1c7b4d901e4ca071ad5319a50f443103c2a3fe33b6c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 58\u002B corresponding lines): internal/store/postgres/verification.go:211-274 | internal/store/postgres/verification.go:283-340 | internal/store/postgres/verification.go:345-403 | internal/store/postgres/verification.go:408-465 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 58 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a05e796bedfcbf56d6b23221407014461eb6815f6a14b83391252ea7bd45a4e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): cmd/walletminiapp/main.go:201-229 | cmd/walletminiapp/main.go:231-263 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"467f4a1be5da681ef8b4175e34ec80393a82a8e839ce6d222fe2f25d5e86cf40"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/admin/verification.go:137-162 | internal/admin/verification.go:171-208 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/verification.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"c34405231a075481ccfd3e74297405701ee5f1a0ac371dffd53808c8e451a371"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 35\u002B corresponding lines): internal/admin/botverification.go:598-637 | internal/admin/botverification.go:642-677 | internal/admin/botverification.go:681-721 | internal/admin/verification.go:213-247 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 35 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":598}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9b8f5e7c3e086e51466c11570e4181fe2fc14695e46eb739a3a349b72c5b924"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): cmd/telesrv-admin/server.go:2853-2881 | cmd/telesrv-admin/server.go:2889-2917 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2853}}}],"partialFingerprints":{"codehealthFindingId/v1":"67466b835dcf59bcce5bf251223e9256c353974c6dc959603da0c34e35d68c0e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (35 corresponding lines): cmd/telesrv-admin/privateview_store.go:250-284 | cmd/telesrv-admin/privateview_store.go:288-338 \u2014 These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"79719866e036b625075a75296c90af1aed609e351bffab09817f3d8a55d8d311"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (45 corresponding lines): internal/rpc/messages_bot_no_state.go:315-359 | internal/rpc/messages_send.go:770-822 \u2014 These two members are one piece of code written twice and then edited apart: 45 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2292d754c6b0ada3761c57d3a7ff4cb4a9feee069b793486ccf013599950a67"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (40 corresponding lines): internal/store/contact_reverse_batch.go:244-284 | internal/store/read_model_batch.go:246-285 \u2014 These two members are one piece of code written twice and then edited apart: 40 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"af241622ba402902b3bfe51d2bb218def2a8db4176f45c9d4076bf8a0655c811"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 39\u002B corresponding lines): internal/store/postgres/channel_reaction_unread.go:114-152 | internal/store/postgres/channel_read.go:591-629 | internal/store/postgres/channel_topics.go:868-906 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 39 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"03c343fbdcadd511f1220549c27374611765b677fab558d7ab5ff06b22d82a19"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (39 corresponding lines): internal/app/bots/verifierbot.go:404-442 | internal/app/bots/verifybot.go:371-410 \u2014 These two members are one piece of code written twice and then edited apart: 39 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":404}}}],"partialFingerprints":{"codehealthFindingId/v1":"300bbb2f4c351bb9120cead8ed6d6f0bba0b57adada93081bec16cc311abdc1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/rpc/channels_members.go:643-674 | internal/rpc/channels_members.go:676-712 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":643}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb5debea4ada45926d6924e01adea27b253b2c41922560d65cd59353aa38121b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (38 corresponding lines): internal/loadharness/run.go:458-495 | internal/loadharness/run.go:497-536 \u2014 These two members are one piece of code written twice and then edited apart: 38 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"b72f3b15a1a47fd01cc164b3c3aa7e8f0e3585504763216b7f169656c5bd7b07"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (35 corresponding lines): internal/store/postgres/channel_settings.go:164-198 | internal/store/postgres/channel_settings.go:974-1012 \u2014 These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d250c72f82f73a6eb58d15a1645708bcec2d72ee42a3a296dec68c4dbd7b580"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (37 corresponding lines): internal/store/postgres/moderation_registries.go:14-55 | internal/store/postgres/moderation_registries.go:146-182 \u2014 These two members are one piece of code written twice and then edited apart: 37 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee5ea8a96d5c4b840db64c972425aa978daa76415d64c1e3e22b7bb965c7e359"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (39 corresponding lines): internal/store/postgres/collectible_username.go:609-651 | internal/store/postgres/verification.go:831-869 \u2014 These two members are one piece of code written twice and then edited apart: 39 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":609}}}],"partialFingerprints":{"codehealthFindingId/v1":"40be2c428919af662747a604aa369525e1138be90757f77bd4604ff180f3ae60"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (48 corresponding lines): internal/store/postgres/channel_dialogs.go:1149-1216 | internal/store/postgres/channel_dialogs.go:1218-1265 \u2014 These two members are one piece of code written twice and then edited apart: 48 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1149}}}],"partialFingerprints":{"codehealthFindingId/v1":"23c1c5b169644d23a5b412df16845d97603486e7399337829703ccffe1fad47c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 59\u002B corresponding lines): internal/store/postgres/contact.go:920-978 | internal/store/postgres/contact.go:980-1039 | internal/store/postgres/contact.go:1082-1144 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 59 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":920}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5a4355fd2bcf84981f4bc0fc7470983ad63794c3f475725d7937f13ced34fb0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): internal/store/postgres/premium.go:485-513 | internal/store/postgres/premium.go:515-548 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f0aa0b5fc6984a2a480a75babe199618b00c81c425336e57f5af562a1624d7b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/store/postgres/channel_reaction_unread.go:11-36 | internal/store/postgres/channel_read.go:275-300 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"648338eea71ce0efe7db73798cfd3d58c69aad6f688d80a6813e277f9188e92b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (45 corresponding lines): internal/store/postgres/channel_dialogs.go:1551-1619 | internal/store/postgres/story.go:1508-1552 \u2014 These two members are one piece of code written twice and then edited apart: 45 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1551}}}],"partialFingerprints":{"codehealthFindingId/v1":"215cb34564f1f171f6da9b10fed63a8b1d0c41205a3c9124c00085597908cfac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): internal/mtprotoedge/rpc_rewrap.go:77-110 | internal/mtprotoedge/rpc_rewrap.go:131-163 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_rewrap.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd72c5da8ff8b360f2179be31d53f097c3757d44ff0917faad411bc2b608c7e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 31\u002B corresponding lines): internal/rpc/messages_edit_geolive.go:128-158 | internal/rpc/messages_polls_updates.go:41-71 | internal/rpc/messages_todos.go:284-314 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 31 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5fd55af472cc9c50a409252d67f36d4795c319c7f160bb530f914ada32c5fd6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): internal/rpc/phone_group_call.go:479-512 | internal/rpc/phone_group_call.go:514-547 \u2014 These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":479}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3da4b45a874fbcf8960f4f70e8989524eee789b45929653a51df404fba1a1e2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): internal/rpc/channels_legacy_chat.go:419-454 | internal/rpc/channels_members.go:44-77 \u2014 These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef0fcf46a8785c26c976ba3671203879f2a74a0690490fdec54ff357de94c15d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (36 corresponding lines): internal/adminapi/server.go:1748-1783 | internal/adminapi/verification.go:21-66 \u2014 These two members are one piece of code written twice and then edited apart: 36 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1748}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ca13fdb3e669f10ae7b88712183b72aa25f89c061e4a927c6cf776422ed5f50"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): internal/app/bots/verifierbot.go:1219-1251 | internal/app/bots/verifybot.go:987-1019 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1219}}}],"partialFingerprints":{"codehealthFindingId/v1":"23a352c3bfb5874535dbb577dd34822e54ead89f77d2e90018a2c8df97b22f16"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (43 corresponding lines): internal/store/postgres/bot_verification.go:737-779 | internal/store/postgres/bot_verification.go:992-1044 \u2014 These two members are one piece of code written twice and then edited apart: 43 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8d5ae1301a04264468ecfacb93b4e6c25cba6f6d088a9494f72397befedcac5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (37 corresponding lines): internal/store/postgres/welcome_message.go:221-260 | internal/store/postgres/welcome_message.go:262-298 \u2014 These two members are one piece of code written twice and then edited apart: 37 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8c9e6d6b979360590b2eb2600d89e739ee708bbd6a93d0f5c3f702338a75417"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (45 corresponding lines): internal/app/bots/verifierbot.go:322-366 | internal/app/bots/verifybot.go:261-313 \u2014 These two members are one piece of code written twice and then edited apart: 45 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"501195cbce35d09e74df625c05ad5d6fd3026e36d2bacb6932ba0a76349a488a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (36 corresponding lines): internal/store/memory/bot_verification.go:499-534 | internal/store/memory/bot_verification.go:705-746 \u2014 These two members are one piece of code written twice and then edited apart: 36 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9684cceee971a1cf4d799fa04bf0a839247c845371f47d56fd706936c421d15"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (47 corresponding lines): internal/store/postgres/message_read.go:422-476 | internal/store/postgres/scheduled_message.go:224-270 \u2014 These two members are one piece of code written twice and then edited apart: 47 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_read.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa8405eb6812afa5b27c792ad384ea6950056a8b1417ccea6aae8ab599b38b25"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 27\u002B corresponding lines): cmd/telesrv-admin/server.go:538-570 | cmd/telesrv-admin/server.go:586-612 | cmd/telesrv-admin/server.go:2368-2408 | cmd/telesrv-admin/server.go:2413-2449 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 27 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":538}}}],"partialFingerprints":{"codehealthFindingId/v1":"4259e740330d735a7df08a5413e33204f14084e6cc8c6ec8507f635d241d631e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/store/postgres/media_search.go:224-255 | internal/store/postgres/media_search.go:286-321 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_search.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"e161af5acd5005ddb58094d377ad8ca3d0936c5fd3ac1f7f9657985e91dbba81"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): internal/app/moderation/registry_reports.go:27-57 | internal/app/moderation/registry_reports.go:59-102 \u2014 These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/registry_reports.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"030645fd84a6f08c04107578ff5d49e8cf9c01b17eee3a9ae94a9e4c71be22a9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (41 corresponding lines): internal/store/postgres/channel_member_list.go:326-366 | internal/store/postgres/channel_member_list.go:432-479 \u2014 These two members are one piece of code written twice and then edited apart: 41 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_list.go"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d9899d0528c55d62cad9a2a3f042d898b371ed7c8b644949acfc12cfe6cf453"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): internal/store/postgres/postgres_connection_admission.go:179-219 | internal/store/postgres/postgres_connection_admission.go:272-302 \u2014 These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/postgres_connection_admission.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ffcf749cecd9d704449c035f6b3102913830d8c9a018bbc53929bee62c322f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): internal/admin/service.go:1660-1688 | internal/admin/service.go:1747-1774 \u2014 These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1660}}}],"partialFingerprints":{"codehealthFindingId/v1":"efae80f9e83da9e0f78f53e149c48bcb0e25c0f715550068211fcd363a2cd1ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (37 corresponding lines): internal/app/channels/service.go:1430-1471 | internal/app/channels/service.go:2039-2075 \u2014 These two members are one piece of code written twice and then edited apart: 37 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1430}}}],"partialFingerprints":{"codehealthFindingId/v1":"963f988ab25e360d891cb63e01ab3fbf01caa2ad337c9e696b32503a7aa4cfaa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): internal/rpc/messages_forum.go:121-151 | internal/rpc/messages_forum.go:153-183 \u2014 These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"4248f9a2f66e8cfc513ab6da65369cb4ec4d53e81f35e3f18105cb4bdecc4378"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/app/files/sticker_management.go:49-83 | internal/app/files/sticker_management.go:85-109 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_management.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"08d8cc12d889d488ebba6d59375846ba2380020eb9052a4ea15d7bbe72c4d2f1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/app/bots/verifierbot.go:445-466 | internal/app/bots/verifybot.go:413-435 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":445}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa74cdefa5e702e95ef88ef4b4c15eb8966c81fe65649c9fae8857f339054fc8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 31\u002B corresponding lines): internal/store/postgres/star_gift_craft_auction.go:754-795 | internal/store/postgres/star_gift_lifecycle.go:745-776 | internal/store/postgres/star_gift_lifecycle.go:1169-1199 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 31 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":754}}}],"partialFingerprints":{"codehealthFindingId/v1":"f32492a0b3e843b93bbfccf928b27028a699699972983bb8cd3a6c86b1c2dbda"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): internal/app/files/external_media.go:70-100 | internal/app/files/webpage.go:100-140 \u2014 These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"94aaa4249531118f64e3029e41bfe8a9616c41f512fdc40caff1bea33bb4046e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/mtprotoedge/session_manager.go:318-349 | internal/mtprotoedge/session_manager.go:394-438 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"26b3916fc4f34b2885050cbda5f7980da45716f7649ca5b131186ba32c329ee3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 42\u002B corresponding lines): internal/store/postgres/channel_member_admin.go:525-566 | internal/store/postgres/channel_member_admin.go:606-652 | internal/store/postgres/channel_member_admin.go:654-700 | internal/store/postgres/channel_settings.go:1073-1119 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 42 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":525}}}],"partialFingerprints":{"codehealthFindingId/v1":"081b1141869fd62313669edf5b5f22b5f2b6e4d8b2f37a83f488bc73866bf233"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (43 corresponding lines): internal/store/postgres/media.go:912-954 | internal/store/postgres/media.go:956-1019 \u2014 These two members are one piece of code written twice and then edited apart: 43 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":912}}}],"partialFingerprints":{"codehealthFindingId/v1":"f031a2083eb147491b88982fa610dc929ca6f257acc876818a5668b2fcca436c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/app/ai/service.go:400-423 | internal/app/ai/service.go:425-448 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2fb43ab6de2551c9b5266f6b35823480417b43947a8c934b8f4c8d6fac03405"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/rpc/auth.go:685-716 | internal/rpc/auth.go:718-744 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":685}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c32551322568c3fbaaada359b216d81bcc4aeb0fbfc8ce497e1abed234447ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 25\u002B corresponding lines): internal/store/contact_reverse_batch.go:62-94 | internal/store/postgres/active_channel_ids_batch.go:76-103 | internal/store/postgres/authkey_get_batch.go:53-80 | internal/store/postgres/authkey_session_layer_batch.go:63-87 | internal/store/postgres/bootstrap_update_job_batch.go:80-107 | internal/store/read_model_batch.go:56-83 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 25 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"69258b9aa4494392ae54c6fad9118a987df3fff85166670c1b03afd63c58a353"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/store/postgres/active_channel_ids_batch.go:219-254 | internal/store/postgres/bootstrap_update_job_batch.go:249-280 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4e399ad38c78162ad1d90975574148ebc347589fad4b4128fb5e5ebda5de888"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/store/postgres/telegram_login.go:202-230 | internal/store/postgres/telegram_login.go:344-369 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"92dec65458cfde196c9a7a5cc164421e6780db8719b7a287aa146370ff57724a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (45 corresponding lines): internal/store/memory/channel_dialogs.go:517-564 | internal/store/postgres/channel_dialogs.go:2128-2172 \u2014 These two members are one piece of code written twice and then edited apart: 45 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"f07871cf09072fdd015e6a97ebeec203edbbbeb917bf7696a893c72fdf3524b8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): internal/admin/botverification.go:468-500 | internal/admin/botverification.go:503-535 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ff181f5c80927b67b78598943d6b7aced01cde1f9d919b734a014bf9c7b5139"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): internal/store/memory/channel_message_history.go:601-633 | internal/store/memory/message_history.go:387-421 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"eada9e76e46fc4bcc50fb58941b2988edfbc3a3ab9c6c809bd2e2cd6a7f9ba24"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): internal/store/memory/moderation.go:188-217 | internal/store/memory/moderation.go:248-277 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"069da4e168577f0ae48d4940d673c84fab4753233eabf68757086b8e9823977f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (33 corresponding lines): internal/mtprotoedge/rpc_execution_budget.go:132-170 | internal/mtprotoedge/rpc_result_subscriber_budget.go:77-109 \u2014 These two members are one piece of code written twice and then edited apart: 33 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_budget.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"a02d4b533f28a3e493a1a967e7f86d958b54d84de270e5069e94083bbbc2dca1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): internal/rpc/account_themes.go:132-165 | internal/rpc/account_themes.go:168-209 \u2014 These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_themes.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"80c3c7bccf45c6c6e4d7fab0cefad599131f952f9fae26682e2663703c46b895"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/rpc/ephemeral.go:384-408 | internal/rpc/welcome_messages.go:269-300 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"dece753a626b2d60627227bf1895d57c503aa65feef9cdedd2ccf587c8a670ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/store/postgres/account_rating.go:73-104 | internal/store/postgres/bot_verification.go:447-486 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_rating.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"05bc4b7e55e194fc096de6190e42bf88c2f977b0373c79c4dc61d7dc6208352f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): cmd/telesrv-admin/readstore.go:1535-1566 | cmd/telesrv-admin/readstore.go:1568-1594 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1535}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3274e1307325a7d8ce0f8e4259bfc3020b92afb6015d612ae07ebe305b5334f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): internal/rpc/channels_stubs.go:20-60 | internal/rpc/messages_reports.go:98-127 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"01600c55ed5612a1b24adcb0cb838e047d5b774b361f700bc59a73ac4a3af250"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/rpc/messages_dialogs.go:485-515 | internal/rpc/messages_dialogs.go:517-543 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"71d6b8a8ddce9c65484576c74694a61339f23beb1b30b835f88f7b93228aefa5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/rpc/presence.go:971-997 | internal/rpc/presence.go:999-1025 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":971}}}],"partialFingerprints":{"codehealthFindingId/v1":"42095d17d36c300877a6956a4b62a2534e3612459fdd56b59320aa58f648941f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/rpc/bots_longtail.go:308-334 | internal/rpc/bots_longtail.go:336-369 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"5079da2f5dec227c7d77fabd582760dc88d85cde1b05e3ea2e8dc444f9d9fd0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/compat/tdesktop/dialogs.go:85-111 | internal/compat/tdesktop/dialogs.go:118-144 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/dialogs.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"18c3ab4afa97b88b33b09805f43f304115a119ee29b1025f64cfbd8bc8cfc9f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (35 corresponding lines): internal/store/postgres/channel_reaction_catalog.go:10-44 | internal/store/postgres/channel_reaction_catalog.go:46-80 \u2014 These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_catalog.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"21cb4e82e8f729d351c6889894c34f0cccb29a8233017de34abfc57fbbcff4b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 23\u002B corresponding lines): internal/admin/service.go:2344-2366 | internal/admin/service.go:2369-2391 | internal/admin/service.go:3043-3066 | internal/admin/service.go:3069-3092 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2344}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe339ef3c7fa005eadaa75865c4672159dd33ffac4cbac31a389658d24ec796d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): internal/store/memory/channel_members.go:880-908 | internal/store/memory/channel_members.go:949-983 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":880}}}],"partialFingerprints":{"codehealthFindingId/v1":"71dab99e560c53c9ca81034260397d5105cb2b983a8459a7f1fe2fd81ed9cf6e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 36\u002B corresponding lines): internal/store/memory/verification.go:158-195 | internal/store/memory/verification.go:201-236 | internal/store/memory/verification.go:241-277 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 36 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"9afe42279e0c2162c7a68a8a01b3a584dc5e546e9bae458751cf1e1176bc84a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/rpc/expiry_dispatcher.go:50-79 | internal/rpc/expiry_dispatcher.go:81-105 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/expiry_dispatcher.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba2942ceb788527992e52c58843729e7028874e216aec99606ce3dcfb599b46b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): internal/store/memory/story.go:918-947 | internal/store/memory/story.go:949-979 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":918}}}],"partialFingerprints":{"codehealthFindingId/v1":"8edb1735b3de01329d4d2e8e1edb4aae6f3acfe58abb502f0419f767d8e09fb1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/store/postgres/channel_member_helpers.go:333-354 | internal/store/postgres/channel_member_helpers.go:371-388 | internal/store/postgres/channel_member_helpers.go:390-409 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_helpers.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"5906d3ced7b8b65533b88985bbf8c77ab12e9ff91225e06985c737ecbd7a8508"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): internal/rpc/messages_scheduled.go:9-37 | internal/rpc/messages_scheduled.go:39-70 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_scheduled.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6fa8c0fd72f3568b22ce7b83f51647f53147628d19dbc0dbf10441f8accad90"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): cmd/telesrv-admin/server.go:1266-1294 | cmd/telesrv-admin/server.go:1315-1344 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1266}}}],"partialFingerprints":{"codehealthFindingId/v1":"f39e9df886ee4de9736c72419b9e06f796da33f1030cdc37453be436e498ff89"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): internal/rpc/ephemeral.go:420-452 | internal/rpc/welcome_messages.go:302-332 \u2014 These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":420}}}],"partialFingerprints":{"codehealthFindingId/v1":"445850fc897e4cc560221e02435c58ea7009634d3562ea9bff6cd4bffd50414b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): internal/rpc/channels_invites.go:461-488 | internal/rpc/channels_stubs.go:712-742 \u2014 These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"55bf137403c019efd7b85179ea9c93b0510df28734575714e8a3953d62ed9ff6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): cmd/telesrv-admin/readstore.go:1205-1235 | internal/store/postgres/broadcast.go:352-381 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1205}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2ce5d3032f2d6fbcf89a43c467a43e401b8a0b609c348585f6ef7220084eea2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (41 corresponding lines): internal/app/ai/provider_http.go:149-189 | internal/app/ai/provider_http.go:341-384 \u2014 These two members are one piece of code written twice and then edited apart: 41 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ab0bb2c4786397895c6f35b1799ef7bc7376a59ce2d7ad71338d75b8fd59963"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/rpc/botapi_rich_projection.go:169-198 | internal/rpc/botapi_rich_projection.go:200-225 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"bceb8c9773b23c9ee4e05e66ee78f242e0593bf98ffd56bb6dc8bc0f2a0d1236"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/rpc/welcome_messages.go:14-41 | internal/rpc/welcome_messages.go:43-64 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/welcome_messages.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"78964f7bcd03b28374e58cb41d73beff963bccfe537087b23f8d13a9c359414b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): cmd/langpackfetch/main.go:263-293 | cmd/telegramloginkeygen/main.go:307-341 \u2014 These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/langpackfetch/main.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"5eeb259c6b8ed018fce3821c562b0f30d5ec36f1a93f9c40a823e280bceb6703"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/app/moderation/evidence.go:424-447 | internal/app/moderation/legacy.go:48-81 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"748bee218d74a9ce78fb6d1f2ac91f9c5919bc8e9682771e71999818836c8516"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (34 corresponding lines): internal/app/langpack/service.go:205-238 | internal/app/langpack/service.go:245-279 \u2014 These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/service.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd4712aee0cf9e449679f5d5e770242158af7c497091ab543a07cd8e848546a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/web/server.go:527-545 | internal/web/server.go:547-570 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":527}}}],"partialFingerprints":{"codehealthFindingId/v1":"23c8ae08cee27c73a15ac4274eb5aa85b98f6960551adcbd90f5d504c19bd353"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): internal/store/postgres/dialog.go:837-864 | internal/store/postgres/dialog.go:1068-1097 \u2014 These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":837}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ef3af6f01c0b345c263ba3c8cff6c42896473bc858a6b0d4febb23b24e7199f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/adminapi/account_rating.go:62-88 | internal/adminapi/server.go:1785-1811 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/account_rating.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"a81e76da19d34a2faa2f11bb26d7262f8b2107b17c01feee6b1b67b70fbec1a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/app/bots/verifierbot.go:577-602 | internal/app/bots/verifierbot.go:888-915 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":577}}}],"partialFingerprints":{"codehealthFindingId/v1":"9216a64c8b23379e89a55f6bdab06412095fc23a3659654acf11352944451f81"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/store/postgres/peer_username.go:176-201 | internal/store/postgres/peer_username.go:254-277 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/peer_username.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"c85cf7b715390ca0cf95750bd462626dccb08df1c9599a34b7636916b071fd61"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): internal/store/memory/ephemeral.go:242-270 | internal/store/memory/ephemeral.go:272-299 \u2014 These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ephemeral.go"},"region":{"startLine":242}}}],"partialFingerprints":{"codehealthFindingId/v1":"12354b6b505e7707c3a5ccb19a072370124b490f8fae5121661ea76d33c7946d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 35\u002B corresponding lines): internal/store/postgres/active_channel_ids_batch.go:161-195 | internal/store/postgres/authkey_get_batch.go:162-206 | internal/store/postgres/authkey_session_layer_batch.go:168-214 | internal/store/postgres/bootstrap_update_job_batch.go:179-215 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 35 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4846b6f5692fca315c9f042e7c31d08b801f3fc4481a0b31bb9e8ab47d314a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/admin/botverification.go:808-832 | internal/admin/verification.go:346-366 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":808}}}],"partialFingerprints":{"codehealthFindingId/v1":"10169d44146bb169fb3950a66d2c298e6f7c50ef2383af5e026a2df4bd027b03"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/app/dialogs/read_model_cache.go:509-538 | internal/store/memory/message_helpers.go:142-165 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":509}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a3a93bdd9a66ebe0a59206a5b23494ab69222649b7badee3ddc52e48d05b7e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/rpc/account_business.go:325-356 | internal/rpc/account_business.go:358-382 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"8dd15219fc1798a3ff482bf5e231c658fa3ab77f282e5b7c12f828aedfe9cf1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 30\u002B corresponding lines): internal/store/postgres/counter_source.go:21-50 | internal/store/postgres/counter_source.go:110-139 | internal/store/postgres/message_helpers.go:227-257 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 30 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/counter_source.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ea0b464212cf165f3101172148435155ac45b48e55d7429b4589246f17da848"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/store/postgres/channel_helpers.go:606-637 | internal/store/postgres/premium.go:34-60 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":606}}}],"partialFingerprints":{"codehealthFindingId/v1":"2aa22f887a061b12b6065815bd6e0325035a2ec06d7f28109326edb692ebabd4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/app/botverification/service.go:996-1020 | internal/app/botverification/service.go:1028-1060 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":996}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8abf6bf403309575da6c6c1cd37d7e506b0123991f389a235e9e27132fc36b9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/store/memory/channel_core.go:162-188 | internal/store/postgres/channel_core.go:289-316 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"410b590cfc83acbad0776ecee20943cb8a55a94cbc949c21d0b3e1ee6a937045"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 37\u002B corresponding lines): internal/store/postgres/contact.go:786-830 | internal/store/postgres/media.go:1387-1433 | internal/store/postgres/privacy.go:70-106 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 37 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":786}}}],"partialFingerprints":{"codehealthFindingId/v1":"97339055068d255ec36d331abef1662c22788acc8ff6204be439f61476d8df9e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/rpc/auth.go:766-792 | internal/rpc/auth.go:806-833 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":766}}}],"partialFingerprints":{"codehealthFindingId/v1":"b262d2e157d0c82f4db45af6e1816e4c12bffcc2ea32e9fe2ad67943b239cc52"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/rpc/botapi_update_queue.go:433-456 | internal/rpc/botapi_update_queue.go:478-505 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb3e2cecdc8417d5b737aad14433c5c82d29cda66e591336d67781b69cc71bb2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/rpc/presence_last_seen_batch.go:195-215 | internal/store/postgres/user.go:521-564 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence_last_seen_batch.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"63ccd97091a1126a118bc1e7e25bc267c5e7523a6b6cf661d7b846c8a3fe4c3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 26\u002B corresponding lines): cmd/telesrv-admin/botverification.go:330-362 | cmd/telesrv-admin/botverification.go:425-450 | cmd/telesrv-admin/botverification.go:490-516 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 26 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"20758a8ab9613d47604909134309d2e6921e61527251e27cf863e7bac687c8b9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/rpc/bots_longtail.go:250-274 | internal/rpc/bots_longtail.go:276-306 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"3edebf751254a8b3455d70387b226804072f648f27a995f03760805ccb0648da"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/store/postgres/message_delete.go:532-562 | internal/store/postgres/message_send.go:920-946 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":532}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d1fd233a8279b39ed0c24eeaeaa87ec404569aa2b3540663cf5b606ebd85068"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/store/postgres/story.go:401-436 | internal/store/postgres/story.go:565-596 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":401}}}],"partialFingerprints":{"codehealthFindingId/v1":"1cb4d926b028962e27f35efe3ba387e39d608ed14f8ad0dfffcce6d1f5a495b5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/admin/service.go:1692-1720 | internal/admin/service.go:1725-1742 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1692}}}],"partialFingerprints":{"codehealthFindingId/v1":"b67e1e7808f5440239d79ea605921b0a31dbd0c5f39a74a4d6b84c802455b41f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/rpc/channels_updates.go:405-426 | internal/rpc/messages_forum_read.go:78-99 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_updates.go"},"region":{"startLine":405}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cc49815f6aca8a9ef5fd3179621bac54ba0fe41007987e7aa6daf0932017120"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/rpc/stories.go:3412-3437 | internal/rpc/welcome_messages.go:334-359 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3412}}}],"partialFingerprints":{"codehealthFindingId/v1":"73a82d934dbed370bf4c3b1719cefa449a1d361d9816c434bc2026f29f503b95"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/store/memory/channel_invites.go:834-859 | internal/store/memory/channel_members.go:847-869 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":834}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca9beb4064133e464be24a4fec650f0adde1ceb6dad475c3971ccfa3337d0e2e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/store/memory/channel_message_helpers.go:55-79 | internal/store/postgres/message_helpers.go:18-38 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_helpers.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"d92c8e915a1fa02f8172f09e27cfb97c81f49047ca50c358528f50b1ffd181bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 35\u002B corresponding lines): internal/store/postgres/account_rating.go:337-385 | internal/store/postgres/account_rating.go:389-424 | internal/store/postgres/account_rating.go:429-463 | internal/store/postgres/account_rating.go:473-507 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 35 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_rating.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"73229aac4aaea7fc93ae549e19a5099b93da48936ff05dba587505925e046f73"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/app/bots/stickersbot.go:283-302 | internal/app/bots/stickersbot.go:304-320 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":283}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3faaa28eaee9a76b4d8ac87f1b135a112afef61ebf6dbc1656a1b45610ec5d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/app/files/photos.go:936-959 | internal/app/files/photos.go:961-983 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":936}}}],"partialFingerprints":{"codehealthFindingId/v1":"9337a406d46f0d0af8fed2e4022f042dc2583aacb1a25113fe9a76a6e3ddfb1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/rpc/phone_calls.go:148-174 | internal/rpc/phone_calls.go:176-204 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_calls.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a1af1037031d10f59f38639a0685fa0f9f9c3b93416573ef25fff412a2c7a37"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/postgres/groupcall.go:35-48 | internal/store/postgres/groupcall.go:69-85 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"140e0437326817ec98a5f590df2b5c085358d009c160b3a99fcdf545904ccfcc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/rpc/phone_group_call_edit.go:216-237 | internal/rpc/phone_group_call_edit.go:239-265 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_edit.go"},"region":{"startLine":216}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ab8d4040e7d34b0c077be79405eb47c59d1716ce8824b8456ef934084e60df1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/store/postgres/channel_updates.go:532-555 | internal/store/postgres/message_allocators.go:15-38 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":532}}}],"partialFingerprints":{"codehealthFindingId/v1":"9937d919ebe4a556d1411223b01803b0ad8cf08cddf63038f206fc6c4ee6052b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/rpc/channels_stubs.go:635-655 | internal/rpc/channels_stubs.go:657-677 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef671cfdabf4bc940af814c826f83b1ba89e64125accbe6a0ddc3c7ac16ea6c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/rpc/payments_star_gifts.go:313-334 | internal/rpc/payments_star_gifts.go:536-560 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":313}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfd707596c2a12c0b8937ba7572f1e9f5230c1b333a1c5f23c5a98df02e1b2ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): internal/store/postgres/account_deletion_notifications.go:56-84 | internal/store/postgres/admin.go:363-391 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_deletion_notifications.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab230469b0360e3e2a2346f3f7173c53be19e5891f5669c674eba7da33d6b690"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 28\u002B corresponding lines): internal/store/postgres/bot_verification.go:245-272 | internal/store/postgres/bot_verification.go:490-517 | internal/store/postgres/bot_verification.go:1048-1078 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 28 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"78d3140d103747094bd10bc92754c63870b767bba67c0d2a2411d042fd10dc4f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/app/usernames/service.go:186-218 | internal/store/memory/id_allocator.go:185-210 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/usernames/service.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c81b0ea2806f534099c5337a5782422c0ef9ca4989eddcac8bd2d6952ef0e0e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/domain/moderation_registry.go:62-86 | internal/domain/moderation_registry.go:133-156 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation_registry.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d3088d231c8b489417a6e9b00d4e115f1e9fc0ee80c1d0bfb9c8fb420ec760e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/memory/story.go:477-498 | internal/store/memory/story.go:521-550 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bc7fe359eaab102b348ad73e5b8b0e476c24e59f2b42b6195139f1e33a2239b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 28\u002B corresponding lines): internal/store/postgres/moderation_cases.go:1244-1273 | internal/store/postgres/moderation_registries.go:292-324 | internal/store/postgres/moderation_registries.go:326-353 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 28 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1244}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ebc7f5d36993f29d58125c48c8fff895312e4940d0cce57113203dc0376aaf1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): internal/store/postgres/account.go:613-642 | internal/store/postgres/account.go:868-897 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"f86152bc1eaa2c8e50b2e55dbccba790b9450433581d5f8ea5ffa5996024c0b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): internal/store/postgres/channel_invite_import.go:235-270 | internal/store/postgres/channel_member_join_requests.go:93-121 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f25715f8ad60926962b44168f6f1295a7673cd3b00ec45c0984eca61949d458"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 25\u002B corresponding lines): internal/store/postgres/channel_member_join_requests.go:12-36 | internal/store/postgres/channel_member_join_requests.go:38-62 | internal/store/postgres/channel_member_join_requests.go:64-91 | internal/store/postgres/channel_reaction_settings.go:12-43 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 25 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join_requests.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"dde362b87c31092f4842b0351632c3d654b4f83235381cf4694780eb3c99539f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): cmd/telesrv-admin/privateview_store.go:515-543 | cmd/telesrv-admin/privateview_store.go:545-570 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":515}}}],"partialFingerprints":{"codehealthFindingId/v1":"96180a3d5329aac3905acdeb4a60c3efd41803c39898ace71475d82ba3761d0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): cmd/telesrv-admin/server.go:770-795 | cmd/telesrv-admin/server.go:797-825 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":770}}}],"partialFingerprints":{"codehealthFindingId/v1":"54173f1ea9d8a022a97733533e9e698f0d86464e5c8683fcb33570f3f35fddd8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/rpc/botapi_gateway.go:937-971 | internal/rpc/botapi_gateway.go:973-999 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":937}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7d2b96f5650f89618933260d7a0b204fabb279935077ad6934b9a477785b810"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/admin/service.go:3362-3393 | internal/web/server.go:1027-1058 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3362}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c7701939028d0dbd2d4f514eb8c7cff81210889b42390d408da3d7467ee2e70"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/rpc/router.go:1691-1716 | internal/rpc/router.go:1797-1818 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1691}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f371618eb23b4185e20d89f21275ea74f3407ebd7b877b4ef255abbf5af1228"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 7\u002B corresponding lines): internal/store/postgres/contact.go:846-852 | internal/store/postgres/contact.go:854-860 | internal/store/postgres/contact.go:862-868 | internal/store/postgres/contact.go:870-876 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 7 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":846}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3704d24a14f5becf33551ff4c2d99f60dfce17f498ab4ec6ea71afa02a97095"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/app/files/upload_receipt.go:42-59 | internal/app/files/upload_receipt.go:61-78 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/upload_receipt.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d00c115672361785008a26093dca06a385a0028a88368613834e73229740df9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (35 corresponding lines): internal/rpc/account_themes.go:212-246 | internal/rpc/account_themes.go:250-284 \u2014 These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_themes.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"f89dd4485be55dfd34dd7f54c377d85d9046d38dc56f77c985afadfbbac3f98f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/rpc/encrypted_messages.go:22-45 | internal/rpc/encrypted_read_typing.go:33-58 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_messages.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ee832a9302879cf646944718fc727f8b00991b64d6293706e0075e98332246e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/store/memory/channel_boosts.go:35-59 | internal/store/memory/channel_boosts.go:108-125 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"c93307bd572a049023b5a2d162f7c658a17072c1f979f1ba99a5697f236ce8eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/store/memory/contacts.go:48-68 | internal/store/memory/contacts.go:361-388 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0511f2431611fbbe333b6cebfa9b40094827c0ea692462d356e2ea28adbd58e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): cmd/telesrv-admin/readstore.go:1291-1311 | internal/store/postgres/authorization.go:354-380 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1291}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a4d8b3cfaf9f6262cc73aa9aa03c0125a6fd63668d173fc950370a524ab3e55"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 23\u002B corresponding lines): cmd/telesrv-admin/readstore.go:1313-1335 | cmd/telesrv-admin/readstore.go:1342-1373 | cmd/telesrv-admin/readstore.go:1375-1397 | cmd/telesrv-admin/readstore.go:1431-1458 | cmd/telesrv-admin/readstore.go:1460-1488 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1313}}}],"partialFingerprints":{"codehealthFindingId/v1":"32e4ad9318dea5c91943d9c99579301a8b445e4aec54e0ccbf900b4ffd2200d7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/rpc/bot_verification_projection.go:145-168 | internal/rpc/messages_monoforum.go:257-285 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e752228e71571319adf719637b083523e3908d79bb87e37408a1edd2cdd1664"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 23\u002B corresponding lines): internal/rpc/messages_compat.go:414-436 | internal/rpc/messages_compat.go:438-466 | internal/rpc/story_peer_projection.go:504-526 | internal/rpc/story_peer_projection.go:528-550 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_compat.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6ced63f583ed5dbcd930d1657f4a77902dcfd519e58310581b40c859ea86502"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/admin/star_gift_catalog.go:253-266 | internal/admin/star_gift_catalog.go:268-281 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/star_gift_catalog.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8336140b03f1598e9d26f48b3e12cbd1d53087f10240f4395e193aadbff0d70"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): internal/store/postgres/media.go:783-810 | internal/store/postgres/media.go:812-842 \u2014 These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":783}}}],"partialFingerprints":{"codehealthFindingId/v1":"61d5276b04ca6d2f5adab9113851c08335f8e52f98e4ba9fbce9d74164d44683"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): cmd/telesrv-admin/readstore.go:2209-2236 | cmd/telesrv-admin/readstore.go:2736-2761 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":2209}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a43283d2f1b19ce10718eb3d1190aa12b89d7cdde13f995b721b56ed4b7c322"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 24\u002B corresponding lines): internal/rpc/bots_longtail.go:175-200 | internal/rpc/messages_pin.go:78-101 | internal/rpc/photos.go:371-401 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"b524233ce3bf6c87a3e083324ce475b464f822f57e923ae168324bf6850bda9a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/rpc/router.go:1395-1418 | internal/rpc/router.go:1420-1451 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1395}}}],"partialFingerprints":{"codehealthFindingId/v1":"604aecfd4771915edb296f7bb3f7069a381fe9f13d92eb8fa19ccbd75092a8b8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/postgres/star_gift_entitlements.go:195-210 | internal/store/postgres/star_gift_entitlements.go:262-282 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_entitlements.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"72bcdbe9d2299cbacadc527a30fba07286a32ee1b428f1cbc6b0dd9307f673de"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): cmd/telesrv-admin/readstore.go:1604-1628 | cmd/telesrv-admin/readstore.go:1630-1654 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1604}}}],"partialFingerprints":{"codehealthFindingId/v1":"e423a7a40041c917d7aa4cdbb6d76d851fd9169b36838dd0289f02111d2d3ae4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/photos.go:531-550 | internal/rpc/photos.go:552-573 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"8032fd6b8bcdbce298a0ee4c192a3e4f1eb5eba305f835c687bf573e470d5728"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/rpc/stickers_creator.go:305-328 | internal/rpc/stickers_creator.go:352-373 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers_creator.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b3d2de2c3f2e0814a9ed4ba356ba45b8a2ae6c63c9a9d5c800b6d4dadc19d41"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): cmd/stickerseeddeploy/main.go:111-136 | cmd/stickerseeddeploy/main.go:138-160 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerseeddeploy/main.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"37a2f714e39c458b18881e56be28d10e57424b0a42feab98100532c3d00da3ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/app/account/business.go:191-208 | internal/app/account/business.go:210-227 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/business.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"02db50577702b1d8c1fd5e8d340d8d9ea64bcf4960a7da521f047fca87febb01"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/payments_star_gift_lifecycle.go:390-409 | internal/rpc/payments_star_gift_unique.go:124-146 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":390}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb9059bdbcc24af2e67b534eba4e94830100e8002c081887468a6436a421dd9f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): cmd/telesrv-admin/server.go:1296-1313 | cmd/telesrv-admin/server.go:1346-1363 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1296}}}],"partialFingerprints":{"codehealthFindingId/v1":"66a29a580260bbd1de3a59e385968b48a67c4b62592d9b404d93d92202b0b9ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (29 corresponding lines): internal/app/ai/provider_http.go:88-116 | internal/app/ai/provider_http.go:118-147 \u2014 These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9b3e7a3584c1575ecc6275dca91f516833f05953ab4908478c2312055f8494a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 27\u002B corresponding lines): internal/botapi/server.go:837-863 | internal/botapi/server.go:1214-1244 | internal/botapi/server.go:1246-1273 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 27 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":837}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3b534d4bccb1045168d8056d83a265277a1b8a85eaf371ab2bdada154f7cf5c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/rpc/stories.go:476-496 | internal/rpc/stories.go:508-528 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":476}}}],"partialFingerprints":{"codehealthFindingId/v1":"a44df59482d8845b9376bd6ddaf846999f25b61122bfb91efe45f7a9ca228944"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/rpc/story_pinned_stories_cache.go:123-140 | internal/store/memory/story.go:1407-1418 | internal/store/postgres/story.go:2534-2545 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_pinned_stories_cache.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"9624c58db40fc7cf6174064b47f59b1332c0e0bae9baa600bbc8dc0a35b43ac9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 19\u002B corresponding lines): internal/rpc/channel_fanout_dispatcher.go:1057-1084 | internal/rpc/channel_fanout_dispatcher.go:1167-1186 | internal/rpc/channel_fanout_dispatcher.go:1191-1209 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1057}}}],"partialFingerprints":{"codehealthFindingId/v1":"47a6b8ba3072dee87496647de39107cb14aa9d5139689fabf7c4efeea005fc2f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (58 corresponding lines): internal/store/postgres/channel_dialogs.go:1492-1549 | internal/store/postgres/dialog.go:750-810 \u2014 These two members are one piece of code written twice and then edited apart: 58 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1492}}}],"partialFingerprints":{"codehealthFindingId/v1":"d92b51c48904c5a31e26c2a80795ff42c89d9237a3621986e9420c937fe64cf4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/postgres/moderation_cases.go:1025-1044 | internal/store/postgres/moderation_cases.go:1177-1204 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1025}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bd1077a69719bc62caacdd846715b96ba216318ac0227156e3829237696af42"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 14\u002B corresponding lines): internal/admin/service.go:3654-3667 | internal/admin/service.go:3669-3682 | internal/admin/service.go:3684-3700 | internal/admin/service.go:3829-3842 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3654}}}],"partialFingerprints":{"codehealthFindingId/v1":"50fdd43b4ea16c6feba1f9614a204cea6407b24b1ae1ae76de607848d2987e40"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/messages_webview.go:423-439 | internal/rpc/messages_webview.go:521-537 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"daa5be8e737a8995871419603a2d5b9999f933ea10bb24634cf9992e4dcd994e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/store/contact_reverse_batch.go:143-169 | internal/store/read_model_batch.go:146-171 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"575b70094a395db551356f6e81ce2db0f49a1fc2566345860228b1d9e0102742"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/rpc/phone_group_call_updates.go:87-109 | internal/rpc/phone_group_call_updates.go:147-165 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_updates.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c44e246e4ee3b78a68ef1de7060834a177bbc920d03d51345b9369ea21a3c8d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/app/channels/service.go:2021-2035 | internal/app/channels/service.go:2111-2124 | internal/app/channels/service.go:2142-2155 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2021}}}],"partialFingerprints":{"codehealthFindingId/v1":"42d2bf029962fa29141a130733d8e92542070cdfa9518cba9b23956e33c7f173"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/rpc/botapi_update_queue.go:373-395 | internal/rpc/botapi_update_queue.go:397-420 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"053a0b2031bbfed210bf60cd8628599e88632228eeba8e1a8a7473a61edf04fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 25\u002B corresponding lines): internal/store/postgres/bot.go:287-312 | internal/store/postgres/bot_miniapp.go:16-40 | internal/store/postgres/dispatch_outbox.go:215-242 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 25 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"d50025138daeace36a284454063bcb859819e4c759839155327f913cfc20d5de"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/store/postgres/telegram_login.go:42-66 | internal/store/postgres/telegram_login.go:68-100 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"19ca082ef3723ca9128909821d8486c8e4c09dd00b21d75a2ec79aebfe79d33e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): cmd/telesrv-admin/botverification.go:63-80 | cmd/telesrv-admin/botverification.go:82-99 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"78fb6572f9277ea20e54551387fc571b1b9403004cbb244fa933f9707c0c66f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 14\u002B corresponding lines): internal/admin/service.go:3426-3439 | internal/admin/service.go:3441-3454 | internal/admin/service.go:3456-3472 | internal/admin/service.go:3474-3490 | internal/admin/service.go:3586-3602 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3426}}}],"partialFingerprints":{"codehealthFindingId/v1":"247cd3b202d94fbb976aae249ae448be893a3ffd3d34b200083f1c01b24a7a04"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/store/postgres/auth_identity_lock.go:80-111 | internal/store/postgres/channel_reaction_unread.go:404-435 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_identity_lock.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"51721b447be7be51aa17733cef7afb9ac55234761586e0c650a471b5bdb0e9f1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 22\u002B corresponding lines): internal/rpc/account.go:1266-1290 | internal/rpc/channels_stubs.go:553-578 | internal/rpc/convert_business.go:252-273 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 22 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1266}}}],"partialFingerprints":{"codehealthFindingId/v1":"45222dadcb8f9225c3124b6408dd77147d8275af79496ce4edd84c8f2675db0c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/bots/verifierbot.go:1397-1415 | internal/app/bots/verifybot.go:1128-1146 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1397}}}],"partialFingerprints":{"codehealthFindingId/v1":"90e43590d04d012933e25658892fe3db211eb8881fcdc9d2cd2a93a5d7644789"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/mtprotoedge/outbound.go:1869-1904 | internal/mtprotoedge/outbound.go:1907-1932 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1869}}}],"partialFingerprints":{"codehealthFindingId/v1":"92dea7ffb638182617a88ea31f5adc867eb8e2c7447047beb76ca81d21449e50"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/update_peer_refs.go:268-284 | internal/rpc/update_peer_refs.go:286-300 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c979698d464ed8a463a76985f6f4d9e38a465452c5de2928f9aba35a0c0fb7c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 32\u002B corresponding lines): internal/store/postgres/botapi_update.go:383-425 | internal/store/postgres/botapi_update.go:427-463 | internal/store/postgres/dialog.go:417-448 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 32 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"b212102a21bdc6581e8936f391c328f55f8e0bde18f55ddafec8bbab7f3c8361"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 24\u002B corresponding lines): internal/store/postgres/channel_reaction_unread.go:179-210 | internal/store/postgres/channel_read.go:656-687 | internal/store/postgres/channel_topics.go:933-956 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"7eea2a0898812d4b8dcca165e144d0550fad3c648e62245fc1696b1317aaf59a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/postgres/langpack.go:26-47 | internal/store/postgres/langpack.go:49-70 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/langpack.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"083abbc39a7af575d2524ba4264fb1f3afcc8fd6261fbca767238a9283c21793"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 24\u002B corresponding lines): cmd/telesrv-admin/readstore.go:1932-1966 | cmd/telesrv-admin/readstore.go:2180-2203 | cmd/telesrv-admin/readstore.go:2473-2505 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1932}}}],"partialFingerprints":{"codehealthFindingId/v1":"d366b91e92d616b75d965d9a1ac1206aea6f72929499afd2a02b5018dc1b7dca"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/app/stories/service.go:256-273 | internal/app/stories/service.go:297-313 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec8cc23ba57ed5b2a62fcf6aa4073ce581f0e7db0f65e2faefb0d3683a6f7ebf"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 26\u002B corresponding lines): internal/mtprotoedge/session_manager.go:2089-2114 | internal/mtprotoedge/session_manager.go:2352-2384 | internal/mtprotoedge/session_manager.go:2444-2473 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 26 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2089}}}],"partialFingerprints":{"codehealthFindingId/v1":"79577a0510ad46ee3417d0bd407a9ba9475150b1df6e151522cee50af26d06e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 20\u002B corresponding lines): internal/rpc/payments_star_gift_collections.go:118-142 | internal/rpc/payments_star_gift_collections.go:144-163 | internal/rpc/payments_star_gift_collections.go:165-189 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_collections.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"b16c5fe97ca810632f1a40fe5ac62a0ceb0e0cb4f1709934288fc5e3ed5f14fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/memory/story.go:1578-1593 | internal/store/postgres/story.go:2421-2436 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1578}}}],"partialFingerprints":{"codehealthFindingId/v1":"01d072df204fbfce3e2a7261c5547b127e087edc1c4d8a7848463d77058839fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/store/postgres/active_channel_ids_batch.go:200-217 | internal/store/postgres/authkey_session_layer_batch.go:219-237 | internal/store/postgres/bootstrap_update_job_batch.go:229-247 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"062856cde76148b6177ccbe0367d563cb6e6e65042183d034fa19a3b54a04a46"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/postgres/bot_verification.go:685-715 | internal/store/postgres/star_gift_collectibles.go:425-446 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":685}}}],"partialFingerprints":{"codehealthFindingId/v1":"34d51c523d9580246712fbb2d720d414ed90bea004fadc96b81b472fc5d3c1e1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/postgres/moderation_cases.go:512-531 | internal/store/postgres/moderation_registries.go:57-79 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":512}}}],"partialFingerprints":{"codehealthFindingId/v1":"badd230a495945374a74f81af94eac56b2fd37d6236a6c91dc995651e56a89f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 20\u002B corresponding lines): internal/adminapi/server.go:339-359 | internal/adminapi/server.go:599-619 | internal/adminapi/server.go:1053-1072 | internal/adminapi/server.go:1118-1137 | internal/adminapi/server.go:1139-1158 | internal/adminapi/server.go:1401-1420 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"1380e363716c1ccefafc16e15b92b11d41f1d59879bfe26a0bded6929eba60a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/files/blobcache.go:130-145 | internal/store/postgres/media.go:533-553 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/blobcache.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"93737950f06c3d2c7189368c25956d7dc1d43c45b45eeae28ed94401fd7d6a86"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/rpc/account_deletion_notifications_worker.go:51-72 | internal/rpc/account_freeze_worker.go:36-57 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion_notifications_worker.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba1dd3544d58dc9b3ea3e0c1cb6ee312e7e38d471d3b4f1aace958dc1c0a4a24"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (27 corresponding lines): internal/rpc/router.go:1517-1549 | internal/rpc/router.go:1551-1577 \u2014 These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1517}}}],"partialFingerprints":{"codehealthFindingId/v1":"386b7653117603ecf2e4163a4220a807e48ebb7e9bbfb68c6965ef38dd70e3fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/message_helpers.go:264-278 | internal/store/postgres/message_helpers.go:359-374 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_helpers.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c328025497f5f1769d8b1e9e638d38f8e2a917a156aa68b6c93d0f8efd2b3e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 45\u002B corresponding lines): internal/store/postgres/contact.go:63-113 | internal/store/postgres/contact.go:115-165 | internal/store/postgres/contact.go:174-218 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 45 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"d63067ee764627901c58c228cbdeaf98c80184a5a414bc10549332107cd0cced"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): cmd/telesrv-admin/donations.go:113-133 | cmd/telesrv-admin/donations.go:155-179 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/donations.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca87dccb3383155c35ea91bfe28643defb884a40043f211e11f24e6646eda168"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/adminapi/botverification.go:34-50 | internal/adminapi/botverification.go:53-69 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"04000c7ce1e2065cb5326edc117f4aa4c786d71deecc9f331c518232895c8c31"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/app/auth/service.go:416-439 | internal/app/auth/service.go:443-460 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":416}}}],"partialFingerprints":{"codehealthFindingId/v1":"bff221d8a1eb6f758fcf1ce96c9272aac7a1abf73bd952706e12fa9feb2b131b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/bots_inline_message_id.go:13-25 | internal/rpc/bots_inline_message_id.go:27-40 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline_message_id.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"df3a85cc714d3628a6e06c15d402b97721805e004a5caf710ed64161144ef357"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/rpc/inline_registry.go:257-275 | internal/rpc/inline_registry.go:277-295 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/inline_registry.go"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"53d7ed407cd5ae69d72eb97ef0816f86b8032bdf337bccb8129e9e07d97e6035"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 27\u002B corresponding lines): internal/store/postgres/channel_boosts.go:336-366 | internal/store/postgres/channel_polls.go:169-195 | internal/store/postgres/channel_polls.go:200-228 | internal/store/postgres/star_gift_collectibles.go:207-233 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 27 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":336}}}],"partialFingerprints":{"codehealthFindingId/v1":"c467327fe1ffd45a168e9ff88428588c7de96c39b14d5c883c90e01a15db8917"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): internal/store/postgres/channel_helpers.go:322-366 | internal/store/postgres/channel_member_list.go:297-324 \u2014 These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba6d9c1de304876aead9bef7be501c4b801264b46a05ab935b407c828ecd408d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): cmd/telesrv-admin/report_evidence.go:41-58 | cmd/telesrv-admin/server.go:2835-2851 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/report_evidence.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"290220d70e83fdda9d35036725e57824ce2bde00a1b9924eb9bf007e331bda34"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/app/bots/botfather.go:684-703 | internal/app/bots/botfather.go:966-995 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":684}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed47ea5ba0c59dd58659b298bdb5c748cabced2dd4154da4fcd8932fd17f4922"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): internal/app/usernames/service.go:222-249 | internal/app/usernames/service.go:253-280 \u2014 These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/usernames/service.go"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"354a094ad579833aeac5b888f6c23b3452ab9257bd9b13ac75058ca4ad33440c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/postgres/channel_boosts.go:213-229 | internal/store/postgres/channel_history_ttl.go:10-31 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfce44b9e072b63c52b726d60e1425233605d2ec125b34fbe3822c9bf97ff6ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/store/postgres/channel_member_list.go:405-430 | internal/store/postgres/contact.go:425-447 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_list.go"},"region":{"startLine":405}}}],"partialFingerprints":{"codehealthFindingId/v1":"d95b795a4b58d9e5e04e80eb2b3b05d3b067e3a40922aeeceff7bec2c811ce03"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): cmd/telesrv-admin/readstore.go:310-328 | cmd/telesrv-admin/readstore.go:3482-3502 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"78d5fb0db341df92887cc17d67b363bbf28f2bf698b0d3a78180195bbb277078"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/app/bots/verifierbot.go:1172-1195 | internal/app/bots/verifybot.go:937-964 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1172}}}],"partialFingerprints":{"codehealthFindingId/v1":"41570bb70adf47129b055d04a8ecc3f7029ae49f9cd1b2db872396fb8b07b680"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/channels_stubs.go:499-516 | internal/rpc/premium.go:151-168 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"34b0e57e2383a7846ac0a2ffd2d194252ca8ec329a2ed19caf09c2b08ee8026b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/rpc/login_token.go:97-117 | internal/rpc/login_token.go:119-143 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/login_token.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"0867ca5074d2c2cf8f3428aa597bad5f8dbca6df56aa0a1b1a11224870d0f3f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/rpc/stories.go:387-407 | internal/rpc/stories.go:1147-1170 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":387}}}],"partialFingerprints":{"codehealthFindingId/v1":"d21ecdb14baa0b3382eed5123ae3ab51954f220b9bf5105f3d5b0cebfbfbf20a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): internal/store/postgres/account.go:231-257 | internal/store/postgres/authorization.go:192-207 | internal/store/postgres/authorization.go:264-282 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"21b3318192f4e28a91083a70eb92a8107a63d487f70a4ed0dbe9dd5b01c1a19a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/store/postgres/dispatch_outbox.go:244-268 | internal/store/postgres/message_send.go:955-981 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dispatch_outbox.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"21fd983d424261d088e51668d5970753121b92ba0667ec48b003efb125baccb5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/moderation/actions.go:321-339 | internal/app/moderation/actions.go:341-359 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/actions.go"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a7c757b939cc77da029ebc3c31a029168b895bc405d783ee6b78bdb0921ea08"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 23\u002B corresponding lines): internal/rpc/story_pinned_stories_cache.go:155-180 | internal/store/memory/story.go:1428-1450 | internal/store/postgres/story.go:2555-2577 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_pinned_stories_cache.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fe846db9852920db61ee8a783b5c175469bcb43db1e31a96094141264c6982f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/store/memory/channel_members.go:626-646 | internal/store/memory/channel_settings.go:102-119 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":626}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e27a99eda4ab883293b41c49bdf9af6eead7234a1a9a9fe62f09b4eac8c460a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/channels/read_model_cache.go:52-67 | internal/app/channels/resolve_cache.go:51-69 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/read_model_cache.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"304d29673e495deae41b79c0c69996e29957a202b3a97d020178f7188d776850"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 22\u002B corresponding lines): internal/app/dialogs/service.go:837-859 | internal/store/memory/channel_dialogs.go:469-491 | internal/store/postgres/channel_dialogs.go:2074-2095 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 22 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":837}}}],"partialFingerprints":{"codehealthFindingId/v1":"571ff4f05521d37a2a0778db4851a3d97672fe2eb46ccf5db13d042208be6c26"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/store/postgres/ai.go:26-51 | internal/store/postgres/themes.go:29-55 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ai.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccb9d68f114340d334c30cf7bd7c972945f593753ba70a71e486554a6163c9bb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/postgres/channel_row_cache.go:60-83 | internal/store/postgres/channel_top_message_cache.go:52-73 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_row_cache.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"973d754117ff94336f6f4a51f22998047aefa4a38675fcc693a4f15a0beb67f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 17\u002B corresponding lines): cmd/telesrv-admin/readstore.go:3193-3209 | internal/store/postgres/donations.go:240-259 | internal/store/postgres/donations.go:261-277 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":3193}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9b9beaa6f4d239aaf7a836c756fb299738a53dcdf95c26c59a09a6294e9bfd0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/bots/verifybot.go:586-604 | internal/app/bots/verifybot.go:606-625 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifybot.go"},"region":{"startLine":586}}}],"partialFingerprints":{"codehealthFindingId/v1":"c371fbae31d76a4def993987f5701451e4a04ee6dbefc1c799f3195d4b5f2fd4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/app/userprojection/contact_cache.go:794-815 | internal/app/userprojection/contact_cache.go:856-883 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":794}}}],"partialFingerprints":{"codehealthFindingId/v1":"8597eae08505270170026fb8ff6ce6cd58f24f3cb61e9b1defe0daee91e0b81b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 23\u002B corresponding lines): internal/store/postgres/bot_verification.go:1083-1108 | internal/store/postgres/media.go:304-326 | internal/store/postgres/media_search.go:258-283 | internal/store/postgres/media_search.go:370-392 | internal/store/postgres/verification.go:803-828 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":1083}}}],"partialFingerprints":{"codehealthFindingId/v1":"755df8a3b73a83f80c399fd64cb32191c0f1d75ad4d4e74b0d6ba43c2e1b2a0b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (31 corresponding lines): internal/app/botverification/service.go:366-396 | internal/app/verification/service.go:358-392 \u2014 These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"630d2d305c756237b823fea6b41579bd896bcd7dc3f106338d0e317b37eec161"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/rpc/messages_read.go:189-216 | internal/rpc/messages_read.go:218-238 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"7135dcdd63315457fe00c0fb23eb9db0b0189d7ca7307ede1614fd779329f251"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 20\u002B corresponding lines): internal/rpc/messages_sticker_sets.go:63-83 | internal/rpc/messages_stickers_personal.go:62-81 | internal/rpc/messages_stickers_personal.go:83-106 | internal/rpc/messages_stickers_personal.go:108-127 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_sticker_sets.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"93fcc0960a5498564c723141660bf3c7238f28864541321aaf531533c4366574"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/store/postgres/channel_message_delete.go:127-151 | internal/store/postgres/channel_topics.go:817-857 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"a454f551182a75e9f2fccf37b6cd67bf5b33b60373d55e8969b154faa460900d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/store/memory/channel_members.go:1030-1047 | internal/store/postgres/channel_member_helpers.go:28-45 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1030}}}],"partialFingerprints":{"codehealthFindingId/v1":"5074cdf496e20cfd2348831cef6d9e15abb362bc02b8c1fd83076e8c502eff19"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/store/memory/message_polls.go:13-25 | internal/store/memory/message_polls.go:27-39 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_polls.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"0289b92cbda50b9fcd87e07339dba60574023fb90c1d15ca887cb094f9a36bbd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/store/postgres/channel_member_list.go:368-403 | internal/store/postgres/channel_updates.go:492-514 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_list.go"},"region":{"startLine":368}}}],"partialFingerprints":{"codehealthFindingId/v1":"2637e570e80ca5c4a7027538f7ac191ed00d8bc5b973d4eb9c8bc76196a77074"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/bots/verifierbot.go:1146-1164 | internal/app/bots/verifybot.go:911-929 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1146}}}],"partialFingerprints":{"codehealthFindingId/v1":"face13fbf7f06d61e873bf6b94a1d28ea42575e1598793f30639afef726351bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/channels_settings.go:117-136 | internal/rpc/channels_settings.go:138-157 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"33ceb5c5b8f14dba84ca5a787671977f03253d8440d795dd2ff5b9e68a8c4aeb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/dialogs_pinned.go:11-27 | internal/rpc/dialogs_pinned.go:29-52 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/dialogs_pinned.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"8dbb30991afbd39762b83d6558409e4237512762ad450bba8acc6d5c7215da68"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 20\u002B corresponding lines): internal/rpc/stories.go:2414-2435 | internal/rpc/stories.go:2499-2523 | internal/rpc/stories.go:2734-2753 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2414}}}],"partialFingerprints":{"codehealthFindingId/v1":"dce14c7bc3bceb8f2a96ab26e207f8428e68a4f5ef301a7f35f3905b494ac4a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/rpc/stories.go:3273-3284 | internal/rpc/stories.go:3286-3296 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3273}}}],"partialFingerprints":{"codehealthFindingId/v1":"eadc6480028d4dbb32344e7d2ede469df4f6d1b50df7e23babdf8658e9948255"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/store/memory/channel_read.go:9-30 | internal/store/memory/channel_topics.go:49-67 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbf58961e4379b3f0e1e728602a3b4d165eb322c249ff7942fedac11977168ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/memory/telegram_login.go:59-74 | internal/store/memory/telegram_login.go:76-91 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"17128eefc805a3e41a4537607fce541cec864da82d00c56d2b2bc539f05b745e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 17\u002B corresponding lines): internal/store/postgres/bot_verification.go:1364-1380 | internal/store/postgres/dialog.go:1164-1181 | internal/store/postgres/dialog.go:1227-1243 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":1364}}}],"partialFingerprints":{"codehealthFindingId/v1":"94dab832e3f18caed9976809d39f6f0c4ba2039cbe8e66f5bad37e648e5bcbdc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 28\u002B corresponding lines): internal/store/postgres/channel_member_helpers.go:109-163 | internal/store/postgres/peer_username.go:80-107 | internal/store/postgres/user.go:732-775 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 28 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_helpers.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"88ea77bd62e6c5910065c46977a381a22714554128a61fef3f934f264e4d789d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 20\u002B corresponding lines): internal/app/files/photos.go:282-305 | internal/app/files/photos.go:764-783 | internal/app/files/photos.go:785-804 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"c838fd68676a83476b68ce1a4883070160ca25a0842bfa5f18c73f7478c3e10b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/account_deletion.go:175-194 | internal/rpc/errors.go:373-392 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"22b46c76e10c0decfaa1fa40118bccd893f05a6957dde0502c0ad26761726feb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/communities.go:45-61 | internal/rpc/communities.go:65-84 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fc683a4148bd9943325442feae705bb309a0f35f8334befbe5a03c530322609"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/rpc/media_count.go:59-80 | internal/rpc/media_count.go:82-102 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/media_count.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e062a0630b19c8da4064095fe6ce9b1f69902401e441fc36d2b475e84f80d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/rpc/messages_reactions_helpers.go:69-92 | internal/rpc/reactions_android_compat.go:60-87 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_helpers.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"42dd4471280a29d2e781da8377a2d343f1d07343bd1fa2d2fee6a52c7b4127e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/upload.go:37-56 | internal/rpc/upload.go:58-77 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/upload.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e02ba1df907f0a2622298f689639f6fd04d69565240fdb724d7d570dd08e2aa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/store/memory/channel_polls.go:13-25 | internal/store/memory/channel_polls.go:27-39 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_polls.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"526bb0889b2cbc2459aea01d55093be8a69d7dfa4718e87c734dda9b21ebb097"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/store/postgres/bot_verification.go:655-676 | internal/store/postgres/bot_verification.go:963-983 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":655}}}],"partialFingerprints":{"codehealthFindingId/v1":"1df99d7c8638f3023f73953ab0c1da580e893439ad79e26465ab3c12ba6c29b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 19\u002B corresponding lines): internal/store/postgres/channel_invite_requests.go:177-211 | internal/store/postgres/channel_member_join.go:300-318 | internal/store/postgres/channel_member_list.go:193-214 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_requests.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bd67a12e58147bbdcff9bbc19b2d50eb73741f9586f1c0824a7109ffff9825c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): cmd/telesrv-admin/donations.go:49-65 | cmd/telesrv-admin/server.go:827-852 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/donations.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"490b0ecaa955f28cbda12cd462fd9ff33ce74166cc09b13a4e7e00ae75e333a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/observability/metrics/registry.go:158-175 | internal/observability/metrics/registry.go:177-194 | internal/observability/metrics/registry.go:196-213 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/observability/metrics/registry.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"c143111c1e0a4192c528cc3b019fc78813ac7e88f3614aa56bf01e21f7cca30f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/bots/verifierbot.go:277-292 | internal/app/bots/verifybot.go:217-232 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"58336ab898c70e3713754bc927045aabf295843b5b081c0cb7e3847b31e2c4d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/app/donations/wallet.go:74-90 | internal/app/donations/wallet.go:99-119 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/wallet.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b4cfa1444ef036df3934869d8d36e0e8b7e130fd6c51521cf62fff22189b351"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/memory/moderation.go:154-171 | internal/store/memory/moderation.go:219-234 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"b715eef618f20b965c0dc4b9eb15e05e63bcda646ef9a857529ab01353426f38"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 18\u002B corresponding lines): cmd/telesrv-admin/botverification.go:253-270 | cmd/telesrv-admin/botverification.go:272-289 | cmd/telesrv-admin/botverification.go:291-308 | cmd/telesrv-admin/verification.go:131-148 | cmd/telesrv-admin/verification.go:150-167 | cmd/telesrv-admin/verification.go:169-186 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"64d9b6ebc9c82d850b732360a1c42f80736f66cd037b7bdebe6ed1cf9cdeba3d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/rpc/account_business.go:121-143 | internal/rpc/messages_quick_replies.go:12-36 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"35d72bf4d6bdcfe928fcf76c445a7d6656e1278a7e34b677572d85262d406e30"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/memory/broadcast.go:218-239 | internal/store/memory/broadcast.go:241-263 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/broadcast.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"073ed3354f14596ff9a07f1e1187413cabcb65086640e2ecda3b77e343a3a1e5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (26 corresponding lines): internal/store/postgres/botapi_update.go:134-163 | internal/store/postgres/encrypted_queue.go:137-162 \u2014 These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d736405bc1837456103fa7846909e0febdb34fd52052afe604a0c480a9b84dc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 27\u002B corresponding lines): internal/store/postgres/channel_helpers.go:701-733 | internal/store/postgres/channel_helpers.go:735-761 | internal/store/postgres/channel_helpers.go:763-806 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 27 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":701}}}],"partialFingerprints":{"codehealthFindingId/v1":"615537e5a19242b25c66290a1f2c1160a58cc64ccf57ed8019444b2f6c9f6462"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 17\u002B corresponding lines): internal/app/channels/service.go:458-475 | internal/app/channels/service.go:478-495 | internal/app/channels/service.go:499-515 | internal/app/channels/service.go:518-535 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ff07866fb08f894faf1798ecc53e23ceb944816afe88654fab516e92df0b791"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/files/mp4faststart.go:210-225 | internal/app/files/mp4faststart.go:228-243 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/mp4faststart.go"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e01bd6e2952feeaf9f5914554b10a7b8472e3047f46fd711da836ddc48e9206"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 21\u002B corresponding lines): internal/app/users/service.go:528-551 | internal/app/users/service.go:555-578 | internal/app/users/service.go:598-618 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 21 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b3b6322a225ed654ce906704c63fd7328e9a6de5e52e367e9bf8f1d1d93e197"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/memory/code_cas.go:23-49 | internal/store/memory/code_cas.go:51-70 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/code_cas.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"f81691b95f5e2d56b3ac6d29fb1297fab2ceff614859321635a7f9bf0cbbc625"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/adminapi/botverification.go:539-561 | internal/adminapi/verification.go:339-361 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":539}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7d55cb1e161fa2a95f391eedbcffdde05f612bf8a85057ede53103e05395af4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/webpage_resolver.go:184-199 | internal/rpc/webpage_resolver.go:201-216 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/webpage_resolver.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca57fd7058e4a92afd65981f0934b518000001f5ce448b51d97a422c026c0a19"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/memory/contacts.go:289-304 | internal/store/memory/contacts.go:343-359 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fd94ed6f936190baa96219c3c235b7a149eac6f2bb8d9d9175e558c4bda0334"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 19\u002B corresponding lines): internal/store/postgres/bot_verification.go:179-198 | internal/store/postgres/bot_verification.go:201-219 | internal/store/postgres/bot_verification.go:223-241 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f75746c2aa1825c36866b95d26089cf615c9e6f3399844ba1667fa1b8177043"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/store/postgres/channel_listener.go:67-95 | internal/store/postgres/read_model_listener.go:228-251 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_listener.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f3eb7c7170792f624ff1071f44268235311b5ab8ecd127e3f923d70cebafb8e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/postgres/channel_read.go:712-728 | internal/store/postgres/channel_topics.go:976-992 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":712}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fbb9a809ba950e9b047c9fa9cf683d820f14af061bf052b0f9360204d4fc319"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/postgres/channel_settings.go:272-291 | internal/store/postgres/channel_settings.go:481-501 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"986de85a97f97f8f6eae782e54b20ae8f773987410f340d2a7a46b75ff9c5eb5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/aicompose.go:42-58 | internal/rpc/aicompose.go:160-177 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/aicompose.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bbb0ebe9e0a51986b24348dc861f77cfbe536496c7807bd245c89e52f583d08"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/messages_quick_replies.go:320-335 | internal/rpc/messages_quick_replies.go:337-356 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_quick_replies.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"23a6925646ad247c24eadeee4ca5bfe4686e40e8bde4c53fc33a7a65928e6b66"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/temp_key_cache.go:44-61 | internal/rpc/temp_key_cache.go:68-85 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/temp_key_cache.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac27c2a5ce7faf0661b0c0c2c377e46f75701cb9c2c1a35337b5bd38ae46086a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/memory/channel_helpers.go:774-787 | internal/store/postgres/channel_helpers.go:929-942 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":774}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a059dae80f912df043c7e725c3100b7b734c3dc4ae0a65d8e3ba04d9e6e8547"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): cmd/telesrv-admin/botverification.go:372-388 | cmd/telesrv-admin/botverification.go:397-412 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"63016bd4aad29ba35eeedef0c51a162fcf87dcaecf5fdb25ab21e9b66dbe9760"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/app/files/sticker_management.go:247-259 | internal/app/files/sticker_management.go:261-273 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_management.go"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"71193bafd5aca26248089be46b582c0a5cdc2ec95c286e05f84f56930ad2da98"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/userprojection/contact_cache.go:686-704 | internal/app/userprojection/contact_cache.go:774-792 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":686}}}],"partialFingerprints":{"codehealthFindingId/v1":"c623caf22fede0c3a58036d69cbb0498ffc8bb2fe5f03fc2d41e97c70389869c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/channels_members.go:950-971 | internal/rpc/messages_polls_updates.go:21-38 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":950}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d3d265e433a111857fdf157119efd9e3a69c6c36c5856da56c5ddb19670e856"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/channel_invites.go:401-415 | internal/store/memory/channel_invites.go:473-493 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":401}}}],"partialFingerprints":{"codehealthFindingId/v1":"c58df4344fa61078500e185bc74452fc20f9d7b652249559edda1f10960f5e3c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/store/memory/channel_updates.go:138-157 | internal/store/postgres/channel_updates.go:466-484 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a94513e2c8d4d2bdd748270ff41650713fff47fb3febb8413f9a6b3211d4c51"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/memory/dialogs.go:253-272 | internal/store/memory/users.go:50-71 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"096cded17991f41f0dd35a44de8d98707e342a93cd34129b1a97e436883d2583"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/postgres/secretchat.go:84-111 | internal/store/postgres/secretchat.go:113-134 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/secretchat.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"6117b0f7a5cbde07bd99cb7ca5c203df2602b22ed44b041645533cd4c9bb0243"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): cmd/telesrv-admin/server.go:1718-1732 | cmd/telesrv-admin/server.go:1824-1838 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1718}}}],"partialFingerprints":{"codehealthFindingId/v1":"4954ed985e7e4f52aab3cb7caf05028b8d83d447a7505cc4470dbd2fc0bdb5a3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/channels/service.go:1736-1751 | internal/app/channels/service.go:1792-1809 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1736}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0b1d6bd05d82891506e9ce36381ce2bc8bc85b3844fb58cc74f03a379493b69"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/hoststats/cpu_unix.go:24-48 | internal/hoststats/cpu_windows.go:24-48 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/hoststats/cpu_unix.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"444f6171462aaeeb67e33d36a2882de08763a13d9739cb4c8d18d7139f481b89"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/channel_interest.go:113-132 | internal/rpc/channel_interest.go:134-153 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_interest.go"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"32c8aecfa888b4c2aee94897de74cda817be333e6e90a447e5c6f8555c9854f1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/send_media.go:939-961 | internal/rpc/stories.go:2020-2039 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":939}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b988b6f0e9a032f493da90b3ba2dd0639e494d0ce030a1808742e3dc86b590e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/postgres/message_send.go:983-999 | internal/store/postgres/message_send.go:1001-1022 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":983}}}],"partialFingerprints":{"codehealthFindingId/v1":"d74808b9f6f436d65a96561cdccf5fe18835b3015cd889e100fe83c241949bab"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 24\u002B corresponding lines): cmd/telesrv-admin/account_rating.go:98-121 | cmd/telesrv-admin/botverification.go:195-221 | cmd/telesrv-admin/verification.go:75-103 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/account_rating.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"de01658f1476d67306a8033119258f1d1965d40e1656ac30aceb4d3aa70f27fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): cmd/telesrv-admin/server.go:1921-1935 | cmd/telesrv-admin/server.go:1951-1969 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1921}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1abb0519b20fb9600161765cc850a448b35768c3450493d74fcf0125334c66e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 24\u002B corresponding lines): internal/store/postgres/channel_member_admin.go:568-600 | internal/store/postgres/channel_read.go:110-138 | internal/store/postgres/secretchat.go:136-159 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1840c006c1eb749075dde2b8adb43e3597da069d8080b3024ba5f6b82ea7c6b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/app/auth/service.go:1118-1131 | internal/app/auth/service.go:1138-1151 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1118}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f36d8d3725a13e9cee95b16887f501106ab4a585790bdb19114b8ac484704c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/bots_inline.go:709-724 | internal/rpc/bots_inline.go:726-742 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":709}}}],"partialFingerprints":{"codehealthFindingId/v1":"98dc05624d4c397d553e152ac32d46ae043cb26224cac410dc33044f971e7209"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/rpc/messages_stickers_personal.go:180-198 | internal/rpc/messages_stickers_personal.go:200-224 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_stickers_personal.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"c86bb5b5a7cf0465011d539d695d20b69d1f28136358fb14755e2c9d8392a9cc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (28 corresponding lines): cmd/telesrv-admin/readstore.go:935-973 | cmd/telesrv-admin/readstore.go:1724-1751 \u2014 These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":935}}}],"partialFingerprints":{"codehealthFindingId/v1":"962305b9edf8f6a1c7c1e148dfb4e71a0d267ec39435e593928b2e749155c328"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/adminapi/server.go:1098-1116 | internal/adminapi/server.go:1374-1390 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1098}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1e64c9ab4458815f876acfd76f7f23b461e9f438be8b19830f33a382b08d45c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/app/bots/verifierbot.go:300-313 | internal/app/bots/verifybot.go:239-252 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad8437cdf31f5b7471ef6273a3d54f0e06b126d43e3c1016045cd9191f946257"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/app/verification/service.go:538-556 | internal/app/verification/service.go:590-607 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":538}}}],"partialFingerprints":{"codehealthFindingId/v1":"5beb0415891aca1789b4beee443144006bf5e8b39cfe7d85129109bed3d51d49"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/mtprotoedge/bulk_rpc_scheduler.go:168-190 | internal/mtprotoedge/outbound.go:1137-1159 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/bulk_rpc_scheduler.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"db792360ee2bc9bf5fd32cd64a31f8e33b0477e5e77f9c10c4c22202b8aa9f69"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/store/memory/community.go:184-204 | internal/store/postgres/community.go:310-331 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9241aa353e2ab597bf7834117d9e79ff3ecf34a598956138be5aaf5170a52ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/postgres/authorization.go:489-508 | internal/store/postgres/authorization.go:514-542 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authorization.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8175f8eca205e4a2f32c86cda9e9815f6f06e278f03d41a1464ed34e7434304"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 17\u002B corresponding lines): internal/store/postgres/channel_reaction_unread.go:212-232 | internal/store/postgres/channel_read.go:689-710 | internal/store/postgres/channel_topics.go:958-974 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"7672d604773b8714ca85d7f7e1dfee9d4eef8301d1b32f159717e52042e9bdc2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/store/postgres/star_gift.go:389-407 | internal/store/postgres/star_gift.go:409-427 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":389}}}],"partialFingerprints":{"codehealthFindingId/v1":"badcadbcf0f13cb6f8790f240928503b649c0f9b94ab45c11aa8f26307ee4c6a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): cmd/telesrv-admin/premium.go:27-47 | cmd/telesrv-admin/server.go:1071-1091 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/premium.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"b207055ae4a8d08b43fe1a31e511186acc106b9e46c8d9e4e86b7d7867a0f346"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): cmd/telesrv-admin/publicbranding.go:44-64 | cmd/telesrv-admin/serversettings.go:91-107 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/publicbranding.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"4eff296a88829151d0891b78ce6c45a775350d433f065f736755eb44d570d107"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/app/stories/service.go:351-363 | internal/app/stories/service.go:365-377 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"f680c4c5850539f001906490fe5b494db5ccc593a5ab4c6c6a36a46902a22071"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/userprojection/contact_cache.go:666-684 | internal/app/userprojection/contact_cache.go:754-772 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":666}}}],"partialFingerprints":{"codehealthFindingId/v1":"38d04114da78a4f614ddfa9a37b26c2f0271f26771873ccfa63e25aeb7ce6f72"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/compat/tdesktop/appearance_seed.go:148-171 | internal/rpc/wallpaper.go:190-216 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/appearance_seed.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbd9e40959aaca15d2bf653b259638072444a383ffdcfb6c1a64fe00318ffeed"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/bot_verification_projection.go:183-202 | internal/rpc/fragment.go:391-407 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"57db9c3228a8628ba1e14833e6343031474cfd5af0f0fa8a7c24774eb4162b63"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/stats.go:50-66 | internal/rpc/stats.go:68-84 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"09139d9809c56251d8b40861336a9b0115a2775b06591eec646fe297fe4fc4f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/memory/botapi_update.go:127-143 | internal/store/memory/botapi_update.go:201-214 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cde2dee1138a46eacb0b20ea2bf69c3bc2501f4f23be53203794910c249a290"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/store/memory/channel_message_history.go:652-669 | internal/store/memory/message_history.go:458-481 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":652}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7968c6d082c47f8bc2de35d50e461eacc7ca90259f3f30b894b3098a918c150"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 17\u002B corresponding lines): internal/store/postgres/ai.go:182-198 | internal/store/postgres/ai.go:200-217 | internal/store/postgres/themes.go:57-76 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ai.go"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a2411160f7f56c8117cd5aac8cc3fc88ff05beeb11f5a2a84020369a4835db0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/store/postgres/star_gift_lifecycle.go:1299-1317 | internal/store/postgres/star_gift_upgrade.go:629-662 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1299}}}],"partialFingerprints":{"codehealthFindingId/v1":"9583e44e62c18c0d510c890b4f3a8b7b1cea03bd11c722501a81609c7f56dc02"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (23 corresponding lines): internal/mtprotoedge/logical_session.go:19-41 | internal/mtprotoedge/logical_session.go:46-76 \u2014 These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/logical_session.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1937bab2f3803a24954cdae1feff7b3539fafd8c3a24789a861d7cf2c982e17"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/store/postgres/authkey.go:56-75 | internal/store/postgres/authkey.go:81-99 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"099ec80517867bf1eb45302faed75266733e67b58e13c8e764572b8a571e5234"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (32 corresponding lines): internal/store/postgres/authkey_session_layer.go:20-51 | internal/store/postgres/authkey_session_layer.go:119-179 \u2014 These two members are one piece of code written twice and then edited apart: 32 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_session_layer.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"32ceee5d36e8c38e91faba8ab2b6a3cf0d8bd0c8ac0b020a50e99f135d5e30e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/store/postgres/themes.go:173-193 | internal/store/postgres/themes.go:195-215 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/themes.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"44f289153f77563a120cd55f4c839a6ab2b71a6c361bd06b4fae14e677505921"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 17\u002B corresponding lines): internal/app/channels/service.go:1051-1070 | internal/app/channels/service.go:1115-1131 | internal/app/channels/service.go:1268-1287 | internal/app/messages/service.go:510-526 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1051}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd3d85ca28a49eb3dc6a3d856910c467270ea07273c1ed2a61e1717ea3fac483"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/account_business.go:145-164 | internal/rpc/account_business.go:166-188 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"15ee6b1ea10d5807efdd49e078dd37a7f7660779120ae057e0435ec71c0cdd6a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/memory/ai.go:28-43 | internal/store/memory/themes.go:34-53 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ai.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"314375f366d30d69aae0b7dfd234a576bb92d2f4bb1dddd31819b3480f257527"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/store/memory/auth.go:493-512 | internal/store/memory/auth.go:528-546 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6dfddee5d9854dc4ac1c88ad8d8db3dd35d4c7fd12da5e5aeab6a9bdc25bb82"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/memory/stars.go:67-81 | internal/store/memory/stars.go:83-96 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/stars.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"52938335fcc1f71ef688a30c1537fa7aeb4d385c4440d18d8019ece84838819c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/postgres/channel_helpers.go:544-565 | internal/store/postgres/channel_read.go:236-273 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":544}}}],"partialFingerprints":{"codehealthFindingId/v1":"1796960e96ace32d3152a5acb8cf34a05849bda9e75372adb3556324c2c66ab6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/store/postgres/channel_reaction_unread.go:164-177 | internal/store/postgres/channel_read.go:641-654 | internal/store/postgres/channel_topics.go:918-931 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"df0f0a30a95383ef6158d7c782a625c397f1c739355db196bcd852fab7acc8f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/channels/service.go:1475-1490 | internal/app/messages/service.go:184-199 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1475}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e46c7705d1770bcd39a9abac6e7ac3ec9b73bd94ee572ae0dcab29795fa39ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 20\u002B corresponding lines): internal/compat/tdesktop/dialogs.go:54-78 | internal/rpc/stories.go:2906-2930 | internal/rpc/update_peer_refs.go:549-568 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/dialogs.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca01bdafed8a98f54a8a96d8e031daecad050b8bc0a8f39a4dd58cac0dcdf1e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/loadharness/dataset.go:430-446 | internal/store/postgres/dialog.go:1287-1304 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b2a277639a856a7ea033b46c23c0c6159183339dfe61fb112abb0612bd135cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 24\u002B corresponding lines): internal/mtprotoedge/outbound.go:1936-1961 | internal/mtprotoedge/outbound.go:1964-1989 | internal/mtprotoedge/outbound.go:1992-2015 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1936}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ef0f564c4f47138229f3cb1793971be22b0d8af339cf777ab00390dcff75e78"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/rpc/channels_invites.go:191-212 | internal/rpc/channels_invites.go:287-305 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"81f54b50fda36a664dda8b871f6965a6a1020d5598a7e0f33b8f0c2ac0dfd166"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/postgres/contact.go:45-61 | internal/store/postgres/contact.go:679-701 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"be1fc19f9c82d11928862c109b3832b8355b52031a7aba896932f9a59f948568"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/app/bots/stickersbot.go:187-203 | internal/app/bots/stickersbot.go:205-223 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"49538293190c50e92a769854f3a745ba7d9db4a7f2fdd39753edcac4c802bcba"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/bots/verifierbot.go:1275-1293 | internal/app/bots/verifybot.go:1037-1055 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1275}}}],"partialFingerprints":{"codehealthFindingId/v1":"594faf40f7e0760271394dd26d0d5b575053d82f8cda784e1e039a072ae06cd5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/files/retention.go:499-517 | internal/app/files/retention.go:521-539 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb6c8a5765479810d732175136aebc6162baa7ef473c6eb5639a519fac3d3a9f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/app/messages/service.go:468-479 | internal/app/messages/service.go:482-493 | internal/app/messages/service.go:496-507 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"998adb49adf3b2550f5f0c82a7812019a998e2fee699376d06630580fbbb3c84"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/rpc/account.go:668-689 | internal/rpc/auth.go:746-764 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":668}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd0f023318f5847cc11a08547cb105c5837fbb4328a7fd59ff51299543e99d79"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/rpc/story_peer_projection.go:35-45 | internal/rpc/story_peer_projection.go:47-57 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_peer_projection.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fcbb1f7104a02bbc03b01dad7e53f641722eedc2e2737ec840c936c08750b0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/memory/ai.go:45-64 | internal/store/memory/themes.go:92-112 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ai.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3f842ab12e8670929b62196891c5376f91577e849aa85359081f5a5cd892121"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/memory/collectible_username.go:222-241 | internal/store/memory/collectible_username.go:246-272 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/collectible_username.go"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"d78f08e5a936c7a584e1a57e7685ec0bd972abc6494d4e5f41f0bdfdae6e5e78"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/postgres/botapi_update.go:165-186 | internal/store/postgres/botapi_update.go:248-273 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4a367b777d473f2135b5609772ec30d7fc64a68f9744bad0cd8214fa078be6a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/postgres/business.go:380-402 | internal/store/postgres/business.go:442-456 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/business.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"d90a1a7febf1888961cb814aee77c8bf8bc51309c487e0045229223010a1d606"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): cmd/telesrv-admin/star_gift_catalog.go:407-422 | cmd/telesrv-admin/star_gift_catalog.go:434-454 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/star_gift_catalog.go"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe524a5478ef2e6092e68d02cad1298540982c43be31ec1c9dac62ad138c1ec7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/app/userprojection/contact_cache.go:265-283 | internal/app/userprojection/contact_cache.go:577-595 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"a57c64917261c5e683c38e71a4fcc56693abe5e6065b2b59ebd6779552900386"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/messages_sticker_sets.go:233-247 | internal/rpc/messages_sticker_sets.go:249-263 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_sticker_sets.go"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c6bf6072a2bdb774bc5e20a226b90cdcea879341adedfd5f1889b1667ddccea"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 19\u002B corresponding lines): internal/store/memory/login_code.go:130-148 | internal/store/memory/login_code.go:150-171 | internal/store/memory/login_code.go:173-191 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"97491bfb2a71c7bc8667405f0935f4bb264e5dae796d800c1b203c2fde5bb1e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/adminapi/account_rating.go:121-135 | internal/adminapi/verification.go:234-250 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/account_rating.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7a5c62d39d551d99e4106dd3e0cf8fd9580dfc4c197a8b141d7b65b5c96d2a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/app/channels/service.go:1955-1968 | internal/app/channels/service.go:2173-2190 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1955}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba60c0852c8c029459304abdff78f150b136fd8b9326f612d33efe25e0659cac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/rpc/bot_verification_notify.go:85-107 | internal/rpc/username_notify.go:47-64 | internal/rpc/verification_notify.go:99-117 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_notify.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4f69bb5226f79358b44ef2d5d6649fefc869308703afd50099f99f2b43e8bab"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/store/memory/secretchat.go:97-115 | internal/store/memory/users.go:385-405 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/secretchat.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"37359522d6386b994289248d465bb4d98c5303c5cd5ee90e732e3311bef0f5d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/app/telegramlogin/service.go:1027-1041 | internal/app/telegramlogin/service.go:1048-1066 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":1027}}}],"partialFingerprints":{"codehealthFindingId/v1":"325c108cff498cdab2d5548940c8c90eef3ccfaa844614597c0c27ee174ae529"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/webpage_resolver.go:218-235 | internal/rpc/webpage_resolver.go:237-258 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/webpage_resolver.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"caad5938461605401f8f147870604d42b0f6f7d0745a8b5ad9cc1ede3e94e9b5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): cmd/telesrv-admin/readstore.go:895-933 | cmd/telesrv-admin/readstore.go:1754-1778 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":895}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb7de9a73027ce9776e62366645d8a3d78b713dedc4b35e322e8e5d293df1e65"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/botverification/service.go:1244-1259 | internal/app/verification/service.go:1224-1239 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1244}}}],"partialFingerprints":{"codehealthFindingId/v1":"08871ba7989e373ea2222f2fff0a708b4a1f8a38a02d9c95cd5e563b02f1acdd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 18\u002B corresponding lines): internal/app/peerview/cache.go:147-164 | internal/app/users/service.go:942-962 | internal/rpc/channels_stubs.go:407-424 | internal/rpc/peer_projection_cache.go:261-278 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/peerview/cache.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"28d38a6e3fb7cddcdc7688b9745f299fad161abf50a47d533fc670ef3a42111e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/channels_messages.go:55-73 | internal/rpc/messages_read.go:76-93 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f937843b05b18ed25291bf9e83cb54654d7c3fbc41ac4553500ed5995ab91a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/messages_reactions_catalog.go:16-37 | internal/rpc/messages_reactions_catalog.go:39-55 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_catalog.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"03e3bbd30ca088332e0cc9095fb2b3005468d7de61188c5fae1410a9ec3b35c5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/message_edit.go:114-128 | internal/store/postgres/message_edit.go:290-305 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_edit.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bdf2270d56cfef891822b76b5a15a85be994688392189ae631e98e271c8d93f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/memory/story.go:1339-1349 | internal/store/memory/story.go:1383-1396 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1339}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce8af6c70d028ea11644ae489ab5e1b48544e9ea840f9be8c9059b839dc5a868"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): cmd/telesrv-admin/server.go:1743-1755 | cmd/telesrv-admin/server.go:1849-1861 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1743}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9ff975113262f01a26fe83adba68a0ca20be38f6006f707f7ad276a57283a8b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/app/channels/service.go:1370-1386 | internal/app/channels/service.go:1557-1571 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1370}}}],"partialFingerprints":{"codehealthFindingId/v1":"8160aece7761a0c5fab11833f9e6ed96de70f665b5c8b48c00340895917eb7a2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/rpc/ephemeral_push.go:17-40 | internal/rpc/inline_push.go:15-36 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral_push.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec7ef021c67ef808ef85536fa5ba27873932ab549b3793792e8237d6d0b18e81"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/memory/langpack.go:210-218 | internal/store/postgres/langpack.go:385-393 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cc23ae201f2a6e9c61eaeb3ac87bd216e4c69130e66be30c9658203584dae3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/store/postgres/channel_listener.go:40-63 | internal/store/postgres/read_model_listener.go:203-226 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_listener.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ddcfbd7ed532313678d93a33c949eb34bcb9ed54a6b5b52e80419300a11c0d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/app/account/business.go:469-486 | internal/app/bots/service.go:583-600 | internal/rpc/phone_group_call_updates.go:218-235 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/business.go"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"204d20b4a3c117dabf1d80213bce818f910a05529e7a41fa02e1d6fb6d3334bf"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 17\u002B corresponding lines): internal/app/files/external_media.go:116-132 | internal/app/files/maptile_proxy.go:290-306 | internal/app/files/webpage.go:142-158 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e39c7bb62f33dda79b0bfb99f47861a7d386a2e66d9804891ae72832501f242"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (24 corresponding lines): internal/app/moderation/legacy.go:83-106 | internal/rpc/messages_helpers.go:38-61 \u2014 These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/legacy.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"c54f36b6bad698fee0dc3496d6d313f4fe58e7df5e0716240004e9e04804b4cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/telegramlogin/crypto.go:49-61 | internal/app/telegramlogin/crypto.go:63-74 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/crypto.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef4f8cda684bb796ebf7d155d743b847b994049b3f0251a77ecfc9ea68ad185c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/loadharness/mutate.go:691-711 | internal/loadharness/mutate.go:713-734 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"db790007323a74f66c6cb59dfcbe9b075e21dcede0c7ac8f1755710f2ae335a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/rpc/auth.go:982-995 | internal/rpc/auth.go:998-1009 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":982}}}],"partialFingerprints":{"codehealthFindingId/v1":"14e35f9c7286cc3b392f63addc6c2ab81099f9a27f37344b9022a1944c848a8b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/messages_no_forwards.go:117-133 | internal/rpc/messages_send.go:598-619 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_no_forwards.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"0013d6fe2d85ed8afedcd219411608375d1eedea7a7e13c441853480ad32c44e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/postgres/phone_identity_migration.go:28-47 | internal/store/postgres/postgres.go:123-146 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/phone_identity_migration.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc46fbd83b99c9eb0960ea8d0ae300a44125bfc6806c44466207d6fc8555782b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): internal/app/channels/service.go:1679-1695 | internal/app/channels/service.go:1821-1836 | internal/app/channels/service.go:1839-1856 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1679}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd70232b342a5a09c2777aa8120fd1116df69042b71e4d745eb9d7bfd106dcc3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/app/rating/worker.go:49-69 | internal/app/verification/worker.go:46-66 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/rating/worker.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8338e6bb5451e0f821fafa3b52543177f1a159cf912d69d25622094a791e6f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/mtprotoedge/bulk_rpc_scheduler.go:60-81 | internal/mtprotoedge/outbound.go:1078-1099 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/bulk_rpc_scheduler.go"},"region":{"startLine":60}}}],"partialFingerprints":{"codehealthFindingId/v1":"7036ef712641389c19c28648d739500ba54e214d3fbc1c793a423ffc5f458553"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/rpc/aicompose.go:122-139 | internal/rpc/aicompose.go:141-158 | internal/rpc/aicompose.go:179-199 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/aicompose.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff56a73da9313f375f9792f4f4c13a70880df42452c38b14d11dcc9590140229"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/bots_longtail.go:398-415 | internal/rpc/bots_longtail.go:630-647 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":398}}}],"partialFingerprints":{"codehealthFindingId/v1":"acb4cc49135e80d1cd40a98b0bcbbfd79a186793bd8cab6cb294de5e61cfc137"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/rpc/contacts.go:110-129 | internal/rpc/messages_quick_replies.go:95-115 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff7d41601d56348fbadf9ac11fb66cf05f1d413df5c6faea8c103293ce6ec3d8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/messages_games.go:16-31 | internal/rpc/messages_games.go:46-64 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_games.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2bd27fda869fed4bc0e78a4d84243d7c496bd4715ce11791ab73bc701f50da3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): internal/rpc/stickers_creator.go:167-182 | internal/rpc/stickers_creator.go:184-202 | internal/rpc/stickers_creator.go:204-222 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers_creator.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"758a3af5822eaf1ff6834663b84c880e5e5c3fbae26a83e2c20efccde436bd77"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/telegram_login.go:393-414 | internal/rpc/telegram_login.go:416-431 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":393}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2075328e62dc8ebb7f1ada4e5c6c3c91093548b8d7a5716c43fd30d87b3b2ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/store/memory/auth.go:117-136 | internal/store/memory/auth.go:419-442 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ca0f693c0ee534f22a894ac4d06a07ea795772c9279393c6febe170ee126018"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/postgres/media_index.go:18-31 | internal/store/postgres/media_index.go:72-85 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_index.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bbf4123fc76803104ef8e70a535ce133d0571959e7a92b00e32f60f631f2125"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/postgres/telegram_login.go:124-140 | internal/store/postgres/telegram_login.go:142-157 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"c822eb2e38a940e6816f62feadae13e25feb3b5308131e5c3e901b3fed7a13e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/channels_settings.go:180-194 | internal/rpc/channels_settings.go:324-344 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"1282cae873d54b371beebba571f9a22e93d58d482642b627118c2971c60d10ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): cmd/telesrv/main.go:487-496 | cmd/telesrv/main.go:551-560 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":487}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b781d36e491c644c786302aac1f99161a2eeac6d162d11a7acb77f12fc3c0b6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/mtprotoedge/session_manager.go:1514-1536 | internal/mtprotoedge/session_manager.go:1570-1587 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1514}}}],"partialFingerprints":{"codehealthFindingId/v1":"193ace686e8e5c71d1992d062dc912380c64b7c563da523bd1d1251f2d2406fb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/rpc/premium.go:34-47 | internal/rpc/premium.go:74-87 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/premium.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"b20365da97785eb7dd0727b88fade46cec59f2bdbe88a1bcc8ec1a2709b2373d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (21 corresponding lines): internal/store/memory/channel_invites.go:871-891 | internal/store/postgres/channel_invite_exported.go:555-575 \u2014 These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":871}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7fabf61b4c1eb2ead2341fc2ca062025e5002908a3af6061f60822688ae30dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/memory/channel_stats.go:300-310 | internal/store/postgres/channel_stats.go:492-501 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"728db7291dc8cca483f09ba963f1f7dbebcd250aa86d600ce8a4531edd41cea5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 13\u002B corresponding lines): cmd/telesrv-admin/serversettings.go:117-130 | cmd/telesrv-admin/serversettings.go:279-291 | cmd/telesrv-admin/serversettings.go:308-320 | cmd/telesrv-admin/serversettings.go:340-353 | cmd/telesrv-admin/serversettings.go:392-408 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/serversettings.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"101264f6725289cd1ae2e24038b36cd8b18ebdafa169aa227d8d688e639ff536"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/app/contacts/service.go:460-473 | internal/app/contacts/service.go:475-488 | internal/app/contacts/service.go:490-503 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"9bf84ba618a5ec934facba1ebe59b975311c6c725bce6f21484387dfa2f282f2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/app/moderation/evidence.go:647-664 | internal/rpc/messages_send.go:356-373 | internal/rpc/messages_send.go:375-392 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":647}}}],"partialFingerprints":{"codehealthFindingId/v1":"a64839f98596b05c0cf4cb758b17cb6c4f638e6e10d90aa59a9270d8c41a94d1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 16\u002B corresponding lines): internal/rpc/account.go:1673-1691 | internal/rpc/account.go:1697-1712 | internal/rpc/bots_longtail.go:87-107 | internal/rpc/bots_longtail.go:109-129 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1673}}}],"partialFingerprints":{"codehealthFindingId/v1":"774788fe9e2cd7ddee5d555120dc6757dbeb4a253156bf75edac04ae3d09d8f2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (7 members, 18\u002B corresponding lines): internal/rpc/account_business.go:21-39 | internal/rpc/account_business.go:41-59 | internal/rpc/account_business.go:61-79 | internal/rpc/account_business.go:81-99 | internal/rpc/account_business.go:101-119 | internal/rpc/messages_quick_replies.go:54-71 | internal/rpc/messages_quick_replies.go:73-93 \u2014 These 7 members are one piece of code written 7 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 7 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e3c7adb9431053d7b0b127745c7925893dc49ca66929cd7aaf64f777645113d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/bots.go:256-270 | internal/rpc/bots_longtail.go:21-35 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"24611f2899353b26fd5c986186cf6b6c4615043efffde299b8c7e6bfdede3882"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/rpc/channel_fanout_dispatcher.go:1027-1037 | internal/rpc/channel_fanout_dispatcher.go:1131-1141 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1027}}}],"partialFingerprints":{"codehealthFindingId/v1":"56afda217b0efc9f1de68cbc5f5b831024c3cd93c7a6ad51b099992752a13d96"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/rpc/messages_dialogs.go:301-310 | internal/rpc/messages_helpers.go:588-598 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"c2803d61cd7c47636ee72f9b40505690312e432469317869b0ebf5c6b56fb951"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/messages_history.go:132-149 | internal/rpc/messages_reactions_helpers.go:50-67 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb3108c4d4aa8aa29a2afb7de671502525cef6c9cdbc11c9ae28d38d095e5a41"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/postgres/donations.go:135-153 | internal/store/postgres/donations.go:192-207 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/donations.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"44cd98e1a41ab43089ee3caa17790e55c249a48869b445618dff449d57bed2fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/domain/verification.go:348-364 | internal/rpc/messages_bot_no_state.go:52-70 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/verification.go"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccafb4732c0131937fe4e9349cf56e7bdf1ae0bef5cb89f06c2290681d147e78"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/convert_polls.go:322-336 | internal/store/memory/groupcall.go:609-623 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_polls.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0c655d06ffe4cbe08d966de99dbc3a65998fcef157679eddfe427cdcd65275b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/memory/telegram_login.go:194-205 | internal/store/memory/telegram_login.go:263-277 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"212026f4ba873a683013862597359e079e3b6deb801fc15a55e220f364deab1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): cmd/telesrv-admin/server.go:1466-1479 | cmd/telesrv-admin/server.go:1490-1503 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1466}}}],"partialFingerprints":{"codehealthFindingId/v1":"803e902888b0ee1355d89e731eda4766e73a6ef4b0e62adf01ab04bd67f07f9a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/adminapi/botverification.go:440-451 | internal/adminapi/verification.go:267-278 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":440}}}],"partialFingerprints":{"codehealthFindingId/v1":"97b37c80f811f133667e9ddc6383f30e6fd4abd0b4ee6c55d6b203cea6b049bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/bots/service.go:552-567 | internal/app/channels/bot_policy.go:69-87 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"83159e9a91ef1fc86207cf80ec3812ba24ce6de1ac5646d8ffe7dce62d27bce3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/app/moderation/evidence.go:580-590 | internal/app/moderation/evidence.go:592-603 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":580}}}],"partialFingerprints":{"codehealthFindingId/v1":"66eb008aed38b9553f37c11b1c4c0bdf308e3b6b4f291b556e8746c96d22f5f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/rpc/welcome_messages.go:66-80 | internal/rpc/welcome_messages.go:82-95 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/welcome_messages.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"5de2d1fd76741a6dc24f93232f2029fe9fa620d364f31f4f40784b00bc9c2f6b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/memory/client_telemetry.go:84-93 | internal/store/memory/moderation.go:311-320 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/client_telemetry.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"83c6a48ae4a8cae71baca47aa3c2944ccb0f0c7dfac0b94481d90a9a72dc1e7b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 23\u002B corresponding lines): internal/store/postgres/auth_delivery_report.go:130-152 | internal/store/postgres/client_telemetry.go:88-110 | internal/store/postgres/moderation_cases.go:648-670 | internal/store/postgres/moderation_registries.go:268-290 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 23 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_delivery_report.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"4645e5f7c70e8e18bfa123319c8569d8f1650c804809a7291b5ed95a1cdb34bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 17\u002B corresponding lines): internal/store/postgres/channel_read.go:881-905 | internal/store/postgres/groupcall.go:1034-1071 | internal/store/postgres/groupcall.go:1236-1252 | internal/store/postgres/star_gift.go:47-67 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":881}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a55ab8112c0a8ee9eadb878430be5f4b2bbfdeef64010b4dcb0b0309cd84c17"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/star_gift_craft_auction.go:33-42 | internal/store/postgres/star_gift_upgrade.go:258-272 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f18dc0be5cbe628414557aac4d99bc37e7915fe5742e450b975a4e625487949"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): cmd/telesrv-admin/privateview.go:127-140 | cmd/telesrv-admin/privateview.go:619-632 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"e89097609c733a97ab6dd5a3e88efbc65794c8d66921ac4a1cc34e629aaa3ce9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): cmd/walletminiapp/main.go:364-372 | internal/rpc/messages_webview.go:727-735 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"bffd244d8512864c356d2f77a27746ef9b14ff47ccf39233b86f265da7c5f7d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 12\u002B corresponding lines): internal/app/channels/service.go:1073-1084 | internal/app/channels/service.go:1087-1098 | internal/app/channels/service.go:1101-1112 | internal/app/channels/service.go:1134-1146 | internal/app/channels/service.go:1193-1208 | internal/app/channels/service.go:2302-2314 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1073}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c8e38cf83fa9fb13773150b085b9057c836819c728f4404a9907a16bd5866ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 14\u002B corresponding lines): internal/mtprotoedge/transport_ownership.go:132-145 | internal/mtprotoedge/transport_ownership.go:149-165 | internal/mtprotoedge/transport_ownership.go:173-189 | internal/mtprotoedge/transport_ownership.go:376-392 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/transport_ownership.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"703003d57691ced86b007e7307019454ef8916d8e7337f2be97156ee263dbe76"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/account.go:1649-1664 | internal/rpc/contacts.go:964-984 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1649}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c3841584f8cf231a65ddf80f01e1f80f9bfc1ce35a40452715f96c86da69dd0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/messages_forum.go:531-543 | internal/rpc/messages_forum.go:545-559 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"9310f26b543ecd7bcf332626b6eb120be695607a09f6dd449c23567313da526b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/updates_delivery.go:163-180 | internal/rpc/updates_delivery.go:237-253 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/updates_delivery.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"86cfa28f7f2edfb9c85c67063a90b5caed4688d795e34ed788a4ae53f2c94e11"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (35 corresponding lines): internal/store/postgres/channel_read.go:54-108 | internal/store/postgres/channel_topics.go:80-114 \u2014 These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"60adf2e84fa191396395c55c2db8284dbf9f234a05b240b438df9dd1f3345c93"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 15\u002B corresponding lines): internal/app/dialogs/draft_read_model_cache.go:102-116 | internal/app/dialogs/read_model_cache.go:305-319 | internal/app/dialogs/read_model_cache.go:321-335 | internal/rpc/story_sparse_projection_cache.go:202-216 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/draft_read_model_cache.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"700abc6df6e69f3b085bcbdcc3424154d3c1eb3c8b2b308eed060d09ed16df44"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 16\u002B corresponding lines): internal/loadharness/dataset.go:335-353 | internal/loadharness/dataset.go:365-380 | internal/loadharness/file_fixture.go:85-100 | internal/loadharness/snapshot.go:695-710 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"00606f5819458b44de922d9bcfb9b7b6f35830543ef8b71b717ec32bf80f180f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/rpc/messages_read.go:165-175 | internal/rpc/messages_read.go:177-187 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"c75a419aa65b6f312c924ff9095f881b80155e38db623fb9ef0dcbc507b0b16f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/send_media.go:1151-1166 | internal/rpc/upload.go:369-386 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":1151}}}],"partialFingerprints":{"codehealthFindingId/v1":"01a6f380a5e58e91988bc0b3e7b17e37b95c0780d6fc43e30bdb48de157a1d29"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/stories.go:2720-2732 | internal/rpc/stories.go:3115-3127 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2720}}}],"partialFingerprints":{"codehealthFindingId/v1":"48e7abdd1c833485b6e01a0ab98e62de7cab0a8aa98596dd89858d538d12d944"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/memory/bot_verification.go:465-481 | internal/store/memory/collectible_username.go:141-162 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":465}}}],"partialFingerprints":{"codehealthFindingId/v1":"804a6cc8aef1d1a89cdcd3acbc9acb507555deecf1441ce3ecae4edd97d47a32"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/store/memory/bot_verification.go:964-981 | internal/store/postgres/bot_verification.go:1294-1313 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":964}}}],"partialFingerprints":{"codehealthFindingId/v1":"45ad35f67493641ec448a6c7f51c45979036ad1a27dbeb16d62462156443f2e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/memory/moderation.go:173-186 | internal/store/memory/moderation.go:677-688 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"0414f88d593770b5461fe679fbde902e5d7283840cbae93e674b6fc90d1ff263"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (30 corresponding lines): internal/store/private_send_idempotency.go:89-118 | internal/store/private_send_idempotency.go:122-152 \u2014 These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/private_send_idempotency.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"007c738462dbb2a85f4e31d7a1740c530f4f56c592e01c2e4dc7d0dbe1ed66c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): cmd/telesrv-admin/admin_command_runner.go:236-253 | internal/admin/service.go:4023-4043 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/admin_command_runner.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc43d289c834bcf9b3c905270c861b2439b4a14161b114f551809adc8584702a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/app/files/appearance_seed.go:243-263 | internal/compat/tdesktop/appearance_seed.go:206-219 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"765d5992136627df814e3239934826d04086303bf93f4a4a1674faec68e36e67"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/rpc/convert_business.go:11-30 | internal/rpc/convert_business.go:32-50 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_business.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"37ef034ccd97d758cd5b1d42168303be4fc3eb9ec746440c754d3000929c39ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/bot_verification.go:169-183 | internal/store/memory/bot_verification.go:286-304 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bbd248d4e1964d7bda48f4f9f5bd934e87e0006cbeb83c557caada130b71d52"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/store/memory/collectible_username.go:598-610 | internal/store/memory/verification.go:591-604 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/collectible_username.go"},"region":{"startLine":598}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ad9ac812a003ae1faea5b49fa07c74ef6d1ec43f27ec2b86bc500d9a7d60c3d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): internal/store/postgres/story.go:1828-1845 | internal/store/postgres/story.go:1847-1862 | internal/store/postgres/story.go:1864-1880 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1828}}}],"partialFingerprints":{"codehealthFindingId/v1":"2100cb93c796b4f2176e9f1c142b436144d58d447ab574e767d84e2fa8e5e980"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/botverification/service.go:1441-1452 | internal/app/verification/service.go:1287-1298 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1441}}}],"partialFingerprints":{"codehealthFindingId/v1":"512d55f05dc9de0d35b96cd75403c681db7862b152d69ee2db0cbfcc8aafda21"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/app/dialogs/read_model_cache.go:450-463 | internal/app/dialogs/service.go:1340-1353 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"116ab44aaf4c373126d448f8c7dc8aace882842f94ee786d5ac461d190ad9dfa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (25 corresponding lines): internal/app/messages/business_automation.go:324-348 | internal/domain/business.go:269-302 \u2014 These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":324}}}],"partialFingerprints":{"codehealthFindingId/v1":"24a8bfc2d75f7683949708addb647f8d1cbd150e96af6187d26ce49591e59f2a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/domain/moderation_registry.go:28-44 | internal/domain/moderation_registry.go:103-118 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation_registry.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"35e3eca4f28003df49bc1bec27702cb9ad573d01330f5d9e130d6451769ee713"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/mtprotoedge/logical_session.go:119-138 | internal/mtprotoedge/logical_session.go:163-179 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/logical_session.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"1434f05438ffd72e0d6516e06b9334a192f981c3629720eb178fcb74ba7e07fb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/messages_dialogs.go:1159-1173 | internal/rpc/premium.go:325-339 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":1159}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9abdff49a0ce4402bdd5d60552c87f3d3723b594985541fc3db4b318a4efe89"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/rpc/payments_star_gift_lifecycle.go:287-295 | internal/rpc/payments_star_gift_lifecycle.go:347-355 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9dd99f653bb68c68b1e559bd30b96eec9c71f64f556b6d4aeacacc35f7d97c5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/memory/business.go:386-399 | internal/store/memory/business.go:401-415 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/business.go"},"region":{"startLine":386}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc5d017e9f3c7997af3a05afb9cba6c0c5c56908445b350e9d97bf9e7e8f65c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/postgres/bot_verification.go:620-635 | internal/store/postgres/collectible_username.go:162-177 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7c955150ceaec839c0b4c335f03522a2eb17eb9c1a3a029c81693cf89e6cb73"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/postgres/message_helpers.go:316-345 | internal/store/postgres/update_event.go:879-895 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_helpers.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"a47a04366a0d8bfb0798ed4f3d0f5505a1b45cb8a9ce3ea2846da88a2892140e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/channels/service.go:1500-1516 | internal/app/channels/service.go:1543-1554 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1500}}}],"partialFingerprints":{"codehealthFindingId/v1":"06d25f602ae9f087ffbd02b4eafab0587191547daded3e7b525c47d4a044488e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/app/files/service.go:709-721 | internal/store/postgres/media_search.go:95-107 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":709}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffe63b7a33114dd359eef33832963269c1be613465c02aed79dfb16ec7b985d7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/app/telegramlogin/jose.go:215-231 | internal/app/telegramlogin/jose.go:236-252 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/jose.go"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3efdadab6eeb34ca57f6c99557291d44417be861038e52c2eb82dffe19b4d5d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/rpc/account.go:1520-1533 | internal/rpc/account.go:1535-1549 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1520}}}],"partialFingerprints":{"codehealthFindingId/v1":"d078a0633c6608d9c9685d3e32a7d300e636e2a88ab2baa4b41051793e78161e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/account.go:2050-2064 | internal/rpc/account.go:2066-2082 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":2050}}}],"partialFingerprints":{"codehealthFindingId/v1":"71d1109db5f21ee573dfe75eb2790d666afd318e1257648804689128a2b9dd6f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/bot_verification.go:1112-1121 | internal/store/postgres/bot_verification.go:1123-1135 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":1112}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff25ca342a6e59ffc375548159793c11812f52fb9cc65e6ce15b4114c68b1067"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/postgres/message_helpers.go:285-314 | internal/store/postgres/update_event.go:861-877 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_helpers.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d58c3fc413270b5736c5c7f96a588df44ce3a88f019d95f93b05154bd64b3a3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): cmd/telesrv-admin/server.go:1443-1455 | cmd/telesrv-admin/server.go:1871-1883 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1443}}}],"partialFingerprints":{"codehealthFindingId/v1":"434fe093f3be5d11b15b6305dfb5dc09cd9f79dc2d905d0828ac8190a4f68cff"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): cmd/telesrv-admin/server.go:2190-2201 | cmd/telesrv-admin/star_gift_catalog.go:132-144 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2190}}}],"partialFingerprints":{"codehealthFindingId/v1":"a41f2b9d93d1f50b0282540b96062022ee94b07c11d7cb949e78f5ff2631e22f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): cmd/telesrv-admin/server.go:2211-2222 | cmd/telesrv-admin/server.go:2480-2491 | cmd/telesrv-admin/star_gift_catalog.go:154-166 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2211}}}],"partialFingerprints":{"codehealthFindingId/v1":"36bb8624226b950f5f630ce5e2e3c02f88d22691ef4408b3f13b8d0102747d23"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/app/auth/service.go:1931-1945 | internal/domain/emailphone.go:160-175 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1931}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d7452e622640ba5901ce5efd94b3fe0be5ddd43cca6afcb555f3f09e72bbc55"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/app/channels/service.go:1721-1733 | internal/app/channels/service.go:1754-1766 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1721}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0e50a87dc412685d8f7b374728c35fba320e3e5ecdeee2445ec85614cbee9f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/app/dialogs/list_snapshot_cache.go:423-442 | internal/store/memory/dialogs.go:848-868 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":423}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcd9d014a79621e1462905a74c53a393e866780da28b17a251ad83eb89b323f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/account_business.go:384-396 | internal/rpc/account_business.go:398-410 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"22d3266844976939999ee58f773dff0f4398bb214de273f63812707e5cf94105"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/contacts.go:488-504 | internal/rpc/contacts.go:586-602 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":488}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb1518b050a171328037d942c5c67d3428574d68c57d4456cbce0982fb53e704"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/sfu/cert.go:28-38 | internal/sfu/sfu.go:130-140 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/cert.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"f50d03bf2f75366c8c3fc76b16f8770b91085caa96fc0477cc7bb0965822b2d2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/store/memory/auth_delivery_report.go:66-83 | internal/store/memory/moderation.go:279-296 | internal/store/memory/moderation.go:752-769 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth_delivery_report.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"438804ae8ccf313ee2c82569645900d318f8d7dfe44526debeb4fc1c1721dbd4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/memory/bot.go:233-248 | internal/store/memory/bot.go:427-444 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"edd4045406e1b7acc5fc418412e7f14a85acfc0669cb60d645da3dcc82e974a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 14\u002B corresponding lines): internal/store/memory/channel_settings.go:193-206 | internal/store/memory/channel_settings.go:208-225 | internal/store/memory/channel_settings.go:262-276 | internal/store/memory/channel_settings.go:278-295 | internal/store/memory/channel_settings.go:297-313 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":193}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f2f978743fa7cb8edfc753a93e8969cdacafd7cb24c72241763aea8f29a9c4b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/store/postgres/star_gift.go:91-104 | internal/store/postgres/star_gift.go:109-122 | internal/store/postgres/star_gift.go:124-155 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"7683323d0bac9ad30858b5cfca954d31ff02aaa67650268b15333df7d6d06fad"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 19\u002B corresponding lines): internal/store/postgres/welcome_message_delivery.go:224-242 | internal/store/postgres/welcome_message_delivery.go:244-262 | internal/store/postgres/welcome_message_delivery.go:264-290 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message_delivery.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb312d3eca38c990a4b900af4474aed49b21a953df0ba11a5510c27f7453f7b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): cmd/telesrv-admin/donations.go:286-298 | cmd/telesrv-admin/donations.go:303-315 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/donations.go"},"region":{"startLine":286}}}],"partialFingerprints":{"codehealthFindingId/v1":"94e8f5e0cf2d848750a36a7323f51736d5e4bbb61d4b3616c6b17591985d7f2d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/adminapi/server.go:1540-1557 | internal/adminapi/server.go:1559-1578 | internal/adminapi/server.go:1580-1599 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1540}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dea70ccbec6069ae3ce67716f95d16c9df3e7075bded2a9e4b049e6f53d4cb8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/domain/moderation.go:410-429 | internal/domain/moderation_case.go:483-499 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation.go"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bae04dba66c185cd01c9e3d5613d88cc3e37854ef89daff44408204092fabc3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/rpc/account.go:857-873 | internal/rpc/account.go:900-917 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":857}}}],"partialFingerprints":{"codehealthFindingId/v1":"68a8cca48f57e783396a0b785933deba8293eca4f93f51d6011edf68c40f5d08"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): internal/rpc/bot_verification_notify.go:40-55 | internal/rpc/username_notify.go:15-30 | internal/rpc/verification_notify.go:47-62 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_notify.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"770939d6058b279855eda334af9207a0fe9bdaa733c21b40ba7e8c8ba0c5b103"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): internal/rpc/channels_stubs.go:518-542 | internal/rpc/messages_helpers.go:517-536 | internal/rpc/premium.go:170-185 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":518}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cf2cf329971f180f7c9aa80f732cca988a6435520c45ff46f872e5b96bab578"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/rpc/messages_forum.go:259-272 | internal/rpc/payments.go:328-341 | internal/rpc/welcome_messages.go:123-136 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c9fd941dd4e0ab2d23b21a141bf00aafcf30a295323ecd3b9ba8787914e03fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 9\u002B corresponding lines): internal/rpc/payments_star_gift_lifecycle.go:17-25 | internal/rpc/payments_star_gift_lifecycle.go:161-171 | internal/rpc/payments_star_gift_unique.go:14-26 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"004190c8af1853659aa040078916782b70aeeda6a9b4872129af4fd3feffa35b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 19\u002B corresponding lines): internal/store/postgres/broadcast.go:276-297 | internal/store/postgres/media.go:844-863 | internal/store/postgres/media.go:865-883 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/broadcast.go"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"74ff6e2a9691d86df0c61cf45b695e070cc41354fb587d2462277b2eb9de9fb9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): cmd/telesrv-admin/account_rating.go:18-29 | cmd/telesrv-admin/account_rating.go:39-51 | cmd/telesrv-admin/server.go:2604-2617 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/account_rating.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"749e7cc1901541d1d23f9f7976368ce5068cd9ea31c00a0012b0807f61285a8d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/adminapi/server.go:1506-1521 | internal/adminapi/server.go:1523-1538 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1506}}}],"partialFingerprints":{"codehealthFindingId/v1":"433c6ffcdd6694b29bfbe44e6d7c7870aad17962d08e19116efe9e4911f0d7d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/channels/service.go:388-399 | internal/app/channels/service.go:402-413 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"2003fa9b107d7726acb8250cd4a7a4e92f62d5b628f40f11ed5855206abf7e8e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/app/users/service.go:638-649 | internal/app/users/service.go:720-731 | internal/app/users/service.go:734-745 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":638}}}],"partialFingerprints":{"codehealthFindingId/v1":"edc469b5429a9a33bd2f3248107720af9950ba705d77488b6f18e6d4fcd949f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/rpc/account.go:1007-1023 | internal/rpc/account.go:1066-1082 | internal/rpc/account.go:1096-1109 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1007}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8848e62f2d33edf575b4656c3c79bbeda07b49bff4f12222aaa929f2662f762"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/update_event.go:138-150 | internal/store/postgres/update_event.go:152-162 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f761fffbb9520565bdb08953faa847d9fbb53758fe0197cb017dade55b53395"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/channels/service.go:2078-2087 | internal/app/channels/service.go:2091-2100 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2078}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8ba838d04575b5192e4c02d50a4374219c05d386f22f9cc227faecd4b85034c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/telegramlogin/service.go:249-266 | internal/app/telegramlogin/service.go:268-283 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":249}}}],"partialFingerprints":{"codehealthFindingId/v1":"154b19a7f0cb161c0f5e8a2b2d6fde137e7b5dc5fb5f744a96521792578049b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/readmodelcache/cache.go:200-220 | internal/readmodelcache/cache.go:503-519 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/readmodelcache/cache.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"deb180289f66adce9e63c55ac3f8ae966d8f679acb91dc661cc7108a0281223a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/rpc/bot_verification_notify.go:61-80 | internal/rpc/username_notify.go:32-45 | internal/rpc/verification_notify.go:68-87 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_notify.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"851c840a3eb247f07f81caa35895b9b815aeaa05075ee82c07f8f1c538dd1caa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/convert_business.go:120-137 | internal/rpc/convert_business.go:150-172 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_business.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0a66e5db328a2ec3bcb0d3693b670f8e50630c0f6a2e1dd0cfa528753462dc4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/stories.go:805-817 | internal/rpc/stories.go:844-859 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":805}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b1840e679924b7b1b07834973f8ccac4e8096d418d572b2d0e2c5648f64bfa8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/media_search.go:49-63 | internal/store/memory/message_history.go:371-385 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcaed4807d8e1b894ae3bc4bf6b82a2107b306ba313dd625bd8f269fc6aaa280"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/memory/moderation.go:964-985 | internal/store/postgres/moderation_cases.go:997-1019 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":964}}}],"partialFingerprints":{"codehealthFindingId/v1":"10babb551ef306e419e76371e0011b3a87b1f0443b39274d05c4d4acd6b47191"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/ai.go:83-93 | internal/store/postgres/ai.go:95-105 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ai.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a8e9cc7c2fa3e53bf01d66d1741251d2ff682c86abfe7d41c00adcade630b86"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/themes.go:78-88 | internal/store/postgres/themes.go:90-103 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/themes.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcaf1186a7ad708944e9ee46ff5ccda7a8ee2efb547cd135f27ee54fdf23895a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/store/postgres/user.go:71-84 | internal/store/postgres/user.go:89-102 | internal/store/postgres/user.go:126-143 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c367aee50fe636a899db4bef00df337f3400147001340a1c5f4a323871d7bb8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 12\u002B corresponding lines): cmd/telesrv-admin/server.go:1102-1115 | cmd/telesrv-admin/server.go:1535-1547 | cmd/telesrv-admin/server.go:1799-1811 | cmd/telesrv-admin/server.go:2655-2666 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1102}}}],"partialFingerprints":{"codehealthFindingId/v1":"32da09d9c500ab41748110e4d33683ffde5f30079ee225a40b2b8602ea5511ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): cmd/telesrv-admin/server.go:1159-1170 | cmd/telesrv-admin/server.go:1179-1190 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1159}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ccfd538ff10ea303b2fbb6175b183af161c01c0499335a9e4a426592eeafb21"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 14\u002B corresponding lines): internal/adminapi/botverification.go:290-305 | internal/adminapi/botverification.go:307-320 | internal/adminapi/botverification.go:322-335 | internal/adminapi/verification.go:118-133 | internal/adminapi/verification.go:135-148 | internal/adminapi/verification.go:150-163 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":290}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e24fafdf1b5ac14e90d7f85b00635f93bec5d12c3a081be9319345aa87adc47"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/app/bots/verifierbot.go:1296-1308 | internal/app/bots/verifybot.go:1058-1070 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1296}}}],"partialFingerprints":{"codehealthFindingId/v1":"59d3d39bdf313cfa9b2a465cf3c6c94c5b0818012059ea300ae16405b9d986b4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/bots/verifierbot.go:1554-1565 | internal/app/bots/verifybot.go:1359-1370 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1554}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e6b2d476df0c6b5783f24db845ed8d666166fb44ce4177ba52796319e6e8b3f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/app/files/service.go:337-350 | internal/app/files/service.go:353-371 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"c72b4cd26a31fff117a9508c9feb4b30e7c60c65094483391477652e3eaaa9ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/rpc/channels_topics.go:102-114 | internal/rpc/channels_updates.go:354-365 | internal/rpc/channels_updates.go:367-381 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_topics.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"70de030cbbd0afaa0d18086bc395d4e31a6594213d986211c3dc2879d913ab74"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 18\u002B corresponding lines): internal/store/memory/bot_verification.go:215-232 | internal/store/memory/bot_verification.go:368-385 | internal/store/memory/bot_verification.go:750-767 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"53162c842d91b99efd0a0a4480a68995d5ae4e981aa512751b66c8fec3e69cb1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/store/postgres/account.go:73-91 | internal/store/postgres/read_model_versions.go:24-44 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1b2282ec544e97b1c7ca2a47c77d07f65549cba23930cbcd1ebcbc06c482652"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/read_model_batch.go:91-102 | internal/store/read_model_cache.go:74-85 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/read_model_batch.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"9894ff2a1d96028650603cfa7d70ff957a97badd321680d6296f7ccd970be395"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): cmd/telesrv-admin/botverification.go:223-234 | cmd/telesrv-admin/verification.go:105-116 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"b31741ca3de072f5b579d4bd0344e71b9fc1d1dd647397ab393c0a54a6ddeea4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 12\u002B corresponding lines): cmd/telesrv-admin/premium.go:12-23 | cmd/telesrv-admin/server.go:2126-2137 | cmd/telesrv-admin/server.go:2335-2346 | cmd/telesrv-admin/star_gift_catalog.go:19-30 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/premium.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b5c36ca4fb2cb176460d80d08ef7b83498fb83258fac7a56c1261e713135e28"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/app/donations/wallet.go:198-208 | internal/app/telegramlogin/crypto.go:106-116 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/wallet.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa4f02a85fb756f340321f04e97e48e6b738d732d861aa3d099b58c2ae72cc4a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/app/telegramlogin/url.go:102-114 | internal/app/telegramlogin/url.go:116-133 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/url.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cf6fef61957d0a6ec0c082db4ba3590ec32784d32462688c2a1c2b9e388ba1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (20 corresponding lines): internal/botapi/formatted_text.go:998-1017 | internal/rpc/botapi_rich_projection.go:429-450 \u2014 These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":998}}}],"partialFingerprints":{"codehealthFindingId/v1":"6962e05d03cd649d3aee9a171a8b930f69e56c896bc085f8c487065e6491bc28"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/rpc/messages_polls.go:231-242 | internal/rpc/messages_polls.go:244-255 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"eee8a48d69d3202c098b9fe7e7438e1be359a29ab4815c8bedad9a4793e07239"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/postgres/channel_boosts.go:285-299 | internal/store/postgres/channel_boosts.go:310-325 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d65be9b81f1460ffbe535e727e9d89d2bf93a447bb53c822fb14b99dd2ea64b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/postgres/channel_suggested_post.go:296-311 | internal/store/postgres/media.go:1046-1063 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b47edde3ee424aa76b2e7f6e9219d35c9138991a1536245c7f70575e9a8232d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/postgres/telegram_login.go:32-40 | internal/store/postgres/telegram_login.go:258-266 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"d37838203cbdd9185ad615dc66a56a944ae860d605d129824f65e93d3b47f2f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/channels/service.go:444-455 | internal/app/channels/service.go:538-549 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":444}}}],"partialFingerprints":{"codehealthFindingId/v1":"063fc5b36335f0a2da05dd79c131391299caf9b5993d93e8a27ca90761db7f07"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/app/channels/service.go:1389-1400 | internal/app/channels/service.go:1598-1609 | internal/app/channels/service.go:1612-1623 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1389}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c70000d42cf3898507ac532ed10cd09eea69b49c6f8d5b5af832bdcdaf9ad13"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/messages/service.go:338-349 | internal/app/messages/service.go:554-567 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"b022326847bb04d16ca99ed25afd9f11b2dd5b16b862a28793c97b50d72d7064"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/messages/service.go:571-582 | internal/app/messages/service.go:585-596 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b719ee882cf062c0bb30e02d049a3b114a6d66b35b17d902a03b6388cdc5579"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/account.go:1412-1428 | internal/store/postgres/community.go:1385-1400 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1412}}}],"partialFingerprints":{"codehealthFindingId/v1":"fea9696b2fe7998ee1354cb38fab4cdba71e252391475a8c76a18d11e0709a07"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 15\u002B corresponding lines): internal/rpc/bots.go:301-317 | internal/rpc/bots.go:319-333 | internal/rpc/bots.go:427-442 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e246a7c477e51585a517a65cc97d29bfe44731de420968618548d3fa2c28f82"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/channel_interest.go:15-36 | internal/rpc/channel_interest.go:42-59 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_interest.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"b931bcadc4932206863bac1d4076c8c59e8b5092f32983705465b62960108078"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/rpc/stories.go:861-880 | internal/rpc/stories.go:1275-1292 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":861}}}],"partialFingerprints":{"codehealthFindingId/v1":"d37adf4ee50a9dc4a200eaf522aff12ac5ba2f6a05224b08952602c673b02a79"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/store/memory/ai.go:94-106 | internal/store/memory/themes.go:65-80 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ai.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"777bfd81abc9c70e59280b18dc9680b04431bab3399bfbfac34bc0b5dbe0bae8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/postgres/dialog.go:639-655 | internal/store/postgres/dialog.go:1022-1036 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":639}}}],"partialFingerprints":{"codehealthFindingId/v1":"117d73194d9673347c1ef387282e7ed23be885bb86a1e51a86fc1be6b2779dea"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/telegram_login.go:102-111 | internal/store/postgres/telegram_login.go:113-122 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"0916bef7c6b9479a4d47cd74aeebc1a12fdf71b9f5166bc27d1172d6cd51c80a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/store/postgres/telegram_login.go:490-499 | internal/store/postgres/telegram_login.go:501-510 | internal/store/postgres/telegram_login.go:512-521 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":490}}}],"partialFingerprints":{"codehealthFindingId/v1":"d98c161bbb6db35c46f7203148d548d2d7344f9e6e81afca24d61480842c7739"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/telegram_login.go:828-837 | internal/store/postgres/telegram_login.go:839-848 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":828}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8c5bfe38ec06afa42a803f8c8673986f1fc81a0717868f0dd1bbb51c914979b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 13\u002B corresponding lines): internal/store/postgres/user.go:613-625 | internal/store/postgres/user.go:628-640 | internal/store/postgres/user.go:643-655 | internal/store/postgres/user.go:887-901 | internal/store/postgres/user.go:904-916 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccd796871d934739c097d90d1432c6f0f5c779433943016ae493dcb3c0d5a8a9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/channels/service.go:1626-1637 | internal/app/channels/service.go:1640-1651 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1626}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb416b807a6b1ce8a64a84cc3c1c1db3299fcd9e74af10c93b8768614cd01c03"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/branding/branding.go:186-200 | internal/links/links.go:186-200 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/branding/branding.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac022e287cc04ce0e0a37fd74373fd3d3c0908d796025d21e09669193e35ab61"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/domain/privacy_evaluate.go:75-89 | internal/store/postgres/star_gift_collectibles.go:990-1005 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/privacy_evaluate.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9b4e6cd4a55f33b39321bc6c6c8215c5715bfe709b530a410bb10f33c42072e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/account_business.go:190-210 | internal/rpc/messages_quick_replies.go:38-52 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3f51ff7db5baa92812463baba096cad4a98b170f39c87a08e22f17e972fce29"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/rpc/messages_ttl.go:15-28 | internal/rpc/messages_ttl.go:30-44 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_ttl.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba9aefa8d1a45f4909ffb65cbbb9b67d3d67cd8e9bd571f24a4cdf723209abed"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/rpc/translation_projection.go:11-21 | internal/rpc/translation_projection.go:23-33 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/translation_projection.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"781561dace19179aee61dca2a2b87b65d55e1bfc13a86e063bc3a03d6f728065"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/channel_topics.go:659-673 | internal/store/read_model_cache.go:335-349 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":659}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a78db0eb248b2745e99f812cc6d6dfbdfb04614a0b1be8eeaa7a764d55aa1d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/store/postgres/groupcall.go:955-974 | internal/store/postgres/groupcall.go:1217-1234 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":955}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f0438862e6e43032b30383aaf5e8651c6f35e33d3b2a5f077965d89bb63bc76"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 16\u002B corresponding lines): internal/store/postgres/scheduled_message.go:596-614 | internal/store/postgres/scheduled_message.go:616-631 | internal/store/postgres/scheduled_message.go:633-651 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 16 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":596}}}],"partialFingerprints":{"codehealthFindingId/v1":"64ea11c6d354cab8ec846364fcd1455db2bb98e7275ab536a8ee180c786e60b1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/channels/service.go:192-201 | internal/app/channels/service.go:833-842 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"d76a66f514afa8a8c5c3ef56c802f4f1a9d2488885b3bb68bb271c344eb903e1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 12\u002B corresponding lines): internal/app/channels/service.go:2127-2139 | internal/app/channels/service.go:2158-2170 | internal/app/channels/service.go:2266-2277 | internal/app/channels/service.go:2280-2291 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2127}}}],"partialFingerprints":{"codehealthFindingId/v1":"e184229876b8e3418bfc75daf201fb1d104b13d41c85e679c5c0f30d1fe63429"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/app/dialogs/list_snapshot_cache.go:127-139 | internal/store/postgres/channel_dialog_cache.go:132-144 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"34ca04000961e3fcee5640c0f9b7fd1816269239512ad1339c12d847c92d9be0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/compat/tdesktop/appearance_seed.go:173-188 | internal/rpc/convert_media.go:293-308 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/appearance_seed.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d8215a5d0145252edd81d67c86252e702149f35f10c625c26c4f6c734031f8b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/links/links.go:144-155 | internal/links/links.go:159-170 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f59f668dcc8109701fbe3faf0fd000e11a38d0ca69ac8475e3ce86eed0e7d47"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/rpc/bot_verification_projection.go:268-277 | internal/rpc/bot_verification_projection.go:302-311 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e7b16d3133bdecd2514849e6ac4b14e16e8d22ca4854978f3fe174cd6153832"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/memory/account_rating.go:107-123 | internal/store/memory/bot_verification.go:352-365 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/account_rating.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce6716cc65ba7714ba6c869c17f3d0b43b018ba7c97a01223104f0a3db4912ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/store/memory/groupcall.go:458-471 | internal/store/memory/groupcall.go:473-486 | internal/store/memory/groupcall.go:811-827 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f620d2d6d116b947a71ead9dfc9597e634c464205502fbac5fa17b412173995"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (18 corresponding lines): internal/store/postgres/authkey_get_batch.go:264-282 | internal/store/postgres/authkey_get_batch.go:284-301 \u2014 These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_get_batch.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea9bb2080a6ac919628f7a3547a864eee70750e2de2adecc9a8b7f0cf6fdbb9d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/admin/botverification.go:861-872 | internal/admin/verification.go:389-400 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":861}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9bd4e466e533ef0d48095de4884407e2ef917d96ed1dae717d307261ec1bed0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/bots/botfather.go:138-147 | internal/app/bots/stickersbot.go:73-82 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2c8ac5d9f860c1ee14649da92c90b6514f2cb70f6903b0b253b0f892e0b6561"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/memory/dialogs.go:408-425 | internal/store/memory/dialogs.go:466-479 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"a771cb6e3c5d0da1b9a1b6ca3b052a44e48c19b0760b5dcd2747a8585e78aedc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/store/memory/star_gift.go:933-945 | internal/store/postgres/star_gift.go:1006-1021 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":933}}}],"partialFingerprints":{"codehealthFindingId/v1":"920aff54724a99ccf427951701ce0aeb7b45a3c6fd814c9d683c67b59d247ab5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/channel_read.go:730-740 | internal/store/postgres/channel_topics.go:994-1004 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":730}}}],"partialFingerprints":{"codehealthFindingId/v1":"86b1649eb64b9142c57cb39f670452842618aafc4b425ebcbe30e24b3e9f1578"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/star_gift_collectibles.go:169-179 | internal/store/postgres/star_gift_collectibles.go:181-191 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"0adbb408c1659a18147442c26ebcb9bfb357e5c336bfa908da0189d0d78b98e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/store/postgres/update_event.go:996-1008 | internal/store/postgres/update_event.go:1033-1045 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":996}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd763f66aec3f9af91015746c1a57f19808614b6a6872005cd5f07ad894f83ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): cmd/telesrv-admin/security.go:388-405 | internal/adminapi/rbac.go:97-111 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/security.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"63718c6c464c4ebd5283e97619b006ea4c63834836d084f61d9e94ca4867cc17"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): internal/adminapi/server.go:575-585 | internal/adminapi/server.go:587-597 | internal/adminapi/server.go:621-631 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":575}}}],"partialFingerprints":{"codehealthFindingId/v1":"13b7c13031d38727dccb7738f9bf29d4e263247e12f8b2748e1dad8e882a59d9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/app/botverification/service.go:708-724 | internal/app/botverification/service.go:755-777 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0b1153038b86cec4f20853cc9f19eaeb1e48b03b6fcb72a8d871f52ba1ce4c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 15\u002B corresponding lines): internal/app/channels/bot_member_ids_cache.go:67-83 | internal/app/channels/media_count_cache.go:109-123 | internal/app/channels/participants_cache.go:102-119 | internal/app/channels/read_model_cache.go:69-87 | internal/app/channels/resolve_cache.go:71-85 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_member_ids_cache.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"00db2b7fde723814a7158b8eba8fd37c7e6509392ef02b279a94631c77b4a0ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/app/donations/service.go:180-194 | internal/app/donations/service.go:233-246 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/service.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"58538947ece221601ff73f6961ad3990d3e4688f57925d16229dad4f7ff3c9ea"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 14\u002B corresponding lines): internal/app/files/sticker_management.go:140-157 | internal/app/files/sticker_management.go:161-178 | internal/app/files/sticker_management.go:209-222 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_management.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"48271ab216c08042c46f4d56698f54f635d42d70de64658fa1915914972f6a1a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/domain/botapi_update.go:64-72 | internal/domain/botapi_update.go:74-82 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/botapi_update.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0630d975fe9febd4166029a5a2e6d9235c6a78b5f56305f14c563ea26545ee4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 8\u002B corresponding lines): internal/rpc/channels_settings.go:303-313 | internal/rpc/channels_settings.go:315-322 | internal/rpc/channels_settings.go:357-364 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf26b88d818fcf40eb6393a280f48433c154a05f9d4d7d662f2f866ed2d3c361"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/bots/verifierbot.go:1511-1522 | internal/app/bots/verifybot.go:1301-1312 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1511}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ebe82b74707398ba85046c98de56aa06ef24a149f9e0bf45ba9b951344917ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/files/sticker_management.go:329-338 | internal/rpc/convert_media.go:710-719 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_management.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f854c9ca9dc889d987acd17a7f1492aed69e42d13b14bf13096b18612b97147"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/loadharness/mutate.go:78-89 | internal/loadharness/seed.go:44-55 | internal/loadharness/snapshot.go:88-99 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"27bb9abaa35a6f14b2f437a72ab8d410fc850e179e1ff3127927eaef0393b0e5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): internal/loadharness/seed.go:611-621 | internal/loadharness/seed.go:623-633 | internal/loadharness/seed.go:635-648 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":611}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d605cbdbeb87af13228e8168312e020a27c474a1df02cb713a1cb23bd78ff79"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/messages_compat.go:308-320 | internal/rpc/payments.go:188-200 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_compat.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"917c0fa1f901a69c0ee8700d08dc8d62f7d1dc75bac6c8396452cef512d4cb22"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/rpc/messages_send.go:911-928 | internal/rpc/messages_send.go:930-945 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":911}}}],"partialFingerprints":{"codehealthFindingId/v1":"7739cadec4638228e15f78c4e62af03a9412d44367c6c746b07dbf2b506bde9c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/rpc/stories.go:2340-2354 | internal/rpc/stories.go:2396-2412 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2340}}}],"partialFingerprints":{"codehealthFindingId/v1":"87fd4d807ef1b1e2e72a4ae2e635945fd994cc991fa352918b9e11a7fc43984f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/memory/users.go:73-86 | internal/store/memory/users.go:90-103 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/users.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"559919441d6d07fd9012aef617b9fc40869c39e934b293305057f0de216cf08c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): cmd/telesrv-admin/activity.go:134-145 | cmd/telesrv-admin/server.go:2742-2753 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/activity.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"926ed31444a26c83d38f038be610cac3f13c0440c89601a12fc5a5c5eb0c33e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/files/retention_purge.go:213-222 | internal/app/files/retention_purge.go:227-236 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention_purge.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ed9cb309f8a04780c8b1ea9b8e1696acb3b2c39b939b5a45a87a21d1787264e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): internal/app/groupcalls/service.go:263-273 | internal/app/phone/registry.go:114-124 | internal/app/secretchat/service.go:308-318 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/groupcalls/service.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5c16f7463cd14900c14e815b9831ffffcbae9a4d9e272e9b0c1c412ba224cdc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): internal/app/stargifts/service.go:1070-1080 | internal/app/telegramlogin/service.go:987-997 | internal/store/postgres/premium.go:206-216 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":1070}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b73369abc13f8e8ddf5f971f28df5ddafb6bb93329ff4ea14eb4ee4ccb82411"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/app/updates/service.go:356-370 | internal/app/updates/service.go:406-421 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c04564e4e92b823e4c60e770e18cd423f82a19e85a5b8e257c4a34a134a207e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/mtprotoedge/rpc_execution_budget.go:57-67 | internal/mtprotoedge/rpc_result_subscriber_budget.go:37-49 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_budget.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"01fac95725d6633ad35b21d06eddda25554ff53015e8826d56086294cf67790e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/mtprotoedge/session_manager.go:2307-2320 | internal/mtprotoedge/session_manager.go:2324-2336 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2307}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc11dbebb9d4ed1348da4909be54ed5d1952112462e876d67edde8d1589f7d58"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/users.go:408-423 | internal/store/memory/users.go:425-439 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/users.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"6036a46ec3437e51b062a4122d8f3c0cf5a0fdbf556f6b62894d4c8599a5e743"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/postgres/collectible_username.go:776-791 | internal/store/postgres/collectible_username.go:793-804 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":776}}}],"partialFingerprints":{"codehealthFindingId/v1":"c397a4c6a2a2c9af80f23f9f2bb1cca661b1b010909537d3534719dea2ede5be"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/postgres/moderation_cases.go:1208-1222 | internal/store/postgres/moderation_cases.go:1226-1242 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1208}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ffc68d04b7b5af87df44775177e7dc475fee7d39231206ca13ef9fae022f1e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 13\u002B corresponding lines): internal/store/postgres/verification.go:1079-1091 | internal/store/postgres/verification.go:1096-1109 | internal/store/postgres/verification.go:1114-1128 | internal/store/postgres/verification.go:1130-1143 | internal/store/postgres/verification.go:1145-1160 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":1079}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce0df461b42a0877bf5c94c8d816cdb449f71b4a22fba7c83bc19aa09872a3ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/loadharness/rich_state.go:181-190 | internal/loadharness/snapshot.go:494-503 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/rich_state.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d7fde5c6d151339d513fb5fdaf04deba3df7362cd1ac89d76d6ad0a3ece5955"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/privacy_gifts.go:13-28 | internal/rpc/privacy_voice.go:11-23 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/privacy_gifts.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"800a28d448bcbc26b603cad6cbf7cd6a055d8c9410242a59f9695cb2858922e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/postgres/langpack.go:439-452 | internal/store/postgres/langpack.go:454-467 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/langpack.go"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"b751108ead63c91b1d810f18b4bc47880f7cc0a2323aba832a7572f40513ec29"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/moderation/appeal_links.go:44-53 | internal/app/moderation/appeal_links.go:62-71 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/appeal_links.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"615106f59b4e16a0ab84cfa60998d71ac2a63cc502485810966857effd78f501"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/app/stargifts/service.go:883-889 | internal/app/stargifts/service.go:891-897 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"622b93d18863064d2d636813724fe184b846d0bcf2436aaf88944f5c47714e23"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/app/updates/service.go:468-481 | internal/app/updates/service.go:540-554 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"34b5bc9758ad104942fdc26031c0a96c636e77d0c0c6e79895a30824b901a792"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/domain/ephemeral.go:322-337 | internal/rpc/ephemeral.go:355-369 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/ephemeral.go"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"5814a3964818c9b6fb43aa7e31ba3ecefa4b3abb24d4e0875f6d62e0336faff1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/links/links.go:298-313 | internal/rpc/messages_compat.go:479-494 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2cd79d89cdd37a2006fafddf024db381026654966f33a53d73600ac95cc20ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/rpc/bots_inline_message_id.go:42-52 | internal/rpc/bots_inline_message_id.go:54-64 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline_message_id.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"5670cd6f91ef9f10d06df8d4edf9d9ba1295b4f2ed9ea2c200398838c8629ea6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/rpc/messages_games.go:33-44 | internal/rpc/messages_games.go:66-80 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_games.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"01ea045cede488a16b754bc07f7130077c3827b67db747fbb9e017237cb4b0fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/rpc/messages_helpers.go:603-612 | internal/rpc/payments_star_gift_lifecycle.go:1148-1157 | internal/rpc/payments_star_gifts.go:1336-1348 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_helpers.go"},"region":{"startLine":603}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd693ba1f02548350434926042a238a712430a2d5e4893e3e9a9dc8c2439c09e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/channel_message_history.go:1042-1051 | internal/store/postgres/channel_suggested_post.go:645-657 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":1042}}}],"partialFingerprints":{"codehealthFindingId/v1":"5794454e4449482eb60e494d9684902464a60b16cf3898b52a3b80de3da15dcb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): cmd/telesrv-load/main.go:278-286 | cmd/telesrv-load/main.go:460-467 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-load/main.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"d55ffab2fd4a8a5f300e8b16f3c946c4e47a9cbd9a5a78a4d07f02007a5cb329"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): cmd/telesrv/log_encoder.go:155-165 | cmd/telesrv/log_encoder.go:167-177 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/log_encoder.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"cceb228b0f1f9caddffe588d85e429023a2e808afa0674c86e48a386323b190d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): internal/app/channels/read_model_cache.go:102-107 | internal/app/dialogs/read_model_cache.go:566-571 \u2014 These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/read_model_cache.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdc0ebdcc6b75f889d58dd4076a4505409b1e6981ae0e97fb615d0b61d0898ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/app/messages/service.go:352-361 | internal/app/messages/service.go:400-409 | internal/app/messages/service.go:854-863 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":352}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcf2ec5511d19b47ad062880c55de3377aeb575038c088de3977d5a031377c8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/loadharness/mutate.go:439-450 | internal/loadharness/mutate.go:452-463 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"56792c7e991c84b181ab3f3e1b6bf6a8aa4571b7a62873e91388699c9262d2c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 14\u002B corresponding lines): internal/rpc/messages_edit.go:260-273 | internal/rpc/messages_edit.go:275-288 | internal/rpc/messages_forward.go:776-791 | internal/rpc/messages_reactions_helpers.go:178-193 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9976b5f0ba7de7baa3477840fa8774879582ca408541ba5e926d1d47bd28b98"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/rpc/photos.go:648-656 | internal/rpc/photos.go:658-671 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":648}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7f75efd5c514af7477a66f9896b24a4d7b075d42112c7e9e83598f0dadaf88e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 7\u002B corresponding lines): internal/store/memory/bot.go:781-787 | internal/store/memory/bot.go:789-795 | internal/store/memory/bot.go:809-815 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 7 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":781}}}],"partialFingerprints":{"codehealthFindingId/v1":"66f4827a496dc5586213021182e5d2918130afef4a2ae5c6d11f9396980fbe6e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 12\u002B corresponding lines): internal/store/postgres/business.go:199-224 | internal/store/postgres/chatlist.go:79-92 | internal/store/postgres/chatlist.go:94-107 | internal/store/postgres/chatlist.go:208-221 | internal/store/postgres/chatlist.go:223-236 | internal/store/postgres/community.go:152-163 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/business.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d6d25390f7585246a365b17dddeb1f3fd06dd87f51fc6371187286348590def"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 11\u002B corresponding lines): internal/store/postgres/groupcall.go:100-110 | internal/store/postgres/groupcall.go:220-231 | internal/store/postgres/groupcall.go:233-243 | internal/store/postgres/groupcall.go:245-255 | internal/store/postgres/groupcall.go:743-753 | internal/store/postgres/groupcall.go:755-765 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"56e30b1aff8f094fe23728e5e2aafd726efe922eef660019fefd466fccc2ca69"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/app/botverification/service.go:740-750 | internal/app/botverification/service.go:873-888 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"071c05e8ea6ac01dab142d08da78e6ad83938333cb0c400eb85bebd689b2bf6c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/memory/channel_core.go:192-204 | internal/store/postgres/channel_core.go:322-333 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"2474c9d80faef1bf7040449c753e8e1713efa6a537a28294496e8436d1d8c69e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/channel_message_send.go:394-408 | internal/store/postgres/channel_message_send.go:661-675 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"684e87a53feda22fe26d35500477a7181b8a7fdfa2d8f18c86aa1be2c1766c3c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/postgres/channel_updates.go:557-572 | internal/store/postgres/user_pts.go:31-50 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":557}}}],"partialFingerprints":{"codehealthFindingId/v1":"855bdbf9ba316d693c096a4cd38a366646d26a11bcfd78e75300893917e985ac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 13\u002B corresponding lines): internal/store/postgres/media_codec.go:34-46 | internal/store/postgres/media_codec.go:62-77 | internal/store/postgres/media_codec.go:90-102 | internal/store/postgres/story.go:2499-2511 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_codec.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"681aa88a751156eb99dbecf4cbeb6f4b605ee2f2132588686cde76c29a9cf5f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): internal/app/channels/bot_member_ids_cache.go:85-95 | internal/app/readmodel/hash.go:24-36 | internal/rpc/callback_registry.go:213-224 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_member_ids_cache.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"a48cbd39e317e7e5acc0fda37f736dcb638bdfafe5f2c10c80fe8e5dc4d7946e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 13\u002B corresponding lines): internal/app/langpack/cache.go:63-75 | internal/app/langpack/cache.go:176-188 | internal/store/postgres/media.go:519-531 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/cache.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbf605972c421dfd485264b11f7a4922c056bee5b3743a487b97bb00b9571d50"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/mtprotoedge/session_manager.go:2587-2601 | internal/mtprotoedge/session_manager.go:2673-2687 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2587}}}],"partialFingerprints":{"codehealthFindingId/v1":"413229fd54668bbaa2f9fa924855bfa7f5db7989f7ea4a68c947a60344033eb9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/stories.go:3042-3057 | internal/rpc/stories.go:3059-3071 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3042}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9efbb80ca3a470cd39d3ba581b0c210e8cfbc0a015ab531d39452cb8cdf454a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/memory/channel_core.go:141-156 | internal/store/postgres/channel_core.go:269-284 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"81e585b7b834f915f276c8de8ecd5222e38c92d64d0747c70420922a1f9be5f9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/bots/verifierbot.go:1254-1265 | internal/app/bots/verifybot.go:1022-1033 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1254}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d9eedf58681c2b8cb0b82090e746967a3483d2aec8b6f6acbf4c7d2531b271c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/channels/service.go:1232-1243 | internal/app/channels/service.go:1246-1257 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1232}}}],"partialFingerprints":{"codehealthFindingId/v1":"483ee52cc4a68105e12a36012efb3458a16e15260ac395e77fd81e55b4fac9d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 13\u002B corresponding lines): internal/app/messages/service.go:671-683 | internal/app/messages/service.go:685-697 | internal/app/messages/service.go:699-711 | internal/app/messages/service.go:713-725 | internal/app/messages/service.go:727-739 | internal/app/messages/service.go:741-753 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":671}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0265ef7abe93ccb2c18ac5704066a9974f05b56be1c8a587778b1d7bc8a1ee5"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/rpc/botapi_gateway.go:782-793 | internal/rpc/botapi_gateway.go:795-803 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":782}}}],"partialFingerprints":{"codehealthFindingId/v1":"26fca0ca56dff6faaa701f2b34d04b20e155241996b67c0494ec148324c33147"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/rpc/story_peer_projection.go:69-79 | internal/rpc/story_peer_projection.go:214-223 | internal/rpc/story_peer_projection.go:225-234 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_peer_projection.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"fecb1a5c61fca41228ec5615e295ca407b8f74cacbb902a2af620207c421f9d7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/rpc/story_projection_cache.go:234-247 | internal/rpc/story_projection_cache.go:249-262 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_projection_cache.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"e983441f7552059bfcd2502e8fa71a5e012c0814f9ccf29d53230d92cd4eefbb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/memory/channel_updates.go:165-175 | internal/store/memory/password.go:163-173 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0ae788aec612b98fd9e225f54c5e6dc4260b44943dd5ada51e9d1f59c288899"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/channel_helpers.go:912-927 | internal/store/postgres/donations.go:26-36 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":912}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c67d3c84dd19f8cf5de8e6b1e25c4ff72ceeb60916eb4c725a7b6a2acf0590e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/admin/service.go:787-795 | internal/admin/service.go:804-812 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":787}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc0ac6cff2c29d1eaec9186533ca1be29e36fd4eeec338965dd9e1502a7b4705"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 12\u002B corresponding lines): internal/app/account/business.go:28-39 | internal/app/account/business.go:41-52 | internal/app/account/business.go:54-65 | internal/app/account/business.go:67-78 | internal/app/account/business.go:80-91 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/business.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"1984bf2c512439546301f31bd7061cbac31e5b92e18556158cf121f741156c82"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/app/userprojection/contact_cache.go:253-263 | internal/app/userprojection/durable_user_facts.go:85-95 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"026064e90117fc330ba7fd45ffd4b38f043b2c8d8a304b91e64ed5597190d564"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/mtprotoedge/conn.go:260-275 | internal/mtprotoedge/conn.go:277-291 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b7d041aa49e3067ec0559fd915534573419a1e7d56e208d9bfa4ec4997edc35"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/memory/channel_message_history.go:635-650 | internal/store/memory/message_history.go:441-456 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b8d889bc9d99034afa4eb80f4ef9ba09ac847b0473c6604bac8a2a788c23a88"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 11\u002B corresponding lines): internal/store/memory/users.go:269-279 | internal/store/memory/users.go:281-291 | internal/store/memory/users.go:342-352 | internal/store/memory/users.go:355-365 | internal/store/memory/users.go:368-382 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/users.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"80c9439f28fe37352d42888f2f994b5325e6fb42435bf22d6d36cfec9ff63e77"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/postgres/channel_invite_exported.go:499-515 | internal/store/postgres/channel_invite_exported.go:517-533 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":499}}}],"partialFingerprints":{"codehealthFindingId/v1":"0738220ae492f247f69c1f34e04a98600431d06da7fe94c6ba2878d5f3847280"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/channel_read.go:349-359 | internal/store/postgres/message_history.go:290-300 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":349}}}],"partialFingerprints":{"codehealthFindingId/v1":"c804993d8c7a1fd74edb846065f2cea01f00fd4798f0f663dcf9979570c2777e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): cmd/telesrv-admin/server.go:622-629 | cmd/telesrv-admin/server.go:631-638 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":622}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9fa6e891b77d8ac61c9bb60284cc3d184373661f86fa5cc5d8a7c01c4dabfdc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/app/files/diskspace_unix.go:9-15 | internal/hoststats/disk_unix.go:13-19 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/diskspace_unix.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"21feaed86cd76f135f7de8350a895550dec2e2c6ee325673253f0ed288b52248"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/stories/service.go:168-176 | internal/app/stories/service.go:196-204 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"e713accc58cbe93906bffa32f97c35ad9c255bffbf02c06cee85e75bd15ebc95"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/rpc/callback_registry.go:91-104 | internal/rpc/inline_registry.go:186-197 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/callback_registry.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcf31dc751ac6537e947e1eb40d1951d4b5cae9acbd3f8af1903e8b11d8f5c3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/rpc/callback_registry.go:192-206 | internal/rpc/messages_no_forwards.go:135-144 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/callback_registry.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"3334bbe81dc5f0d0ba126bee8768bf07ef9fe03068be7273fabac0c233f2a538"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/rpc/contacts.go:1178-1187 | internal/rpc/contacts.go:1195-1206 | internal/rpc/contacts.go:1208-1217 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":1178}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddf2d5f0160269d6cbc8829dcc8f40082a2c6b4708430e58e27c8143357ee159"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/memory/bot_verification.go:186-197 | internal/store/memory/bot_verification.go:201-212 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ebe557d06ca6ce0d81c3c98506315b27994bc7c2be8d24463e2ad5626bbdb3c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (15 corresponding lines): internal/store/memory/channel_read.go:415-430 | internal/store/memory/channel_topic_read.go:89-103 \u2014 These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":415}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba156821d49f8d1c669a2d20706682e1787a976a0d2d2aff47f993386e3fb61a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/store/memory/verification.go:452-463 | internal/store/memory/verification.go:467-478 | internal/store/memory/verification.go:481-492 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":452}}}],"partialFingerprints":{"codehealthFindingId/v1":"972b3c1ae314bfa24f76934a919bdb959a3216c8d415307588ec58f38e37e2c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/store/memory/verification.go:780-787 | internal/store/postgres/channel_core.go:614-626 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":780}}}],"partialFingerprints":{"codehealthFindingId/v1":"61073cbfe93d793e22b3137cdae59690dec127f33d65810f381d4fb0f30675a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 11\u002B corresponding lines): internal/store/postgres/bot.go:364-376 | internal/store/postgres/bot.go:378-388 | internal/store/postgres/bot.go:390-400 | internal/store/postgres/bot.go:402-412 | internal/store/postgres/bot.go:414-424 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":364}}}],"partialFingerprints":{"codehealthFindingId/v1":"99127369e66d5afb1c745e2bc1b68a89abb61cbf16a26b67ac5d77f7ca319fc4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/app/account/service.go:333-345 | internal/app/account/service.go:1064-1076 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6dd552369223aa3a77e6cfcb9e1214b6072ecb1aed1f271dd4ed1163191ba4e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): internal/app/bots/botfather.go:1049-1061 | internal/app/bots/service.go:682-692 | internal/app/donations/watcher.go:130-142 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":1049}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ce67eb404ff87ef496711633cb15596cf397076e809b7c073e41f198853b2ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/botapi/server.go:277-288 | internal/botapi/server.go:290-298 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddec8cb6d47c98624cb1756b1ab8119ebf7552923aad40bdfda3409045141d78"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 7\u002B corresponding lines): internal/mtprotoedge/rpc_execution_budget.go:200-206 | internal/mtprotoedge/rpc_execution_ledger.go:189-195 | internal/mtprotoedge/rpc_result_subscriber_budget.go:143-149 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 7 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_budget.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7ce1008b11de8ce219a21f7aa2617bbcd1cd38f4e510f7e80c1b9e5cae3aceb"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (19 corresponding lines): internal/rpc/bootstrap_updates.go:54-72 | internal/rpc/outbox_dispatcher.go:123-144 \u2014 These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bootstrap_updates.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"222cc691ac91c59c15d2263083036b7513086b898c719dd5ea0b6b8527cc3f01"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/rpc/convert_stories.go:337-351 | internal/rpc/convert_stories.go:394-405 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_stories.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"97cabe96418f9ecf57ef76342b54c8be5566e4415c1bc52d513a91dabfbd6509"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/stickers.go:574-586 | internal/rpc/stickers.go:588-600 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers.go"},"region":{"startLine":574}}}],"partialFingerprints":{"codehealthFindingId/v1":"7944e3aac862ee91b4b1d0f452a51f36c0df417521827b25093c9b4895826ef4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 11\u002B corresponding lines): internal/store/postgres/broadcast.go:153-209 | internal/store/postgres/donations.go:63-73 | internal/store/postgres/donations.go:308-318 | internal/store/postgres/encrypted_queue.go:164-175 | internal/store/postgres/history_ttl.go:44-60 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/broadcast.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c3b30295fd983e4a020243bab28914da16f211445de35959174651cb4c3fb6b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/postgres/star_gift_listing_suspension.go:77-90 | internal/store/postgres/star_gift_purchase.go:104-120 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_listing_suspension.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"c51021feaf5d9145617b12cc4e1a8052767e1abc70adcbf831783052fe610b22"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/store/postgres/story.go:443-464 | internal/store/postgres/story.go:2028-2043 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":443}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb06a581e13ff646c1b454d50f29ad343ce6ef57b6fe8aae0ae8bf699857d251"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/auth/service.go:1605-1613 | internal/app/auth/service.go:1615-1623 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1605}}}],"partialFingerprints":{"codehealthFindingId/v1":"29e3a2dba9937777509a32fc69349c8a2ddc6f539ac98450b7a2fc8b950ca044"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/loadharness/startup.go:624-635 | internal/loadharness/startup.go:867-880 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":624}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6c2e1055bda71e733580538e96c972ec9055e550e7e1de7917f01cd7f66744a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/mtprotoedge/inbound_layer_rpc.go:1381-1392 | internal/rpc/layer_dispatch.go:531-542 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":1381}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca8283ded212537a6cafdf23d204e14b9ed2faed1dd456f8dfec6e449c59c3a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 8\u002B corresponding lines): internal/rpc/stories.go:3402-3410 | internal/store/memory/story.go:1532-1539 | internal/store/postgres/story.go:2375-2382 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3402}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc86e2bbfe99fdbcba3f4e0fb781e49850642e12af121f2bc0c57a7239224776"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/memory/bot_verification.go:671-682 | internal/store/memory/bot_verification.go:687-698 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":671}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d29f4e5ba8d361e64f434ebc2e10d4b97494d0324f8774f87f8e89514c2da95"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): internal/store/memory/community.go:902-912 | internal/store/memory/community.go:913-923 | internal/store/memory/community.go:924-934 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":902}}}],"partialFingerprints":{"codehealthFindingId/v1":"134d0d786f8567368a127d22cf22a88d536176443d1697958796b97a4c4dc1b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/memory/star_gift.go:184-193 | internal/store/memory/star_gift.go:195-204 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"61041328a4f5678cf9f37b2c02babbac9679e8db8afc273123bea122e9cc33df"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/store/postgres/channel_core.go:710-716 | internal/store/memory/channel_helpers.go:766-772 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":710}}}],"partialFingerprints":{"codehealthFindingId/v1":"af84e6421d19231d6b8a8104adf2b27ced89a5845db969fc99260ad866fb8b29"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 8\u002B corresponding lines): internal/store/postgres/channel_reaction_unread.go:101-112 | internal/store/postgres/channel_read.go:578-589 | internal/store/postgres/channel_topics.go:859-866 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 8 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffaed0c27aa6f8481fd04411f11f2b00b8ce54d55368fd664f8709853c7e7877"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/postgres/donations.go:438-449 | internal/store/postgres/donations.go:501-512 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/donations.go"},"region":{"startLine":438}}}],"partialFingerprints":{"codehealthFindingId/v1":"684596a67294523a3aa8a48e9dd72f21b8f2b008908ff44cf2f6ab30d5e8eeff"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): cmd/otpwebhook-example/main.go:267-273 | internal/otpdelivery/webhook/sender.go:195-201 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/otpwebhook-example/main.go"},"region":{"startLine":267}}}],"partialFingerprints":{"codehealthFindingId/v1":"b306e5dce71eda64db29c2397c58da279e9afec5c0e231854d48329389d8b8c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): cmd/walletminiapp/main.go:500-507 | cmd/walletminiapp/main.go:509-522 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":500}}}],"partialFingerprints":{"codehealthFindingId/v1":"f179b4bef9acb5ba601094cc279e8c728359ccc234f927ae45318da2d3c365ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 9\u002B corresponding lines): internal/app/channels/service.go:341-349 | internal/app/channels/service.go:904-912 | internal/app/channels/service.go:2255-2263 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":341}}}],"partialFingerprints":{"codehealthFindingId/v1":"6495d1bb4c869365ea336fb26d57f5f92cf4e8cbf14c39089385d812ba4d3ee4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/channels/service.go:985-994 | internal/app/channels/service.go:1022-1034 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":985}}}],"partialFingerprints":{"codehealthFindingId/v1":"14e0a353e643f4721100136ae36c64beec9ccb60aad5f08e1cdd4a932f9efe9d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/dialogs/service.go:911-923 | internal/app/dialogs/service.go:1167-1176 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":911}}}],"partialFingerprints":{"codehealthFindingId/v1":"036bd59b3915735f76ae268f5fa82f1557c3d213b54453f4de1bd3d616284055"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/app/updates/service.go:424-435 | internal/app/updates/service.go:454-465 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f7b4751c7763f7f3995e4a9b10597ff3e6baad08985e89c6219cf263f870054"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/mtprotoedge/rpc_rewrap.go:119-129 | internal/mtprotoedge/rpc_rewrap.go:189-199 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_rewrap.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"46fbb8879fe5fe0da8b2966b076dded8e66971524a9e5e878087ff120bfd3d1a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 18\u002B corresponding lines): internal/rpc/account_deletion_notifications_worker.go:19-37 | internal/rpc/account_freeze_worker.go:16-34 | internal/rpc/account_lifecycle_worker.go:19-37 | internal/rpc/premium_sweeper.go:20-37 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 18 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion_notifications_worker.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"7eba01831317fa294a408741f7c5a9244d99f5c650b79f7b01273821ce329f23"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/store/memory/business.go:494-501 | internal/store/memory/story.go:1398-1405 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/business.go"},"region":{"startLine":494}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f1dc9b2c42267554e5312cd0cd1919bd2ef5066278a86120aebb83cef99824a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/bot_miniapp.go:502-512 | internal/store/postgres/user.go:487-501 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_miniapp.go"},"region":{"startLine":502}}}],"partialFingerprints":{"codehealthFindingId/v1":"48e0675af61d0580d47d8b3a936f9c1f6945bc8932716874758aa87cbb1b1837"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 5\u002B corresponding lines): internal/store/postgres/channel_polls.go:19-23 | internal/store/postgres/channel_polls.go:25-29 | internal/store/postgres/message_polls.go:18-22 | internal/store/postgres/message_polls.go:24-28 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 5 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_polls.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"1356274a83dc40ae04a2ea9125c54c659f80c81f4bc19a006b26d4e0186f3495"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (52 corresponding lines): internal/store/postgres/channel_reaction_unread.go:253-321 | internal/store/postgres/channel_read.go:806-857 \u2014 These two members are one piece of code written twice and then edited apart: 52 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d4cd204e348b49a1172e4593d02ea552f9202939e72d846bab820fb2313e78c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/app/bots/chatbot.go:249-264 | internal/app/messages/business_ai_provider.go:86-101 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/chatbot.go"},"region":{"startLine":249}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b4e41f9ad5a61a0d96e47424469e2c9ece601d920a8afebf612f339b18b992b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/rpc/account.go:691-701 | internal/rpc/auth.go:794-804 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":691}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d04db8b5fb146b83273e31df16c8eafaf9e7524da94648d796ed3b9d08c4967"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/rpc/account.go:718-727 | internal/rpc/auth.go:835-844 | internal/rpc/chatlists.go:269-281 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":718}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9732dd21aa5a6ecc95ddfad4dbe5c9fdd6f4838a8e0aba12c3c9a79f3006bb0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/memory/bot.go:204-217 | internal/store/memory/botapi_update.go:392-406 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7a2d96da2be1961722c1b59e6c1e7080dbd5e0b6f46c6689d642e6b8731b673"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/memory/business.go:513-522 | internal/store/postgres/business.go:832-841 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/business.go"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f5e2ae87310f059685a02a26ef90f5b76387037f70bd90407ec9b68fc466557"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/store/postgres/dialog.go:677-691 | internal/store/postgres/dialog.go:812-823 | internal/store/postgres/dialog.go:916-929 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":677}}}],"partialFingerprints":{"codehealthFindingId/v1":"63da780675120dd09a6f1cdc8dc01e74240535d98d814ae1a9a2394749626c6b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/postgres/dialog.go:737-748 | internal/store/postgres/dialog.go:904-914 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":737}}}],"partialFingerprints":{"codehealthFindingId/v1":"82dd4c6e09011cc2c48512210cb6a3289fa3bc39f21a254c547c3218e56f4463"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (5 members, 11\u002B corresponding lines): internal/app/ephemeral/service.go:595-605 | internal/app/ephemeral/service.go:607-617 | internal/loadharness/run.go:711-721 | internal/rpc/send_media.go:963-973 | internal/rpc/send_media.go:976-986 \u2014 These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":595}}}],"partialFingerprints":{"codehealthFindingId/v1":"e646aa9f219828a5020a6d7975d4795c2cc6b658f27a4dd615e9551d52286281"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 13\u002B corresponding lines): internal/mtprotoedge/session_manager.go:1424-1436 | internal/mtprotoedge/session_manager.go:1463-1478 | internal/mtprotoedge/session_manager.go:2139-2151 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1424}}}],"partialFingerprints":{"codehealthFindingId/v1":"d65668c418ae337556af8719b484836354699a3252d18493434cf4b8d4ff9d9c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/memory/contacts.go:274-287 | internal/store/postgres/dialog.go:1194-1204 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":274}}}],"partialFingerprints":{"codehealthFindingId/v1":"31749ccb9a97589ce37853af8fedb756654235ac2184d7d1808e0a2e12936e2c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 9\u002B corresponding lines): internal/store/postgres/channel_reaction_unread.go:154-162 | internal/store/postgres/channel_read.go:631-639 | internal/store/postgres/channel_topics.go:908-916 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"616fec1c0faff1e4b99e9887e156712fe7106432e1edcb75a17846e88d904eaa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): cmd/telesrv-admin/privateview_store.go:885-895 | cmd/telesrv-admin/star_gift_catalog.go:488-498 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":885}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbf385ae72738c68245d3da6b5ddd687040dbe2296acb8895bab03dd11fd8a55"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/adminapi/botverification.go:230-238 | internal/adminapi/verification.go:165-173 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"c35d59ec78f855b425d93032c3954ef763b99d6b852a0408f5e971afdcd80b1d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 10\u002B corresponding lines): internal/loadharness/dataset.go:251-260 | internal/loadharness/dataset.go:323-333 | internal/loadharness/file_fixture.go:102-112 | internal/loadharness/types.go:126-136 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3bf6d792bcaeb295642d5f68c1384fa60ecf445f63d24bedfeaa2f73861b1d7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/loadharness/snapshot.go:684-693 | internal/loadharness/startup.go:1028-1037 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":684}}}],"partialFingerprints":{"codehealthFindingId/v1":"80d92f10a20a4ef970cfe5b6573027fb1c21090b663a57f13f9f33b20f29436b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 12\u002B corresponding lines): internal/rpc/account.go:2235-2246 | internal/rpc/bots_errors.go:94-107 | internal/rpc/channels_settings.go:572-583 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":2235}}}],"partialFingerprints":{"codehealthFindingId/v1":"373de8baef7fcb09c6c4f0f19e867caf3692d23fe924f90d33fbebc74c7a91a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/memory/users.go:295-305 | internal/store/memory/users.go:308-323 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/users.go"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ab062f608061d88ae6a530ba3ff736ca1aa44a0412fce09737db3c62ca3794c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/store/postgres/bot.go:426-438 | internal/store/postgres/contact.go:1146-1160 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":426}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1900b46520e0d361df3778ac51543f18e011fa4d0ad079efd184464d7a2e194"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/store/postgres/media_codec.go:111-120 | internal/store/postgres/poll.go:410-419 | internal/store/postgres/story.go:2477-2486 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_codec.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"66b597d5218c6b04655136d68d6a231a85df883f59a9919501d12fbdc2919ad9"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 9\u002B corresponding lines): internal/app/stories/service.go:95-103 | internal/app/stories/service.go:112-121 | internal/app/stories/service.go:123-131 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b54f05e1b5efb1b20ef02ee9594587eb9d9116e42a187e6ccdfd49c55ee0a8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 13\u002B corresponding lines): internal/branding/branding.go:202-215 | internal/domain/bot.go:236-248 | internal/rpc/messages_webview.go:578-590 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 13 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/branding/branding.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa6087136092e0f13313235715639ccc136f5d3d243f2d1e9307b921cd8300e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/memory/chatlists.go:81-89 | internal/store/memory/chatlists.go:119-129 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/chatlists.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"98322c4d29871289482049813c3be649974ec1fdb651852b443d72cb62e2cf97"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/memory/chatlists.go:159-168 | internal/store/memory/bot.go:393-402 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/chatlists.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c27532a0157cb1537f21199a639b292c6a2ab19a34714fb7296db69852c277e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 10\u002B corresponding lines): internal/store/postgres/contact.go:1176-1191 | internal/store/postgres/gif_catalog.go:47-56 | internal/store/postgres/scheduled_message.go:412-430 | internal/store/postgres/themes.go:105-114 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":1176}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bc4909bc041f387af7a4fb46130260c4afd8a5bec2568fbe07fed5520c6e98b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/adminapi/server.go:664-672 | internal/adminapi/server.go:1944-1953 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":664}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb7e5e72dc4995d3b6446a5b9d4b24ee090acc8ebee8a16e4a01b9e352645d53"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/files/blobcache.go:119-127 | internal/app/files/blobcache.go:186-197 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/blobcache.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"00fb93bebe4e48c7a728b40acd46965e3ae3d926c622380b388f841cc0ad0872"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/mtprotoedge/rpc_execution_budget.go:183-193 | internal/mtprotoedge/rpc_result_subscriber_budget.go:122-132 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_budget.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"6124b6db54515a27bef60670045693b98a0c6e8d8eb625a856d13b7b95c3b11e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (16 corresponding lines): internal/mtprotoedge/session_manager.go:2806-2821 | internal/store/memory/sweeper.go:43-59 \u2014 These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2806}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a5e93d0ffe19abb7dfa94f12c7e9604a9efe2dd570a37bc595149758895c174"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/memory/chatlists.go:180-189 | internal/store/memory/chatlists.go:191-203 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/chatlists.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"720d3bd1c6555fb93ab77bb4d12ea197a3aba613ed43ed349b837858b59f81e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 11\u002B corresponding lines): internal/store/postgres/dialog.go:959-973 | internal/store/postgres/star_gift_craft_auction.go:1258-1268 | internal/store/postgres/verification.go:1209-1221 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 11 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":959}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bddc80a1202d2d2e73c30345c7543530296e83ba557f7558a6c3d0b1fdde8b7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/star_gift.go:858-867 | internal/store/postgres/botapi_update.go:541-555 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":858}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c450e5e5659e05e5357b6ec47dfdc2719dcf0c94d2cfec8d3bb3fdd31605ee4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/botapi/server.go:412-418 | internal/rpc/welcome_delivery_dispatcher.go:282-288 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"50382a9f964b4342c29cfe8c37bb5d806d3445f84b31c92caa571eee0cc8aad7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/rpc/send_media.go:1203-1213 | internal/rpc/account.go:920-929 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":1203}}}],"partialFingerprints":{"codehealthFindingId/v1":"85f37038fa9227b4bef8b4dd773fcc0ada8a81e9d83a896d0890ed701405e4df"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/memory/bot_callback.go:125-135 | internal/store/memory/ephemeral_push.go:17-25 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_callback.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"334e18f30398616b029531e57683f45ade1f63f613901d6b5af54a15c63bacff"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (14 corresponding lines): internal/store/postgres/star_gift_entitlements.go:286-299 | internal/store/postgres/star_gift_lifecycle.go:730-743 \u2014 These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_entitlements.go"},"region":{"startLine":286}}}],"partialFingerprints":{"codehealthFindingId/v1":"75810fc8698c02d134255121be75317d267dcee7f1f009e753e4cce5637e9441"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/rpc/botapi_update_notifier.go:76-90 | internal/mtprotoedge/session_manager.go:259-270 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_notifier.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"35adc86140a60a9653b9ce45e0d8ecc2e5fb3e2bc8ad6e3354d0004826cdb21d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/memory/ai.go:84-92 | internal/store/memory/themes.go:55-63 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ai.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3d7bc6377b1a600e1c45840f8f8c509efbe5dc460cddba47f431e04a825d809"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (17 corresponding lines): internal/store/postgres/channel_member_helpers.go:188-204 | internal/store/postgres/channel_member_join.go:277-298 \u2014 These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_helpers.go"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"e13df1fb99f2738bd734a0b2016c06583ae4f6d144d355e2bab9883256da5b91"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/store/postgres/message_polls.go:127-137 | internal/store/postgres/channel_polls.go:232-238 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_polls.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"90ece489ca55443fde584174171ee054de9be4b3e64c0a15cd99e6624362e3fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/app/bots/miniapp.go:134-144 | internal/app/bots/service.go:957-968 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/miniapp.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"4948823f1cfa62bc3ed87bc00eb02b00cfe604a19e2e96711fc773d3d8a2f225"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/app/bots/verifierbot.go:1590-1596 | internal/app/bots/verifybot.go:1419-1425 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1590}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3c7578548991d2bef4c4522899d63d460fc4a97552f1a068be70958c8bd4d1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (4 members, 12\u002B corresponding lines): internal/app/files/upload_gc.go:19-39 | internal/app/rating/worker.go:33-44 | internal/app/verification/worker.go:30-41 | internal/rpc/groupcall_sweep_dispatcher.go:28-39 \u2014 These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/upload_gc.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"803b7d8a1b3f8d31cb747b9bded6106038b16e65c3e8faa6e252187037475513"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (6 members, 7\u002B corresponding lines): internal/app/account/phone_change.go:332-338 | internal/app/chatlists/service.go:828-834 | internal/app/groupcalls/service.go:275-281 | internal/otpdelivery/delivery.go:125-131 | internal/store/code.go:96-102 | internal/store/postgres/channel_invite_exported.go:577-583 \u2014 These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 7 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/phone_change.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"7db5e1fb314936a0510e9df9549cb2edf24d15d011f8a1f0326fb9ee80f3096c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (13 corresponding lines): internal/rpc/auth.go:171-183 | internal/rpc/messages_received.go:13-25 \u2014 These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e6814feaf5c29a4b6b119e8bf07d26c75ebda075f149562c312d3a858b210a3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/rpc/channel_full_bot_cache.go:152-162 | internal/domain/moderation.go:479-486 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_full_bot_cache.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"200da4d2778a1e7dd32df7233fd849643db6640168a3a8c411cab139be77ee68"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/rpc/channel_interest.go:166-178 | internal/rpc/phone_group_call_updates.go:207-216 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_interest.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c69fdfdad8af4b735573c9a27781d7aeaf79b91a87cf107a32fdb5072775756"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/rpc/convert_business.go:435-443 | internal/rpc/convert_messages.go:356-364 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_business.go"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"e434626c23dbe0bfe7267499693d8678078dbe6551081cbf2a9eba354ef39c4c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/memory/contacts.go:36-46 | internal/store/memory/dialogs.go:481-491 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0bc96fa0888f7bb29625346e4a984f0376211e679a26df4806c7c03bcbc1880"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/media_codec.go:122-131 | internal/store/postgres/update_event.go:974-983 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_codec.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"89f65bf72df520c17fecc09c34f2995cc313bda77e72088f1de088b1447ec60e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/app/files/blobcache.go:149-156 | internal/store/postgres/media.go:557-567 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/blobcache.go"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfd5911d4c0f56b0c61c0bdafc18dc394dba88ab9dbaf80495136d5c4bb37417"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/rating/service.go:329-341 | internal/app/verification/service.go:679-688 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/rating/service.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfc156bda10a34eeb295861188a4016eb19763f7c71eaf953e5f1dc455b2ef15"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): cmd/telesrv-admin/admin_command_runner.go:385-396 | cmd/telesrv-admin/adminusers.go:114-125 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/admin_command_runner.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d4b9d86ca320874d5301ce88c4a7dc826df17ec07cbd00fb5d90262569ecf0a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/readmodelcache/cache.go:522-534 | internal/app/messages/private_media_count_cache.go:111-121 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/readmodelcache/cache.go"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"0efbca920c2c5a50f0177f37edd3f5eff3346e6465d5a269bb5816da1cfe9ccf"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/store/memory/bot.go:219-229 | internal/store/memory/themes.go:114-124 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"072866578fc4322fd117267638f11b91627e55578fe01057163c495ea65efaf7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/media_codec.go:133-142 | internal/store/postgres/update_event.go:908-917 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_codec.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"0702c4651255c8a5b8d7d8594329f381b452923bed505b858eeb2a18ed2de222"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/media_codec.go:144-153 | internal/store/postgres/update_event.go:952-961 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_codec.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"106d3c6d678a13e582aa43d8f1679b2488ac7d8b94d0aa64e53f44ac1ae3034d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/store/postgres/star_gift_lifecycle.go:1873-1880 | internal/store/postgres/star_gift_upgrade.go:1106-1113 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1873}}}],"partialFingerprints":{"codehealthFindingId/v1":"c937ecafa1231241dc3bc53807f58fb4cc2e365efe66fad7d2865b80fb1f61a1"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/memory/password.go:538-549 | internal/app/files/sticker_management.go:423-431 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":538}}}],"partialFingerprints":{"codehealthFindingId/v1":"c29bf7e0bb9d0d0ff7fa31b89e9d87017c6d0f0940e7828a893cefda2e9b5e57"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (22 corresponding lines): internal/store/postgres/channel_reaction_unread.go:368-402 | internal/store/postgres/channel_read.go:1009-1030 \u2014 These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":368}}}],"partialFingerprints":{"codehealthFindingId/v1":"de10da5dda7235fc7f97e323933f6d00747469f7f38330032d85490fe57b914c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/postgres/media.go:197-205 | internal/store/postgres/media_refs.go:186-194 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"50b89fd096a67216abcbbd14f42f0d1be75df01246e28298307d8b9e37e70471"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/moderation/evidence.go:613-624 | internal/rpc/messages_reactions_send.go:452-460 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":613}}}],"partialFingerprints":{"codehealthFindingId/v1":"18effaba3d728f062a94d7410a19b12eddf3a215277b6a1ff49208a3f534e7fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): internal/rpc/payments_star_gifts.go:1857-1864 | internal/rpc/payments_star_gift_lifecycle.go:1055-1057 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1857}}}],"partialFingerprints":{"codehealthFindingId/v1":"de20829757d0586839a7ea76bf92bcd7c54838e06552a5a4570ad89603644714"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): internal/store/memory/channel_reactions.go:863-865 | internal/store/postgres/channel_reaction_helpers.go:246-248 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":863}}}],"partialFingerprints":{"codehealthFindingId/v1":"f699a04895fe796c2c70f23b5e4733ef22c7ca131e2ab3e99a39ac45b448f7d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (38 corresponding lines): internal/store/postgres/channel_read.go:907-957 | internal/store/postgres/channel_membership_batch.go:227-264 \u2014 These two members are one piece of code written twice and then edited apart: 38 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":907}}}],"partialFingerprints":{"codehealthFindingId/v1":"285941e86f1cfa4fb4098806e1eea213a0a86802756b432bb0040cce04c4835e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/store/postgres/scheduled_message.go:696-711 | internal/store/postgres/message_helpers.go:91-102 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":696}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd1b81828597650047b44e6dbbf41877eed1d61ee2bb1c6734939cee0a840917"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/auth/service.go:1664-1673 | internal/app/verification/service.go:1242-1251 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1664}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5b2ee41da108311f56ccb2b75f47ee8a419a768326aa8c7b45a41ea255d004c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/store/postgres/business.go:16-33 | internal/store/postgres/telegram_login.go:249-256 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/business.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4f8ed6b650f77931bba0efdf4c69d13be097f842f99ead543187ea97c3d23d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/store/postgres/story.go:2466-2475 | internal/store/postgres/themes.go:225-234 | internal/store/postgres/update_event.go:897-906 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":2466}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b4597b20ceaf8200e2523039bf84f808f9dfd88358073bc3d9c3b3fbc6eed32"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/app/contacts/service.go:685-694 | internal/store/postgres/user.go:965-975 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":685}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ba161973858f37a19b2b1848fd3ecf22d9153d452c8405232ee6594cfa3d437"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/postgres/channel_core.go:660-672 | internal/store/postgres/media_codec.go:14-23 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"aacc3602df3d8c608a4e80cc7db2462093eefc2159f9115500d9a6efeacad5d7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/postgres/channel_membership_batch.go:266-274 | internal/store/postgres/message_send_batch_actor.go:389-401 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_membership_batch.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bafd9f2296f72864c8f285ef7c936140453ce1bb56b677da5bd88c70711a538"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): cmd/bots/aiogramecho/echo.py:31-37 | cmd/bots/ptbecho/echo.py:66-72 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"8be2a410be8a162422060db8f252fb09ecf10ca4bcc03a60b35121e16020deac"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): cmd/telegramloginkeygen/main.go:285-291 | internal/app/auth/service.go:1923-1929 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telegramloginkeygen/main.go"},"region":{"startLine":285}}}],"partialFingerprints":{"codehealthFindingId/v1":"50507fce6c86f304375816e75787837c506cb622d62d987407d6852a0d135c84"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): internal/app/botverification/service.go:476-481 | internal/app/stargifts/service.go:499-504 \u2014 These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":476}}}],"partialFingerprints":{"codehealthFindingId/v1":"048e6a0e9fe3c70956ce3c3415216c9c0c7121dc0855a3bc4a68776c8e3a4b15"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): internal/app/channels/service.go:648-653 | internal/app/channels/service_groupcall.go:10-15 \u2014 These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":648}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dbe7836a363b949144fc820fafe5a90b31000e845c5d2d53f5bc6b49ff74030"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/memory/bot_callback.go:114-123 | internal/store/memory/inline_registry.go:194-203 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_callback.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"9df5c57c28365845f4686c3e8142eed4b35310f115f2f35ec670bf156f508661"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/store/postgres/bot_verification.go:124-130 | internal/store/postgres/verification.go:86-92 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb083c3bb84faf075d0c274424c58b033869e666c25a3fb6394d15091a142721"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): internal/app/botverification/service.go:456-461 | internal/app/stargifts/service.go:527-532 \u2014 These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"35a282ee8d57f31647efa6caab660a61e0d7730a69c467718ae3c7f61ef5cc80"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/chatlists/service.go:790-799 | internal/app/dialogs/service.go:1476-1484 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":790}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ba026fd33232c8b4be01a6b31f5764f1971bde72299a6129cb9f615a177a20b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/mtprotoedge/rpc_execution_budget.go:172-181 | internal/mtprotoedge/rpc_result_subscriber_budget.go:111-120 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_budget.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"6481dd9219fd89e37716fac0fe3b3a5279d1ac39713eb46a453972ebdf1ccc95"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/rpc/phone_conference.go:411-417 | internal/store/memory/poll.go:266-275 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_conference.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"c204110a860e8845abb948048d811a53ebee86492b5aa3290380bd9092c68723"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/rpc/presence.go:143-152 | internal/rpc/temp_key_cache.go:111-120 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7c88a04c0bda843d511bdb7b711532ad402382e4cacfb84c254e79fda78a76b"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): internal/store/memory/business.go:534-541 | internal/store/postgres/business.go:853-855 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/business.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"1082817d9c5162ee53cc8c66d3ccf062eed1ccce641eaa10e1ccd4d4b09307d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/store/postgres/business.go:799-808 | internal/store/postgres/story.go:2488-2497 | internal/store/postgres/update_event.go:919-928 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/business.go"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"145dba260ad3a31420720b5f5cd3c0f24e4f839691681c65108651ae5831fe58"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (12 corresponding lines): internal/hoststats/hoststats.go:119-131 | internal/rpc/presence.go:684-695 \u2014 These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/hoststats/hoststats.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4ee439cb76aaaabf917d1192f5fdefd0a0397bd1640570f1a9756f43ed39873"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 10\u002B corresponding lines): internal/rpc/messages_helpers.go:394-403 | internal/rpc/messages_reactions_helpers.go:167-176 | internal/rpc/stats.go:535-544 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_helpers.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"141c42bf9dbe49c6bb1acae690f218393e569c5fbc0a1f6261ceb584414c2155"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/store/memory/message_helpers.go:200-212 | internal/store/postgres/message_history.go:1013-1022 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_helpers.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"966afd62b8f61fca8f20148b81c77ef0b833ebd0d52f5107ef640b7f8a20c46a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/app/bots/miniapp.go:174-181 | internal/app/bots/service.go:971-978 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/miniapp.go"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"f377ff7971da26d2099c10a8ef7ca0fef643f73ee392faa00507992906bc5b88"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/botverification/service.go:407-415 | internal/app/verification/service.go:405-413 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"32f0da5953274d46f64184eda144c0d087fc36bf59120e144d895ca19927f54c"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/store/memory/ai.go:184-191 | internal/store/memory/themes.go:146-153 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ai.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"b05e861d078781b1fd5bbb42b99c3aba9e5166f2a1863f0186507b3f59b8fb20"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): internal/app/account/service.go:1029-1033 | internal/app/auth/service.go:593-597 \u2014 These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":1029}}}],"partialFingerprints":{"codehealthFindingId/v1":"99b5e08e96a5a631f1ce57d1d6bed3c0fc0a4e3351062ccb4ae0f91c5b376b90"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): internal/app/files/blobfs.go:217-222 | internal/identity/identity.go:218-223 \u2014 These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/blobfs.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"654aa71276db17165d233daaf3633c3903811f22701504fe8eeee6f73a8c208e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/app/langpack/seed.go:220-227 | internal/loadharness/mutate.go:538-545 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/seed.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"e08dfd99908f0f8505dc19f7771e8add95b7bb79b88d3b537ce6849613734e7f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/app/userprojection/contact_cache.go:1088-1094 | internal/store/memory/story.go:1697-1706 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":1088}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bb922003006cd389e499cc94e068ac6ebb849abc7cebec53b4b19bb9fabbc89"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 7\u002B corresponding lines): internal/rpc/convert_communities.go:47-53 | internal/rpc/rpc_projection_cache.go:247-256 | internal/rpc/send_media.go:1193-1199 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 7 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_communities.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e74e9d059eec0f95fb3e5856675be1c52918383040a0e9cb4c4626c09d9b079"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/rpc/convert_users.go:411-417 | internal/rpc/send_media.go:1185-1191 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_users.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"3dcaa7e0532e2d93bbea5858f5d8b0ccaf215e249e3de9a32c45e138d8e906c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (11 corresponding lines): internal/rpc/messages_forum.go:223-233 | internal/rpc/stories.go:3006-3016 \u2014 These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"b052ccfa1c40d206f22ea5bd5b7c04973e905d85ac9e8fe71711e751ed363ab0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/rpc/messages_polls.go:17-23 | internal/store/postgres/privacy.go:108-114 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"59a01ddef9092797e92e8c85b63ff501a18ccac56f4261776516033dba2ff790"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/store/postgres/bot_verification.go:1178-1184 | internal/store/postgres/verification.go:1071-1077 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":1178}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaeac7b747919e8a6b418b570e2df952101b5bb675f2f119a3f87f5329b9c801"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): cmd/catalogfetch/main.go:82-88 | internal/loadharness/report.go:228-234 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/catalogfetch/main.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4e5f5083a2895ef4ca5fd61799eaabefaf277b7cec0ca3b31e033abdc9d9a3f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): cmd/telesrv-admin/readstore.go:1596-1602 | internal/store/postgres/media_search.go:87-93 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1596}}}],"partialFingerprints":{"codehealthFindingId/v1":"54f2fe201889cb7ada2b2c40414fe067c58faa6806579f1497c6bf8e4ca57df6"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): internal/app/ai/service.go:799-808 | internal/app/themes/service.go:222-226 \u2014 These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":799}}}],"partialFingerprints":{"codehealthFindingId/v1":"85160d6f487476af688c47cd133ff81b41ecd7116f0fcd16f0b7ba0f63d1e9a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/domain/login_code_delivery.go:77-85 | internal/domain/login_welcome_template.go:51-62 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/login_code_delivery.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"15f1862faf88a00b77ba3afc08f77471b0a277a3f6b114096a158eaf47b1980e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/domain/boost.go:183-192 | internal/loadharness/dataset.go:418-428 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/boost.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"93a503d7f6f6e33b3bb8f8b9a69086d6e8b743a8f98a073c13ee8f7d03331c80"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/mtprotoedge/outbound.go:2761-2769 | internal/mtprotoedge/session_manager.go:1850-1858 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":2761}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf47e30c8ef374991f839f21c0427c57260542c93db938d07ffbbb5d9c4add37"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): internal/telegramloginhttp/handler.go:105-110 | internal/updatecdn/server.go:34-38 \u2014 These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"17947ca3e8533a8492cb8ecd58ea9636ceac2c1028b532478bb28b4179095b24"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): cmd/telesrv-admin/readstore.go:57-61 | internal/store/postgres/channel_helpers.go:1039-1044 \u2014 These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"84f816a95474192d821ac11c23b8d509d2f1f407f2b136cc4cbcdad5c9a109ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/app/account/business.go:505-511 | internal/app/bots/stickersbot.go:816-822 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/business.go"},"region":{"startLine":505}}}],"partialFingerprints":{"codehealthFindingId/v1":"baa3c0604a2066cb190ba90beb80caf76387ec0842303c34015986af63ef703f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (10 corresponding lines): internal/loadharness/rpc_retry.go:80-89 | internal/mtprotoedge/admission.go:157-166 \u2014 These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/rpc_retry.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc8534bd6ac82356cfc8b82e3c32a6b8f5521dab4cc0b18f10642abb043bee28"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/store/memory/channel_message_history.go:687-695 | internal/store/memory/message_history.go:493-501 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":687}}}],"partialFingerprints":{"codehealthFindingId/v1":"602b32bd779b7f653aa3659f575fde1a283f0d9867d5ad83f7a70e2250d71fd0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): internal/app/botverification/service.go:1507-1510 | internal/app/verification/service.go:1363-1366 \u2014 These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1507}}}],"partialFingerprints":{"codehealthFindingId/v1":"e369e9047d0ff6056e6c571a0ff1dc79855a3f376553dbae07604962a04fdce7"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 4\u002B corresponding lines): internal/rpc/channels_members.go:714-717 | internal/store/memory/channel_invites.go:991-994 | internal/store/postgres/channel_invite_helpers.go:7-10 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 4 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":714}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcf7d96cac6268c85a520297b03ebd59dd4356a393589c985bff69c25eb6f20d"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (8 corresponding lines): internal/rpc/fragment.go:234-242 | internal/rpc/payments_star_gifts.go:1445-1452 \u2014 These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/fragment.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"75bdf64ca0ad0a7d3dd497c21daef46f81acaea56aa9e3136740aac736a95263"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (5 corresponding lines): cmd/telesrv-admin/server.go:3011-3016 | internal/adminapi/server.go:1970-1974 \u2014 These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":3011}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d0f04b1fc2effb510a4d606759a1cc3d00e5ecc98fda51e0dbb37c7d6ca40bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): internal/app/broadcast/service.go:173-178 | internal/app/stargifts/service.go:506-511 \u2014 These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/broadcast/service.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"02533f627e2254614b5682c9c7777a52e7b2bb6c58ba5fb7d92c8c01513e44bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copies of one member (3 members, 4\u002B corresponding lines): internal/app/files/sticker_creator.go:694-697 | internal/store/memory/business.go:543-546 | internal/store/postgres/business.go:857-860 \u2014 These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 4 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":694}}}],"partialFingerprints":{"codehealthFindingId/v1":"8110890bcc0665b745c85006895490b98aa995b990ed5b7e7c71c6af99280254"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): internal/app/telegramlogin/service.go:950-956 | internal/telegramloginhttp/handler.go:710-719 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":950}}}],"partialFingerprints":{"codehealthFindingId/v1":"686b2651eef4a35d77b84d449a77d8b075cbb1f6670f29db316983620e0e976a"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/rpc/convert_updates.go:563-572 | internal/rpc/send_media.go:1175-1183 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":563}}}],"partialFingerprints":{"codehealthFindingId/v1":"c490b6a593fe31ff1e95198d442c8fb7080a6d50f05b2fb3f4b872ba4f0e2a9f"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/files/retention_purge.go:194-202 | internal/app/messages/service.go:313-321 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention_purge.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f3ceca2a167a64b5ba51332080c2776bd3b4585a3d5e015472520f548ecebd0"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/files/sticker_management.go:399-407 | internal/store/memory/dialogs.go:968-976 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_management.go"},"region":{"startLine":399}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1cf1652099fb29e651e7f0ccc8774764fe4488fa5b6b3cc983a0c9fcc4e9658"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): internal/mtprotoedge/rpc_execution_budget.go:195-198 | internal/mtprotoedge/rpc_result_subscriber_budget.go:136-139 \u2014 These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_budget.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3d3a0b345f06d008df7755ca018ea642eb7fa2dccc4dd91645cb9271477073e"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (4 corresponding lines): internal/store/postgres/account.go:148-153 | internal/store/postgres/peer_username.go:321-324 \u2014 These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"c57399adc8e268505f5715896c043382f9fedd32ef7605d0f8b5b39c65e945c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (7 corresponding lines): cmd/telesrv-admin/privateview_store.go:342-349 | internal/store/postgres/channel_message_history.go:1034-1040 \u2014 These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"55df40ab064a482819d1c5fe7a673fcbad403d98caac88bbe903d8f904f11dba"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/langpack/cache.go:77-85 | internal/readmodelcache/cache.go:592-600 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/cache.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"565112e27a293ee19f69f554a995e0d597686c956c983c1e34ad23f4570f20b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (9 corresponding lines): internal/app/langpack/cache.go:190-198 | internal/readmodelcache/cache.go:605-613 \u2014 These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/cache.go"},"region":{"startLine":190}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb04b774e1708d71dd37cd1fe28f34007a71b27135dc8c0f77940dedbe8a9915"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (6 corresponding lines): internal/app/dialogs/list_snapshot_cache.go:101-106 | internal/rpc/story_pinned_stories_cache.go:52-57 \u2014 These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":101}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ecbec6e4422eae7010b7a12ee87f8ef0859b4e1dc9164b83fe88a42fdaed2fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Edited copy of a member (3 corresponding lines): internal/loadharness/startup.go:620-622 | internal/rpc/convert_updates.go:8-10 \u2014 These two members are one piece of code written twice and then edited apart: 3 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below \u2014 the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members\u0027 grain \u2014 factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":620}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4a9f0d10295c4181bf46f1cd23a4d04678590afddec3fdbb40c5b01b206e27e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (139 lines \u00D7 2): internal/store/postgres/update_event.go:338-476 | internal/store/postgres/update_event.go:547-685 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/update_event.go:338\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e81bfce7639e37862ceb3ed48a0f21623c0ddbfdaec46777a03410ef25d1ee9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (118\u2013119 lines \u00D7 2): internal/store/postgres/dialog.go:139-257 | internal/store/postgres/dialog.go:483-600 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/dialog.go:139\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/dialog.go:602\u0060 calls \u0060dialogListHash\u0060 and \u0060internal/store/postgres/dialog.go:258\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"337e99833e25a331a792d786ae43d10aaf5cb9db74a9df67265739fcdcc235df"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (46 lines \u00D7 2): internal/store/postgres/message_history.go:654-699 | internal/store/postgres/message_history.go:726-771 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_history.go:654\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":654}}}],"partialFingerprints":{"codehealthFindingId/v1":"529aaefcef584ab39fe7c1b45fb661acbba6e2faac135f607a66297e1823205e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (4\u201342 lines \u00D7 6): internal/store/postgres/contact.go:637-655 | internal/store/postgres/contact.go:922-963 | internal/store/postgres/contact.go:982-1023 | internal/store/postgres/contact.go:1085-1126 | internal/store/postgres/media.go:1175-1178 | internal/store/postgres/media.go:1179-1182 \u2014 there are 6 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/contact.go:637\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":637}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce09564d78ebd54f7f41f4211b08a65e546b8c36cd1badc11f1d2f61d2c57936"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (31\u201334 lines \u00D7 2): internal/store/memory/contacts.go:122-155 | internal/store/memory/contacts.go:178-208 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/contacts.go:122\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff4ee15512acf32e49ad1fb29c3a6e319bab4b1e88951ec251d7cf8453c09e7e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (34 lines \u00D7 2): internal/store/postgres/channel_helpers.go:287-320 | internal/store/postgres/channel_message_history.go:447-480 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_helpers.go:287\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ee31d78978d19432fba2280c494df7cd83a05ee3d4569a196462764c919bf2c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (33 lines \u00D7 2): internal/app/files/sticker_admin.go:149-181 | internal/app/files/sticker_management.go:15-47 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/sticker_admin.go:149\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_admin.go"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"755b6ef800bc6916eb470b68b8f38334179b011409812d32bdf7c66f3ac8bbb4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (31\u201332 lines \u00D7 2): internal/rpc/convert_users.go:12-43 | internal/rpc/convert_users.go:46-76 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_users.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"8da232d457d2e89ae354e63db8ba02d3a7f2b60834b6b1f4fb6ed3342fd54ed9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (32 lines \u00D7 2): internal/rpc/stories.go:2124-2155 | internal/rpc/stories.go:2219-2250 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/stories.go:2121\u0060 calls \u0060addCandidateIDs\u0060 and \u0060internal/rpc/stories.go:2217\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2124}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0f69a9e66770346b290541da318e35012e7ba5d9ea98b845a4466572257dae1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (32 lines \u00D7 2): internal/store/memory/channel_helpers.go:196-227 | internal/store/memory/channel_message_history.go:297-328 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_helpers.go:196\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"121a19d454edcd9cdc6b89422c7d36f40d29b912d7bc56e004bcdda23740ef93"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (30 lines \u00D7 2): internal/rpc/messages_bot_no_state.go:120-149 | internal/rpc/messages_bot_no_state.go:201-230 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_bot_no_state.go:120\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"89c7c7aed9a028ebec72d8bd12bde88c428ff6a61320dcb660abf850b1e81374"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (35 lines \u00D7 2): cmd/telesrv-admin/server.go:877-911 | cmd/telesrv-admin/server.go:917-951 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":877}}}],"partialFingerprints":{"codehealthFindingId/v1":"793840e22d2ce440c2f4256b832d7106efd16329c079398878edb18d53bf73e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (29 lines \u00D7 2): internal/rpc/botapi_update_queue.go:269-297 | internal/rpc/botapi_update_queue.go:304-332 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/botapi_update_queue.go:303\u0060 calls \u0060botAPIMessageFromChannel\u0060 and \u0060internal/rpc/botapi_update_queue.go:268\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"40411fd28c5d7e791664c34e0cc87ed919282ca6e29d1548aaef6b8478ecad35"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (29 lines \u00D7 2): internal/store/memory/channel_dialogs.go:567-595 | internal/store/postgres/channel_dialogs.go:2175-2203 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"90259bc0fe0353c792bf3b9e802a8fa987ba27a633f2bf65f6d6a69ba821347b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (29 lines \u00D7 2): internal/store/memory/channel_invites.go:35-63 | internal/store/postgres/channel_invite_members.go:54-82 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_invites.go:35\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":35}}}],"partialFingerprints":{"codehealthFindingId/v1":"43be4029475e779d112f491029dcf8e90f92f73dd29564022c15689aa2f99845"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (28 lines \u00D7 2): internal/store/memory/groupcall.go:260-287 | internal/store/postgres/groupcall.go:460-487 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/groupcall.go:260\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ffa36521857f1c86bd687cb0e33381cbc5807c0811e2a42547f155ea9701221"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (27 lines \u00D7 2): internal/app/dialogs/service.go:436-462 | internal/app/dialogs/service.go:631-657 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/service.go:436\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":436}}}],"partialFingerprints":{"codehealthFindingId/v1":"a146bc287188be18b253b8acb90019803e62122fc2138a9d4481a945490db084"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (27 lines \u00D7 2): internal/store/memory/groupcall.go:581-607 | internal/store/postgres/groupcall.go:887-913 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":581}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0b099f529f2789e37d80b091dd7470ac04afcd98641fc624fb4bf6d4e10e9c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (26 lines \u00D7 2): internal/store/contact_reverse_batch.go:217-242 | internal/store/read_model_batch.go:219-244 \u2014 before extracting anything, compare \u0060internal/store/contact_reverse_batch.go\u0060 and \u0060internal/store/read_model_batch.go\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/contact_reverse_batch.go:217\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc4d8af6a0705021939f0700d0564e00a0c69f5f3318d8dc731541cda6510fb5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (26 lines \u00D7 2): internal/store/memory/channel_helpers.go:667-692 | internal/store/postgres/channel_helpers.go:985-1010 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":667}}}],"partialFingerprints":{"codehealthFindingId/v1":"00818aee7ecf6055e845592e7ebc1bb227596cc278f26e7594774dc7700f1aa9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22\u201325 lines \u00D7 2): internal/mtprotoedge/session_manager.go:1636-1657 | internal/mtprotoedge/session_manager.go:1802-1826 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1636}}}],"partialFingerprints":{"codehealthFindingId/v1":"57bd6d0db5b839e31c6c693278fdee12ee4dc9e5089ca62843f7ea908126d689"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 2): internal/rpc/bots_inline.go:1127-1150 | internal/rpc/bots_inline.go:1153-1176 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bots_inline.go:1127\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":1127}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fe9ed74141856724cb416d61d0ef89a9f5bc15dc5e347c9f1445017a4ac5d35"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 2): internal/store/memory/channel_helpers.go:230-253 | internal/store/memory/channel_helpers.go:256-279 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"b686d150377c5330e7be99727551c4133362cd2ddac41b9bcb5b425f574a3fa6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 2): internal/store/memory/channel_topics.go:218-241 | internal/store/postgres/channel_topics.go:229-252 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_topics.go:218\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea5498ae31e28b3a1e55f855f18c9deb7228ae3b7c4361304b020ff910441a6f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 2): internal/store/memory/login_code.go:31-54 | internal/store/memory/login_code.go:101-124 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/login_code.go:31\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb0cac07486e8bad983a0cdfedf720e0ec7b94bff440a6d272825e1cf2b67fa6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23 lines \u00D7 2): internal/compat/tdesktop/dialogs.go:148-170 | internal/compat/tdesktop/dialogs.go:174-196 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/compat/tdesktop/dialogs.go:148\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/dialogs.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"e58118e93e092eb119f64aac138fc9edf0465cf697b317cb4426d51794e5f2ee"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18\u201323 lines \u00D7 2): internal/rpc/account.go:485-507 | internal/rpc/account.go:519-536 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b68c37247146e3c26245d956118e8f2d6a64badab265c8d28e3d3bb0d4dac3b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20\u201323 lines \u00D7 2): internal/rpc/users.go:175-194 | internal/rpc/users.go:200-222 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/users.go:175\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f7ffc9505a09d91cabae21c1c43ab7196f4eb295eb1d96eb8ad8a54947f9b99"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23 lines \u00D7 2): internal/store/memory/channel_members.go:558-580 | internal/store/postgres/channel_member_admin.go:416-438 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":558}}}],"partialFingerprints":{"codehealthFindingId/v1":"a407d82ce29066629db8fa12633ed9c6e5e00fe7f03f82dec31c5c154c7dafdd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23 lines \u00D7 2): internal/store/memory/channel_message_delete.go:133-155 | internal/store/memory/channel_message_delete.go:177-199 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_delete.go:133\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"52710db34ca3494e22672ed12ccd2fa87222e53b6725448239b7f2b97787fae7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (3\u201323 lines \u00D7 3): internal/app/dialogs/list_snapshot_cache.go:301-303 | internal/store/memory/dialogs.go:992-1014 | internal/store/postgres/dialog.go:1259-1281 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/dialogs.go:992\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"499697926efbc03423c26bfc52a6b547e0215a47d0eff543b917e374ecfa8714"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18\u201322 lines \u00D7 2): cmd/bots/botcheck/main.go:53-74 | cmd/bots/botdemo/main.go:75-92 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf0d55e247215745fdaf65697d46727eafc2769657ffc7976e3d1ebf0ac990f1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22 lines \u00D7 2): internal/rpc/stories.go:2100-2121 | internal/rpc/stories.go:2197-2218 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:2100\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/rpc/stories.go:2123\u0060 calls \u0060addCandidateIDs\u0060 and \u0060internal/rpc/stories.go:2220\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2100}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9bc135ac242ce4ce7da2ee6139fd62a0fbe3edb37fee243a877a24f1f90e68f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (22 lines \u00D7 2): internal/store/memory/channel_dialogs.go:494-515 | internal/store/postgres/channel_dialogs.go:2244-2265 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":494}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb582ba2bbb1d191f73b183dc2f988f5c4cc397af66c66f613538045ccc6094f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16\u201322 lines \u00D7 2): internal/store/memory/channel_helpers.go:559-574 | internal/store/postgres/channel_helpers.go:878-899 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_helpers.go:559\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":559}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5e98d613a0117f40808c83018922fc35cb63002d188f413ed84121e2aca5cf9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (23 lines \u00D7 2): internal/store/memory/channel_message_edit.go:227-249 | internal/store/postgres/channel_message_edit.go:381-403 \u2014 \u0060internal/store/memory/channel_message_edit.go\u0060 and \u0060internal/store/postgres/channel_message_edit.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 4 separate duplicated blocks between them, totalling at least 56 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d2eafca7968cab19de87e8d7588a55e1c2ece9eda339f81baa2c2209796352c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 10): internal/store/postgres/message_forward.go:124-144 | internal/store/postgres/message_history.go:194-214 | internal/store/postgres/message_history.go:670-690 | internal/store/postgres/message_history.go:742-762 | internal/store/postgres/message_history.go:802-822 | internal/store/postgres/message_history.go:874-894 | internal/store/postgres/message_history.go:946-966 | internal/store/postgres/saved_dialog.go:419-439 | internal/store/postgres/update_event.go:344-364 | internal/store/postgres/update_event.go:553-573 \u2014 before extracting anything, compare \u0060internal/store/postgres/message_forward.go\u0060 and \u0060internal/store/postgres/message_history.go\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_forward.go:124\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ad17df88f7a105a0801bdd956fe6fa266c722b949f3a0ab0242ede21c8696c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 3): internal/app/channels/service.go:2526-2546 | internal/app/users/service.go:979-999 | internal/domain/collectible_username.go:301-321 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/channels/service.go:2526\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2526}}}],"partialFingerprints":{"codehealthFindingId/v1":"dae4cfc0ab44d8e1afe90f5aaa4ea8aa6d1a37f75b156c9fa96574882ef80e4b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20\u201321 lines \u00D7 3): internal/store/postgres/active_channel_ids_batch.go:164-183 | internal/store/postgres/authkey_session_layer_batch.go:171-191 | internal/store/postgres/bootstrap_update_job_batch.go:182-202 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/active_channel_ids_batch.go:164\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"281d80289ca336ec19382b302e592af101183cacb01f5576a182bef53e62197d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): internal/mtprotoedge/outbound.go:1941-1961 | internal/mtprotoedge/outbound.go:1969-1989 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/outbound.go:1941\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1941}}}],"partialFingerprints":{"codehealthFindingId/v1":"997a4de5f7ba8ba6a6542f6a069b1b7d69940da5d13f677a1d9d1e4fdd28f7e6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): internal/mtprotoedge/rpc_rewrap.go:90-110 | internal/mtprotoedge/rpc_rewrap.go:143-163 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/rpc_rewrap.go:90\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_rewrap.go"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"69115a628c751c814a6e2203c6930910f6d9aed8a93fe01c62a9ec320b671ee2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): internal/mtprotoedge/session_manager.go:1659-1679 | internal/mtprotoedge/session_manager.go:1828-1848 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:1659\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1659}}}],"partialFingerprints":{"codehealthFindingId/v1":"25c02fed7c2b09469e3b54209809071d19ea1d0c2582497124e05a3cf5b9091e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): internal/store/memory/channel_members.go:1131-1151 | internal/store/postgres/channel_member_helpers.go:450-470 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1131}}}],"partialFingerprints":{"codehealthFindingId/v1":"df85eeabed306ee2b2f7258eaf77f3cbbb32cc3bef4184bf76e2de6ac91af9e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (38\u201340 lines \u00D7 2): internal/store/memory/message_forward.go:61-98 | internal/store/postgres/message_forward.go:78-117 \u2014 \u0060internal/store/memory/message_forward.go\u0060 and \u0060internal/store/postgres/message_forward.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 3 separate duplicated blocks between them, totalling at least 51 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_forward.go:61\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_forward.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"f862cc5875b07ead83bc6f4cdcf2e868bf84a21879ec674d4b8ef48d450801d9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (21 lines \u00D7 2): internal/store/postgres/media.go:1457-1477 | internal/store/postgres/media.go:1525-1545 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/media.go:1457\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":1457}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce2ba428e1b1073652d8df30e41167258ee3f9e9bb95011515f267b997b64825"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/loadharness/mutate.go:119-138 | internal/loadharness/startup.go:159-178 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"32ef9c7d4632682f9cd7f7f0b2cb74bcacde7ca1d60de4c1463fc8a4a6b5f04d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/rpc/users.go:697-716 | internal/rpc/users.go:735-754 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/users.go:697\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":697}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a2bc82af97d3fdb13eae532ae26593a3c7ffee0a7ae97b07b6ea92be246ec69"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/store/memory/channel_topics.go:125-144 | internal/store/postgres/channel_topics.go:151-170 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"9afd3e6b8bb8f91b4fee4459d1a59ec24e54826e147477ee08d96ae6b519d746"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (29 lines \u00D7 2): internal/store/memory/contacts.go:520-548 | internal/store/postgres/contact.go:1275-1303 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"8048ac60144401eeec25842f77abff30f8103406aeb3290cc9bf76d1541733b8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/store/memory/story.go:1511-1530 | internal/store/postgres/story.go:2354-2373 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1511}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c08b9d7a783382ba4c2b6af269f59496eb98b459e9ba7e368719e839e5f75f9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (27 lines \u00D7 2): internal/store/postgres/channel_helpers.go:258-284 | internal/store/postgres/channel_message_history.go:418-444 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_helpers.go:258\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6c334a6b266019471d14fea917372bd9534f5b16657770ec65e2f1b3e7ef063"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/store/postgres/collectible_username.go:361-380 | internal/store/postgres/collectible_username.go:442-461 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/collectible_username.go:361\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1cd8c5bd48ee4199dabbff9c69cda6cdd101c5fe583357e600f66bf967d84ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/store/postgres/media.go:913-932 | internal/store/postgres/media.go:957-976 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":913}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ee96f057f0860f05f72543a43f9f1faad746583c0dc511490ddd09b049d07cf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 3): cmd/telesrv-admin/server.go:2863-2881 | cmd/telesrv-admin/server.go:2944-2962 | cmd/telesrv-admin/star_gift_catalog.go:294-312 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:2863\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060string\u0060 to \u0060apiPath\u0060 in one and \u0060fileName\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2863}}}],"partialFingerprints":{"codehealthFindingId/v1":"65cbf9665a98d5a838f09a872262ea191092c009f92d364c2f426c218ad8487b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 3): internal/app/privacy/service.go:218-236 | internal/app/privacy/service.go:366-384 | internal/app/privacy/service_sparse.go:67-85 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f7a200d0ccad2edf0b2366b360607f87538feffe1ad9267d9613ab00a5cae1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): cmd/telesrv-admin/botverification.go:566-584 | cmd/telesrv-admin/verification.go:244-262 \u2014 before extracting anything, compare \u0060cmd/telesrv-admin/botverification.go\u0060 and \u0060cmd/telesrv-admin/verification.go\u0060 as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 81 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"61653e57bb15d750864f6684df53d04b4df32a92248e07962283b6f7e216cfe4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/app/files/appearance_seed.go:142-160 | internal/app/files/seed_state.go:169-187 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/appearance_seed.go:142\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"48333fd0d2796687132fc831b099193a9999586e3b727c90729a353989f0e8e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/app/messages/business_automation.go:325-343 | internal/domain/business.go:270-288 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":325}}}],"partialFingerprints":{"codehealthFindingId/v1":"7db690394b0fe0bed1f321fa74005f374e8a135f73d63b1d03719a6eaf97b559"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17\u201319 lines \u00D7 2): internal/mtprotoedge/same_port_mux.go:83-101 | internal/mtprotoedge/server.go:865-881 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/same_port_mux.go:83\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/same_port_mux.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4e2cbb2bb48d6e30cecd8b2ff95eb76435215ab35d814818c1cc3e50dcd33c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 2): internal/mtprotoedge/session_manager.go:320-343 | internal/mtprotoedge/session_manager.go:400-423 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:320\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":320}}}],"partialFingerprints":{"codehealthFindingId/v1":"d689820bfc6f4e94c459f950bf62cbff5916abe0587afa0a2d871a9e36145990"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201319 lines \u00D7 2): internal/mtprotoedge/session_manager.go:1889-1907 | internal/mtprotoedge/session_manager.go:1924-1937 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:1889\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1889}}}],"partialFingerprints":{"codehealthFindingId/v1":"1303d06465d686bee787e2dce9aa594142944b50dbd322b357e1cb05cae3fec9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/rpc/channel_fanout_dispatcher.go:1236-1254 | internal/rpc/channel_fanout_dispatcher.go:1319-1337 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channel_fanout_dispatcher.go:1236\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1236}}}],"partialFingerprints":{"codehealthFindingId/v1":"e02c03419bc74c338770d8aa2b7390dc350b3571f815b3a9e97b85b9a29c1307"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/rpc/photos.go:38-56 | internal/rpc/photos.go:86-104 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"e960be206f9cfaddf19dcc00dec4e89ac5cf3c9c80a2a4c5aa5e6abd15103a88"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/store/memory/channel_monoforum.go:86-104 | internal/store/postgres/channel_monoforum.go:136-154 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/store/postgres/channel_monoforum.go:136\u0060 is reached only past a guard at line 96 that tests \u0060domain.ErrChannelPrivate\u0060 and leaves the function early, and \u0060internal/store/memory/channel_monoforum.go:86\u0060 reads \u0060domain.ErrChannelPrivate\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":86}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fbd9ca5cabd77295721ac67ae527ecc2809ddc8ec56cfabe3eb4fe2934a0953"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16\u201319 lines \u00D7 2): internal/store/postgres/message_send_batch_sql.go:186-201 | internal/store/postgres/message_send_hotpath.go:127-145 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_send_batch_sql.go:186\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_sql.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9ee0e34c29ae8e9a00b85d2f127aebc87e1d160678f4a6b3818d428b788453b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 3): internal/rpc/messages_compat.go:419-436 | internal/rpc/story_peer_projection.go:509-526 | internal/rpc/story_peer_projection.go:533-550 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_compat.go:419\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_compat.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdc61b0b9f220f52d2e721b0e4cd000a4f774c85ca7d0248bea97bc58b5ff28f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 3): internal/store/postgres/channel_message_delete.go:339-356 | internal/store/postgres/channel_message_delete.go:408-425 | internal/store/postgres/channel_topics.go:430-447 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":339}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa46f6364d37591ff51b6ad2352e342f4d33f42d50137b723480614fc02daa79"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): cmd/walletminiapp/main.go:375-392 | internal/rpc/messages_webview.go:738-755 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060string\u0060 to \u0060botToken\u0060 in one and \u0060startParam\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. Check import visibility before settling on that home: \u0060internal/rpc/messages_webview.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7349fadb09734ab6f0dfa1b9772309ab80c4109dfe0c971b8bc671dc62ab652"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/admin/service.go:3376-3393 | internal/web/server.go:1041-1058 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:3376\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3376}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f24f7bf1779b17d5c2bb8795ded86e094f1f03434e5e7ba825f3d911474f283"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/app/account/lifecycle.go:194-211 | internal/app/account/phone_change.go:49-66 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/app/account/lifecycle.go:212\u0060 calls \u0060TrimSpace\u0060, \u0060Errorf\u0060 and \u0060internal/app/account/phone_change.go:67\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"986541865b29c4b87ed49804c886bc51c4c9cb2c0754addd22aafb2db4afc6f2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/app/bots/premiumbot.go:78-95 | internal/app/donations/service.go:506-523 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/premiumbot.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"3036e5e684bfaf47f70c2c4212f678639c0c43b5bfdf6678857a792fcd47209d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16\u201318 lines \u00D7 2): internal/app/bots/verifierbot.go:953-968 | internal/app/bots/verifierbot.go:1004-1021 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/verifierbot.go:953\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":953}}}],"partialFingerprints":{"codehealthFindingId/v1":"8276fc4891e33d3ffcce3cc53b7ad00b4931c209f3978611a076884fc220ebe5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16\u201318 lines \u00D7 2): internal/app/userprojection/projection.go:196-211 | internal/app/userprojection/projection.go:455-472 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/userprojection/projection.go:196\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/app/userprojection/projection.go:195\u0060 calls \u0060cloneUsers\u0060 and \u0060internal/app/userprojection/projection.go:454\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecb36cb6e7bdc89e10f24c696a6a4f471fc392c0a83bdc4ee0c6aa9b2b3c19aa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/rpc/messages_bot_no_state.go:342-359 | internal/rpc/messages_send.go:805-822 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_bot_no_state.go:342\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4386d97f1b551fef6647fc73d9d5b1257b0f67139bd26bc9dbcdca87dccef2d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/store/memory/auth.go:118-135 | internal/store/memory/auth.go:420-437 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"c57926cb645678ac7710537359816578170322dd242e5afa05dbaa582ce95855"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/store/memory/botapi_update.go:419-436 | internal/store/postgres/botapi_update.go:685-702 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"64735a66c6842da4c0f6773fdf5594d3062979851e5b919fbe71f3ae7168f0fd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/store/memory/channel_members.go:1154-1171 | internal/store/postgres/channel_member_helpers.go:490-507 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1154}}}],"partialFingerprints":{"codehealthFindingId/v1":"474301259809573b2b79fe7663da873a0f855074812af857fc035a4d934a276e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17\u201318 lines \u00D7 2): internal/store/memory/channel_topics.go:243-260 | internal/store/postgres/channel_topics.go:253-269 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/memory/channel_topics.go:242\u0060 calls \u0060Unlock\u0060 and \u0060internal/store/postgres/channel_topics.go:252\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b5e828e211941ff4e0439021eb25c4540733ce2adea978b3d7296f9d03c2a45"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/store/memory/message_helpers.go:73-90 | internal/store/postgres/message_helpers.go:41-58 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_helpers.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3dbf1d1874a9147ab8f35d463a56ea6591dfc213c166847ec4ac51e717ae1c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/store/memory/telegram_login.go:327-344 | internal/store/postgres/telegram_login.go:666-683 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"88d3577670fa46f0317f674ae1ccc499346be371053b2a4940f8f4b4dadec579"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/store/postgres/moderation_cases.go:130-147 | internal/store/postgres/moderation_cases.go:220-237 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_cases.go:130\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":130}}}],"partialFingerprints":{"codehealthFindingId/v1":"f03f7a815cd161669ccfaa2cb2cd02b266a52f06e5ef6d07f0ff68c779523d04"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 4): internal/store/postgres/account.go:355-371 | internal/store/postgres/account.go:451-467 | internal/store/postgres/account.go:495-511 | internal/store/postgres/account.go:540-556 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"42ccdc06f4f1e0b11a8f696502a10db31fbf8415f8e056381781d35fe8b4887a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): cmd/telesrv-admin/botverification.go:106-122 | cmd/telesrv-admin/botverification.go:153-169 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/botverification.go:106\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"95c353f630aef1961a9ee41b3df4abb256d948dee9673709e3ce6f03724b7660"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/adminapi/server.go:840-856 | internal/adminapi/server.go:874-890 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":840}}}],"partialFingerprints":{"codehealthFindingId/v1":"7570f966e7a4981f51a0dc141a4055932b8b798e34d9c8fbdf33be95e5773cfe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/app/account/phone_change.go:295-311 | internal/app/auth/service.go:1885-1901 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/phone_change.go"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"7272877ce5bbd77da902b7f5d49326df1f50100fa92168096958d109a20e85d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/app/files/sticker_admin.go:210-226 | internal/app/files/sticker_management.go:67-83 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/sticker_admin.go:210\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_admin.go"},"region":{"startLine":210}}}],"partialFingerprints":{"codehealthFindingId/v1":"80ffd7b5b8a937f01968ebba6cd061b5075056cc90d8657b2b10d4f390cf0f45"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/app/moderation/legacy.go:84-100 | internal/rpc/messages_helpers.go:39-55 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/moderation/legacy.go:84\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/legacy.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4221e1f1b484c36acbf301311011644c17f0eae4cc2d9205321bd4e414cae6f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201317 lines \u00D7 2): internal/mtprotoedge/encrypted.go:713-729 | internal/mtprotoedge/layer_rpc_execution.go:172-186 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/encrypted.go:713\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":713}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c9895c4fa70f7b0bcb1f585c0eba870b2111b14cc715b98488bf4e783279b66"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201317 lines \u00D7 2): internal/mtprotoedge/encrypted.go:811-827 | internal/mtprotoedge/layer_rpc_execution.go:278-290 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/encrypted.go:811\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":811}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c1c4c68fee07b3cfb908e3dc0f4e9d3f181209d5ff837be7c5dc48015889ee8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/rpc/messages_bot_no_state.go:153-169 | internal/rpc/messages_bot_no_state.go:245-261 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b86bf231e1fb326841435b2d34f276804f1d1377a58bdd5eca0eb3dcaafeb65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/rpc/messages_bot_no_state.go:316-332 | internal/rpc/messages_send.go:771-787 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_bot_no_state.go:316\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"778239071267c43f191310e886a1a9b397af21b93c138834d21218532a7d48bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/rpc/payments_star_gifts.go:445-461 | internal/rpc/payments_star_gifts.go:641-657 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":445}}}],"partialFingerprints":{"codehealthFindingId/v1":"19c13935eaa5af2ad4b07d32ed35a1f539585f4d996cc2f409d626a80e90dd00"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/store/memory/channel_invites.go:748-764 | internal/store/postgres/channel_invite_import.go:129-145 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/channel_invite_import.go:126\u0060 calls \u0060Is\u0060 and \u0060internal/store/memory/channel_invites.go:746\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"f069692e8b229c3a3f3bf6dbad40077f93f01790fc9eaafc0648520dcf9ef399"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/store/memory/channel_message_edit.go:28-44 | internal/store/postgres/channel_message_edit.go:84-100 \u2014 \u0060internal/store/memory/channel_message_edit.go\u0060 and \u0060internal/store/postgres/channel_message_edit.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 4 separate duplicated blocks between them, totalling at least 56 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_edit.go:28\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"074bb6d6e2c7c5cb9c22d30fe5f5227cb7c351466dc79c63f216e2726b27afcb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/store/memory/langpack.go:221-237 | internal/store/postgres/langpack.go:396-412 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"de478d42db4defe3913059bf06b8c009a4bca46d039da1c6fef19d0025451411"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/store/memory/verification.go:329-345 | internal/store/postgres/verification.go:483-499 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/verification.go:481\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/memory/verification.go:328\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"34c98d276d041de851b9966f01fed982026a5b2046c3769fd60a07613340e38e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201316 lines \u00D7 3): internal/rpc/ephemeral.go:259-272 | internal/rpc/messages_reports.go:74-87 | internal/rpc/stories.go:596-611 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f5dd4f714065245bf34e984f7fe5fe7f34c1e7685ff6ac9d1d722fca82ac627"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/botapi/server.go:431-446 | internal/botapi/server.go:1049-1064 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"38d8463d8a5132e1b423609ecfda5d6a5407c11698027b26200cd909e6fb0a74"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/botapi/server.go:545-560 | internal/botapi/server.go:699-714 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/botapi/server.go:545\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"7549b2e71faa601a68a43e4462afe805e7323cbbdada1f20aa6541c51526d45b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/mtprotoedge/session_manager.go:2369-2384 | internal/mtprotoedge/session_manager.go:2458-2473 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:2369\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2369}}}],"partialFingerprints":{"codehealthFindingId/v1":"172925b063060b4f6585ef09f2a11490dca1975e8378314b9bce5ebf9fecd3c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/rpc/channel_interest.go:114-129 | internal/rpc/channel_interest.go:135-150 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channel_interest.go:114\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060r *Router) addOnlineChannelMemberships(channelID\u0060 in one and \u0060r *Router) removeOnlineChannelMemberships(channelID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_interest.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"d08bdfa05347597a572c62942001cfadf37de53ef8d768bf5d564eefe4c88e0d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/rpc/channels_legacy_chat.go:504-519 | internal/rpc/messages_no_forwards.go:100-115 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_legacy_chat.go:504\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"217af944fd9e5144eb31ea82a2e14109bc3e866d0f432ea4204448fb79ae4f25"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/rpc/media_count.go:65-80 | internal/rpc/media_count.go:87-102 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/media_count.go:65\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/media_count.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"19423285cd3d620ead3963e68885dc2b8825e51ab06ce98740e96716c0057882"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/rpc/messages_edit_geolive.go:84-99 | internal/rpc/messages_todos.go:233-248 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_edit_geolive.go:84\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e4f0a80a165901fa4dd1bb9b94bdee01fa9b1c17169bc86374f388fe68fde92"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/rpc/update_peer_refs.go:335-353 | internal/rpc/update_peer_refs.go:425-443 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b34c3b2e632848787fe21bada03b1c5979bb55d34bb72d5eefd704a4231ed5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/store/memory/botapi_update.go:448-466 | internal/store/postgres/botapi_update.go:706-724 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/botapi_update.go:448\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":448}}}],"partialFingerprints":{"codehealthFindingId/v1":"e85b0e8a9185dfbcc2bead3428a807f40b1f86fa17896a994b4ec5a65d5fb493"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/memory/channel_helpers.go:642-657 | internal/store/postgres/channel_helpers.go:960-975 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":642}}}],"partialFingerprints":{"codehealthFindingId/v1":"3076cd74af37699d0831817ddb12cef482db0d51533eecffda79bf6777ecb94c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/memory/channel_invites.go:365-380 | internal/store/memory/channel_invites.go:608-623 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_invites.go:365\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae9a187e318fb14d2cebd5df8999259635a97ec4691f70efaa7874a130f86d78"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/store/memory/channel_reactions.go:482-498 | internal/store/memory/channel_reactions.go:517-533 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_reactions.go:482\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ac805b5f0ca44c31d0dd57a76ee352f78569ce089a0a85e8309d8efd4b01af6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/memory/channel_read.go:256-271 | internal/store/postgres/channel_message_history.go:918-933 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"3422cdc47e363fed599e86f7384ef09972615a5e2660ed08f3ae9693a0fa5af3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/memory/community.go:1097-1112 | internal/store/postgres/community.go:1368-1383 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":1097}}}],"partialFingerprints":{"codehealthFindingId/v1":"97deafe4be1ce86f260d3f937a8217f4b0113435e03f2c62a9e9a33ec3ab0e07"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/memory/moderation.go:442-457 | internal/store/memory/moderation.go:510-525 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/moderation.go:442\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"a60ae7a69f6afe0ac25f5ca26a777fda9a6bd8d1327969e8f40a0d53ff0cad39"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15\u201316 lines \u00D7 2): internal/store/postgres/channel_invite_import.go:146-160 | internal/store/postgres/channel_member_join.go:77-92 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"d34504ebc49dd4357a6374b8f2ccbd7552f233994a3f338bacc8bb283fe29a51"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/postgres/channel_reaction_catalog.go:29-44 | internal/store/postgres/channel_reaction_catalog.go:65-80 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_reaction_catalog.go:29\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_catalog.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"398cb685ebda6fc6d33a90d444509d617c2d48b734007be1863852782f249408"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/postgres/moderation_registries.go:114-129 | internal/store/postgres/moderation_registries.go:236-251 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_registries.go:114\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba36466a5f05defa9f319bd1b65dcefc57cb52770fccaf2b8d44df64736da066"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/postgres/star_gift_lifecycle.go:451-466 | internal/store/postgres/star_gift_lifecycle.go:1204-1219 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"acda8f62bc0a7429a5fb543f805e7922a9a9ddd4b7b060bd7e387ddb2e8634b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/postgres/story.go:1673-1688 | internal/store/postgres/story.go:1728-1743 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/story.go:1673\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1673}}}],"partialFingerprints":{"codehealthFindingId/v1":"b24b0a5dc397710635f91b358e827edccb7266a65a1af6e311251206ad371a00"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 3): internal/app/dialogs/service.go:842-856 | internal/store/memory/channel_dialogs.go:474-488 | internal/store/postgres/channel_dialogs.go:2077-2091 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/channel_dialogs.go:2092\u0060 calls \u0060clonePeer\u0060 and \u0060internal/store/memory/channel_dialogs.go:489\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":842}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9da26d52cc8fac7fce43db932eecbaf7233450a33d6581ca0d087454cef7488"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 3): internal/loadharness/mutate.go:100-114 | internal/loadharness/snapshot.go:110-124 | internal/loadharness/startup.go:144-158 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/loadharness/startup.go:142\u0060 calls \u0060resolveStartupProfile\u0060 and \u0060internal/loadharness/mutate.go:98\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5af4b8f436c8420b73221953351159e52a19111162b670c216c134d9ee4de56"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 3): internal/rpc/bot_verification_projection.go:116-130 | internal/rpc/fragment.go:311-325 | internal/rpc/story_peer_projection.go:592-606 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bot_verification_projection.go:116\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"702e8b377eaf64f0e48808ed2ab26ded9c78c9ba5ea29be18fe677b05f2f8735"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 3): internal/rpc/story_pinned_stories_cache.go:166-180 | internal/store/memory/story.go:1436-1450 | internal/store/postgres/story.go:2563-2577 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/story_pinned_stories_cache.go:166\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_pinned_stories_cache.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"3146afabf410bb23b42661b396f933fce435290f5172225062498ac575ddd6da"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): cmd/telesrv-admin/server.go:973-987 | cmd/telesrv-admin/server.go:1637-1651 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":973}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9b433ba4638891c9711b03078b69e30bf40326bf18783b555cae220787daf82"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): cmd/telesrv-admin/server.go:2036-2050 | cmd/telesrv-admin/server.go:2082-2096 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2036}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9ff21105b232e6afb4ef9f1bc1680073613060ba62dd8120cdaf8394ea96438"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): cmd/walletminiapp/main.go:202-216 | cmd/walletminiapp/main.go:232-246 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/walletminiapp/main.go:202\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"627f063df672904d3fa1cb5809fd38015ac1ed842b1dc6339fe0e01f8f02fb84"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201315 lines \u00D7 2): internal/app/channels/bot_member_ids_cache.go:68-81 | internal/app/channels/participants_cache.go:103-117 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_member_ids_cache.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4de7a7813c386104adfcea176b58d4dc22d74f75da1733f6b0fe87d1851084b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/app/files/appearance_seed.go:127-141 | internal/app/files/seed_state.go:148-162 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/appearance_seed.go:127\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"379f5b6d21489dc744e768242f6141197f2ecd14f29dd218ceaba917f462f249"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/app/files/retention.go:112-126 | internal/app/files/retention.go:193-207 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/retention.go:112\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":112}}}],"partialFingerprints":{"codehealthFindingId/v1":"07d81963c33abfe9070e05d326f2c3b14ca7d2cb7d6a79dbad339dc7ef0bf34e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/app/privacy/service.go:279-293 | internal/app/privacy/service.go:453-467 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/privacy/service.go:279\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":279}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c21ec2ccb880b8ffc9a9769d1b39c8c95df7e5b844ccc6b99cca23553868d5b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/app/rating/worker.go:55-69 | internal/app/verification/worker.go:52-66 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/rating/worker.go:55\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/rating/worker.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"c27e9db35618bd0deb5144977f0819dd098a06e9ea3a6755c5140b1cd8d5507f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14\u201315 lines \u00D7 2): internal/loadharness/mutate.go:141-154 | internal/loadharness/snapshot.go:139-153 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/loadharness/mutate.go:141\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"e360836dae68530d787030e361a67b5793ca06229a3ee5b1a9326b7f21555e9a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/account.go:1276-1290 | internal/rpc/convert_business.go:259-273 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/account.go:1276\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1276}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b169e3243c39532c55febb718b7ec8389115294e3d139514cd8980bddf5bfb6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/account_reports.go:20-34 | internal/rpc/account_reports.go:55-69 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_reports.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"31dd21fac82a941c1f05dd4ca834d3db8ff7246f8b9d10a497f4e16403a470b1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/bots_longtail.go:88-102 | internal/rpc/bots_longtail.go:110-124 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"b30c4423dd87ad9e73ae2c0051d97bdd796903bfb4f61dae253e02c6f60a6b33"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/channels_stubs.go:519-533 | internal/rpc/messages_helpers.go:518-532 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_stubs.go:519\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":519}}}],"partialFingerprints":{"codehealthFindingId/v1":"82d22e241a378cf90996d7e6393831be4f77ce7e0ee96d1e11782ad57744dab4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/contacts.go:278-292 | internal/rpc/contacts.go:312-326 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2f128be294ce9f81a75e1a3ef35a33777861162510d8b8a35ee93fc19bd71b8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/messages_dialogs.go:1053-1067 | internal/rpc/messages_dialogs.go:1103-1117 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":1053}}}],"partialFingerprints":{"codehealthFindingId/v1":"195c1543782e3e3e7c107289b43865f40fc6f4ce18a989a9146e93611e9f037b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/messages_webview.go:24-38 | internal/rpc/messages_webview.go:205-219 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"18eb0c5471e52c7d095e29aca7af096fb5ae3e62d1b9df6f673fd874192cc8fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/contact_reverse_batch.go:150-164 | internal/store/read_model_batch.go:152-166 \u2014 before extracting anything, compare \u0060internal/store/contact_reverse_batch.go\u0060 and \u0060internal/store/read_model_batch.go\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/contact_reverse_batch.go:150\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"82695fe0cb39c90ed03fd85dc81007641895fd14483574f2370f0abeeb42b548"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/memory/bot_verification.go:547-561 | internal/store/postgres/bot_verification.go:796-810 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/bot_verification.go:794\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/memory/bot_verification.go:546\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":547}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e1f91e9746c9372a37412b7687442a4bec972f312dc5beba2b9cd93ac2fbb5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/memory/bot_verification.go:608-622 | internal/store/postgres/bot_verification.go:859-873 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/bot_verification.go:857\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/memory/bot_verification.go:607\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":608}}}],"partialFingerprints":{"codehealthFindingId/v1":"64c084b6ab690ab4779c2e58b0d9fdde5b6598e52aea9688f9f3be7aeaecd4d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/memory/channel_invites.go:180-194 | internal/store/postgres/channel_invite_exported.go:56-70 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"54cc8b78b738b75423f1bf5a418510a60fe10029762593d5e7be6ff2cc1f1fe5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/memory/channel_invites.go:452-467 | internal/store/postgres/channel_invite_exported.go:313-328 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":452}}}],"partialFingerprints":{"codehealthFindingId/v1":"30665ee012ee358f68e0b045a95f3c349a20a6738f37aa648d5dae1dfa6432a2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/memory/channel_topics.go:329-343 | internal/store/postgres/channel_topics.go:349-363 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_topics.go:329\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"95e207757bbf77bc1825bd3b1ab323de13dd6d60f32c445bad90fb83e316b147"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/memory/channel_updates.go:143-157 | internal/store/postgres/channel_updates.go:470-484 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_updates.go:143\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"d149b3bcfe2c23ae6fcd6f13e7dd3a1ca0a40d759eb8c5f885d06b9b6a4c9cb4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/postgres/channel_updates.go:254-268 | internal/store/postgres/channel_updates.go:314-328 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_updates.go:254\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"f24faa44ad493275feba30b090825b57bc7f22d25af3406f4febdcd5c58703c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201315 lines \u00D7 2): internal/store/postgres/contact.go:316-330 | internal/store/postgres/contact.go:412-423 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/contact.go:316\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"faa28d03a485260e9b2b621f7a8602bc829f4dbfda4affa4999e547553ef6baa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/postgres/contact.go:807-821 | internal/store/postgres/media.go:1411-1425 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/contact.go:807\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":807}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8b15af8308269f02db24d0743371f2b810fd874611499bf3cfe47ade4767be3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/postgres/message_send.go:984-998 | internal/store/postgres/message_send.go:1002-1016 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Note what the matched lines are: every one of them assigns one field to another, so the block is a hand-written mapper between two data shapes rather than behaviour with a helper inside it. Extracting one shared function only works if both sites map the SAME pair of types in the same direction \u2014 check that first, because inverse or differently-typed mappers have no single function they can both call. Where they do not, the moves that exist are a generated or reflective mapper, a common embedded/base type the fields live on once, or accepting the run and covering it with a test that fails when a field is added to one side only. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/message_send.go:1001\u0060 calls \u0060applyCreateMessageBoxMetadata\u0060 and \u0060internal/store/postgres/message_send.go:1017\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":984}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfb2d597992558b332938d5c6d6fc37c3c5974bf9cd817afaf75de5decab2fbd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201315 lines \u00D7 2): internal/store/postgres/star_gift_private_projection.go:30-41 | internal/store/postgres/star_gift_private_projection.go:105-119 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_private_projection.go:105\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/star_gift_private_projection.go:44\u0060 calls \u0060privateStarGiftAction\u0060 and \u0060internal/store/postgres/star_gift_private_projection.go:121\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_private_projection.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"659038a0dcd43f080a523f3477e0a681ba28d0b63dc5c744276e1abadb4e7880"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/web/server.go:1106-1120 | internal/web/server.go:1131-1145 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":1106}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb0983e7fcda420b185a1255871afb16d6d4ba86129bad85b683dc19ebd9c845"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 8): cmd/telesrv-admin/readstore.go:491-503 | cmd/telesrv-admin/readstore.go:1081-1093 | cmd/telesrv-admin/readstore.go:1898-1910 | cmd/telesrv-admin/readstore.go:2135-2147 | cmd/telesrv-admin/readstore.go:2575-2588 | cmd/telesrv-admin/readstore.go:2682-2694 | cmd/telesrv-admin/readstore.go:3071-3083 | cmd/telesrv-admin/readstore.go:3412-3424 \u2014 all 8 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:491\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef40e6814dd44a59e6f14551d4e44a1be419c2948017ae1a65b7751ae57c379d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 6): internal/store/postgres/message_forward.go:161-174 | internal/store/postgres/message_history.go:705-718 | internal/store/postgres/message_history.go:777-790 | internal/store/postgres/message_history.go:849-862 | internal/store/postgres/message_history.go:921-934 | internal/store/postgres/message_history.go:993-1006 \u2014 before extracting anything, compare \u0060internal/store/postgres/message_forward.go\u0060 and \u0060internal/store/postgres/message_history.go\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfdccc981931e8cd2578bd8d804c35db48245cf50fc4419f67bdfb66da316696"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 4): internal/rpc/chatlists.go:55-68 | internal/rpc/chatlists.go:206-219 | internal/rpc/chatlists.go:248-261 | internal/rpc/chatlists.go:299-312 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/chatlists.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b769026c381f064118abe968e1b49d98daca06544ff087ea7301dbc0037d205"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): internal/app/botverification/service.go:372-385 | internal/app/rating/service.go:129-142 | internal/app/verification/service.go:365-378 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/botverification/service.go:372\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f8c680f484fb2e4ffd95c6ca15200ae03b745f87a307abcef9a41228b0e214b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): internal/app/files/photos.go:266-279 | internal/app/files/photos.go:770-783 | internal/app/files/photos.go:791-804 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/photos.go:266\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1bca0df182d2737039ec357a1fa09704eb6aeef62cfa7335696b2613d6f2529"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): internal/botapi/server.go:518-531 | internal/botapi/server.go:586-599 | internal/botapi/server.go:838-851 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":518}}}],"partialFingerprints":{"codehealthFindingId/v1":"0175e7f503c98fe14a613e272d3108c3e80e5c9030a21e50ce628e0674571196"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): internal/mtprotoedge/session_manager.go:1620-1633 | internal/mtprotoedge/session_manager.go:1764-1777 | internal/mtprotoedge/session_manager.go:1782-1795 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:1620\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1620}}}],"partialFingerprints":{"codehealthFindingId/v1":"73dc929de37dc0cc84df62956fb96f4b179a83b1a51a07f438a5a75e79773c24"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): internal/rpc/payments_star_gift_lifecycle.go:1095-1108 | internal/rpc/phone_group_call_updates.go:222-235 | internal/store/postgres/contact.go:1259-1272 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/phone_group_call_updates.go:222\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060originUserID\u0060 in one and \u0060userID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":1095}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f266b60988202ed388784683a74420ee9a4dbf27a5b6f4c648ffeabf0d1c104"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): internal/store/postgres/channel_reaction_unread.go:197-210 | internal/store/postgres/channel_read.go:674-687 | internal/store/postgres/channel_topics.go:943-956 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_reaction_unread.go:197\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d9b1a693d5ef98861a11a45285c413ca72ae00eca6a7309a52a83cc4f9451c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): cmd/telesrv-admin/readstore.go:1222-1235 | internal/store/postgres/broadcast.go:368-381 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:1222\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Check import visibility before settling on that home: \u0060internal/store/postgres/broadcast.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1222}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ea89e0f249fd1978300be6b030c6e2e45ae76c73d11941f91f29ecd0a4563b8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/adminapi/server.go:346-359 | internal/adminapi/server.go:606-619 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/adminapi/server.go:346\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":346}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d122473af12f653a01c54c64edd42143f0b8d6c574eed06df9b4b1c08af6e1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17\u201320 lines \u00D7 2): internal/app/auth/service.go:625-644 | internal/app/auth/service.go:744-760 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/auth/service.go:625\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/app/auth/service.go:743\u0060 calls \u0060TrimSpace\u0060 and \u0060internal/app/auth/service.go:624\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":625}}}],"partialFingerprints":{"codehealthFindingId/v1":"537a5d7aeba981ca7e238d040d17b1b6f98d05ae467fe7e3acc1b45abe2bed61"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 2): internal/app/userprojection/contact_cache.go:457-470 | internal/app/userprojection/contact_cache_sparse.go:147-159 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/userprojection/contact_cache.go:457\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":457}}}],"partialFingerprints":{"codehealthFindingId/v1":"de1e460e3dc4a04fdc6c4137877ebe1136080de622e3ab06f33060f31daa197a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/botapi/ephemeral.go:93-106 | internal/botapi/ephemeral.go:136-149 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"9af3c3ba7dec1b369c204380feeb57f95594e303676d905d2229c31999c2d090"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/mtprotoedge/inbound_layer_rpc.go:548-561 | internal/mtprotoedge/inbound_preflight.go:814-827 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/inbound_layer_rpc.go:548\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"50dd37a82e861809c83d7d71b7ca0cb20bb0354eee73b22aa029ca601ff317d2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 2): internal/rpc/auth.go:779-792 | internal/rpc/auth.go:821-833 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/auth.go:779\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/auth.go"},"region":{"startLine":779}}}],"partialFingerprints":{"codehealthFindingId/v1":"40909e1f39242a99e3be4b1428bc58377de0797f45ee11ad02127074f1597ba7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/botapi_gateway.go:525-538 | internal/rpc/botapi_gateway.go:762-775 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/botapi_gateway.go:525\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":525}}}],"partialFingerprints":{"codehealthFindingId/v1":"66d23385999bb6767464188c2316c4e05f79d211de13ea1774d110f89f397020"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/bots_inline.go:442-455 | internal/rpc/bots_inline.go:473-486 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bots_inline.go:442\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"217df2af907159f50d0a3edce7651344de26fd478b29df089a27484da87becca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201314 lines \u00D7 2): internal/rpc/channels_members.go:498-508 | internal/rpc/channels_members.go:538-551 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_members.go:498\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":498}}}],"partialFingerprints":{"codehealthFindingId/v1":"69adccd0de5093a976f979105e063d5731b06f0743c2e5aa25b7412447f6fe94"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/channels_settings.go:477-490 | internal/rpc/channels_settings.go:493-506 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"19aee4b554e15cb0d1e89884f73f438212ea063250e307eb7e0c7407c64e220a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/channels_updates.go:407-420 | internal/rpc/messages_forum_read.go:80-93 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_updates.go:407\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_updates.go"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fb2b0e9078747158e3a364ef38237495102271eac8c3409541f0796f83ab676"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/messages_dialogs.go:335-348 | internal/rpc/messages_send.go:1205-1218 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_dialogs.go:335\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"4817568aef9a010544429e9a6b7ca9aa198d3846609f62357ad577d6025b9958"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/messages_forward.go:761-774 | internal/rpc/stories.go:1351-1364 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":761}}}],"partialFingerprints":{"codehealthFindingId/v1":"f021b4f6fdbfe1ce7dca457a91b5b6cffee383f039e4382ca77e0fd2e88cb41b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/messages_history.go:14-27 | internal/rpc/messages_history.go:33-46 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"553bbdc05e21b56ef183907ae73b6cbab1fcc0c8caa0a7dbfce00c9af3753ff3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/messages_reactions_catalog.go:218-231 | internal/rpc/messages_reactions_catalog.go:232-245 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_catalog.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e2c7877a9c558918d3cb0b7c8bdb44e61eec070aac20ebc4284c1718c498a1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/messages_read.go:196-209 | internal/rpc/messages_read.go:219-232 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"04dabccbcf16578b32229fe0a94c4a64dce17cee738d313e3d5fcb3b6df91f99"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/payments_star_gift_lifecycle.go:566-579 | internal/rpc/payments_star_gift_lifecycle.go:608-621 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6e3338027e7121d1f1810a345194866fae04fb1b19a050aa25391a89227b8f8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/phone_group_call.go:200-213 | internal/rpc/phone_group_call_rtmp.go:122-135 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"c001194477cc888399a5249fd7e170fa06c1fe6d513b203a29c55376021776d3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/rpc/router.go:1365-1378 | internal/rpc/router.go:1396-1409 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1365}}}],"partialFingerprints":{"codehealthFindingId/v1":"178533d6b9949a97742ea354e6b3b29bd34769207a9cbf775e76055df7b21592"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/memory/bot_verification.go:965-978 | internal/store/postgres/bot_verification.go:1295-1308 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":965}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a11645754e6e44b60fff345bcbbefc26154742288af45151d436c272eb6b410"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13\u201314 lines \u00D7 2): internal/store/memory/channel_message_edit.go:85-97 | internal/store/memory/message_edit.go:75-88 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1f31c6516efaec9eb0f1eccae6cdbb6c692f45f2a094e17bf539e99c00e8cb7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/memory/channel_settings.go:794-807 | internal/store/postgres/channel_settings.go:1243-1256 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_settings.go:794\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":794}}}],"partialFingerprints":{"codehealthFindingId/v1":"167001add0145b5cf9922b56a585f9d99bf6cb20522145c46bb4af1ba2ed1adb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/memory/collectible_username.go:372-385 | internal/store/memory/collectible_username.go:437-450 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/collectible_username.go:372\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/collectible_username.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"2be5fdb219c1309f3095e31ea8a87f5d890d2f9d218bfb2b06c8016a946496c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/memory/moderation.go:199-212 | internal/store/memory/moderation.go:259-272 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/moderation.go:199\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad367c2872500507968cf63975d0ee794b65457c9c9f6a5b5abbd090a1e394d2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/memory/verification.go:875-888 | internal/store/postgres/verification.go:1248-1261 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":875}}}],"partialFingerprints":{"codehealthFindingId/v1":"601bdc6dd62ee64f5bdfe8faf0ea364fe7eca52561d05eff553d9370512b1f70"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/postgres/channel_boosts.go:353-366 | internal/store/postgres/channel_updates.go:501-514 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_boosts.go:353\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":353}}}],"partialFingerprints":{"codehealthFindingId/v1":"77078cf343f89d2e80a58287ff084e6cb9487326633e3457567ca8c455a7518d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/postgres/channel_member_list.go:350-363 | internal/store/postgres/channel_member_list.go:464-477 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_list.go:350\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/channel_member_list.go:364\u0060 calls \u0060Slice\u0060 and \u0060internal/store/postgres/channel_member_list.go:478\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_list.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"3685800c3f1f23d4377c65d4bcbd91d9e3b9c5079e6c2d4f380132f1a81d3390"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/postgres/contact.go:300-313 | internal/store/postgres/contact.go:396-409 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/contact.go:300\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"79d34e6023984c3296abd86dd2e90bdc973731c6e357d16ea4fa07dcdabfd676"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/postgres/contact.go:1021-1034 | internal/store/postgres/contact.go:1054-1067 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/contact.go:1021\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":1021}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e718d402ad885a59b9a74a338152d1ea4ffc8b3935f5110dc76fb2f82ba3cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201314 lines \u00D7 2): internal/store/postgres/message_send.go:307-318 | internal/store/postgres/message_send.go:397-410 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_send.go:307\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"b50d6971ff33a3a979b44538ddc26c6d51e38b5c68f4fbf9e4617a85b37c4a05"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/postgres/star_gift_craft_auction.go:146-159 | internal/store/postgres/star_gift_craft_auction.go:182-195 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_craft_auction.go:146\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d86a9bb8db7add01071f3b343d1b0a6ae332e803413c7266f34ce2fea6e9e6d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/postgres/star_gift_lifecycle.go:1736-1749 | internal/store/postgres/star_gift_lifecycle.go:1855-1868 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_lifecycle.go:1736\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1736}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c37d8a9a83098879c07ab6342a14aabd4e2a8cec04f4a371e1ca23481ad3ccb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 7): internal/store/postgres/message_forward.go:158-170 | internal/store/postgres/message_history.go:702-714 | internal/store/postgres/message_history.go:774-786 | internal/store/postgres/message_history.go:846-858 | internal/store/postgres/message_history.go:918-930 | internal/store/postgres/message_history.go:990-1002 | internal/store/postgres/saved_dialog.go:460-472 \u2014 before extracting anything, compare \u0060internal/store/postgres/message_forward.go\u0060 and \u0060internal/store/postgres/message_history.go\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"de3f8f86cbcd649b45c339148cd6de48a1fab8fbfa8fb888f219eb57f1a44d1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 6): internal/store/postgres/channel_settings.go:585-597 | internal/store/postgres/channel_settings.go:722-734 | internal/store/postgres/channel_settings.go:771-783 | internal/store/postgres/channel_settings.go:905-917 | internal/store/postgres/channel_settings.go:941-953 | internal/store/postgres/channel_settings.go:989-1001 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"a65d6577d680fcbe83f89136147b786a40172f91a62e820c59c6a85ebebd48e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): cmd/telesrv-admin/botverification.go:117-129 | cmd/telesrv-admin/botverification.go:164-176 | cmd/telesrv-admin/verification.go:44-56 \u2014 before extracting anything, compare \u0060cmd/telesrv-admin/botverification.go\u0060 and \u0060cmd/telesrv-admin/verification.go\u0060 as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 81 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb0d95c9c5dd5443fe31730b75eff6b681585b131079a60181576acb27629308"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 3): cmd/telesrv-admin/server.go:540-558 | cmd/telesrv-admin/server.go:2370-2388 | cmd/telesrv-admin/server.go:2415-2433 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:540\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfc2021122f13733c5e6c251cd756dd13df8732b8a23419d4bb9c6c71cc373bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): internal/loadharness/mutate.go:96-108 | internal/loadharness/seed.go:62-74 | internal/loadharness/snapshot.go:106-118 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/loadharness/mutate.go:96\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":96}}}],"partialFingerprints":{"codehealthFindingId/v1":"b484cded36b110d0734f58a7711c450bbacbd9a481bd03eee2bd9d8345c9f8e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201313 lines \u00D7 3): internal/rpc/messages_edit.go:138-150 | internal/rpc/messages_edit_geolive.go:85-95 | internal/rpc/messages_todos.go:234-244 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_edit.go:138\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/messages_edit.go:137\u0060 calls \u0060Now\u0060, \u0060Unix\u0060 and \u0060internal/rpc/messages_edit_geolive.go:84\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"abcf1df4e612b8d823f69b6999e69f45b95a5e67a6962ba331e973e8c960833c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): internal/rpc/payments_star_gift_collections.go:120-132 | internal/rpc/payments_star_gift_collections.go:146-158 | internal/rpc/payments_star_gift_collections.go:167-179 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gift_collections.go:120\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_collections.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"5619313beb9ec17edb05315eed9167a9b5c1129e926a3452f2bc2125f13fb719"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): internal/store/memory/channel_members.go:912-924 | internal/store/postgres/channel_member_list.go:408-420 | internal/store/postgres/contact.go:428-440 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:912\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/channel_member_list.go:422\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/postgres/contact.go:441\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":912}}}],"partialFingerprints":{"codehealthFindingId/v1":"94b4c2ab60c3ab52a8f189da376fa7327b87028ef7face1ee7639ebee15e2ea2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): internal/store/postgres/collectible_username.go:183-195 | internal/store/postgres/collectible_username.go:295-307 | internal/store/postgres/collectible_username.go:386-398 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a0eb4603adf705c55bd7ed3bb52430fa36d0266b62d74347251d14116e227ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): cmd/telesrv-admin/publicbranding.go:52-64 | cmd/telesrv-admin/serversettings.go:95-107 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/publicbranding.go:52\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/publicbranding.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdd5c5d9f8f4ea63975ab07d84a9366e4410c9feac6974e9eaf4ca9af4db40d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201313 lines \u00D7 2): internal/app/account/service.go:927-939 | internal/app/account/service.go:994-1003 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":927}}}],"partialFingerprints":{"codehealthFindingId/v1":"5011d1b0256f38ba4f4ef4217dbc3a1ea77f7c1ee2a6ae476fe2091d773b355f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/app/ai/service.go:471-483 | internal/app/ai/service.go:536-548 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/ai/service.go:471\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":471}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7187b6e1d7190392eb8f8a110f87df203129bdc32b230b8c39e2052c10d193b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/app/userprojection/contact_cache.go:409-421 | internal/app/userprojection/contact_cache_sparse.go:69-81 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/userprojection/contact_cache.go:409\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"8660c93fec9687305e727c7c213d3876e00f425888357d99acf214c07404afa6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/app/userprojection/projection.go:179-191 | internal/app/userprojection/projection_sparse.go:104-116 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/userprojection/projection.go:179\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd67c850ecccb7f8a8ddbddeee2dda043813530908c9e7ee67495c2001685829"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/domain/star_gift.go:1456-1468 | internal/domain/stars.go:269-281 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1456}}}],"partialFingerprints":{"codehealthFindingId/v1":"60f2cc224d35f779df48484e36d1d3ea717c9283ec5c4115afa7f218b87b3ed6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/loadharness/run.go:1266-1278 | internal/loadharness/startup.go:329-341 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/loadharness/run.go:1266\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1266}}}],"partialFingerprints":{"codehealthFindingId/v1":"351c32fc2038796c86c81a4c6cbe22d4af8f70628d5bcb2046b1b3bedcb80613"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/mtprotoedge/rpc_rewrap.go:171-183 | internal/mtprotoedge/rpc_rewrap.go:202-214 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/rpc_rewrap.go:171\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_rewrap.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"819b376f5fb3a1fa3ff5aeccbe24a80ac0e1fe10d334561fa3c3ce772951b04c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/account_themes.go:133-145 | internal/rpc/account_themes.go:169-181 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_themes.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffaccacdffc504c2d9a8a3e481b01ecc91216008f9d9daf1ba24bb0da8002bba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/encrypted_files.go:68-80 | internal/rpc/encrypted_messages.go:49-61 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/encrypted_files.go:68\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_files.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"354dc46de2ee2fa10d3644d8278742e1c141c8ed12dd4231f8b80369c0c3a7f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/messages_reactions_lists.go:275-287 | internal/rpc/messages_read.go:115-127 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_reactions_lists.go:275\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/rpc/messages_reactions_lists.go:275\u0060 is reached only past a guard at line 263 that tests \u0060req.AddOffset\u0060 and leaves the function early, and \u0060internal/rpc/messages_read.go:115\u0060 reads \u0060req.AddOffset\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_lists.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccb6f0ab2395c91f9dcf0358b54435a4b85933938e7fe99daab2585393f8a53a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/messages_send.go:1139-1151 | internal/rpc/messages_send.go:1175-1187 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_send.go:1139\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1139}}}],"partialFingerprints":{"codehealthFindingId/v1":"550a03d44891fa1edeeb98b59aa71f75ba72fa83bca7296543d75fe5855a3764"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/payments_star_gift_collections.go:45-57 | internal/rpc/payments_star_gift_collections.go:73-85 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gift_collections.go:45\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_collections.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3428623bcf0feee8930cfb52169b38f87d514c0f7d19282e0a6639d49c47796"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/phone_group_call.go:465-477 | internal/rpc/phone_group_call_scheduled.go:73-85 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/phone_group_call.go:465\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/phone_group_call.go:464\u0060 calls \u0060pushChannelStateToMembers\u0060 and \u0060internal/rpc/phone_group_call_scheduled.go:69\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":465}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0d6c3c87c5a9b92954cd7e301ba5fd76c716712e500d5ba7d2674d888a5ed3b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/upload.go:38-50 | internal/rpc/upload.go:59-71 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/upload.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"17be090c73d39adac844dec497bc4eac92f4499188ca382327c2e9737175cbc6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/memory/channel_reactions.go:580-592 | internal/store/memory/channel_read.go:184-196 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_reactions.go:580\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":580}}}],"partialFingerprints":{"codehealthFindingId/v1":"6acc9629bc541e58ec2b7a351796a7ece30d1bc4c37394cced2263ae57788a57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/memory/code_cas.go:33-45 | internal/store/memory/code_cas.go:55-67 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/code_cas.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"b721cc8de52b7f3c246c3a715647478c985b509b103065d5b793315305436ed3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/memory/message_delete.go:78-90 | internal/store/postgres/message_delete.go:238-250 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_delete.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4ea662ca9dff71bbcc3888abbe0d0615ae0e1eb509b17a7db8f216406c66e84"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (3\u201313 lines \u00D7 4): internal/store/memory/message_reactions.go:237-249 | internal/store/memory/message_reactions.go:259-261 | internal/store/postgres/message_reactions.go:428-440 | internal/store/postgres/message_reactions.go:450-452 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_reactions.go:237\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b7a84064ac8e0b3b6b6fb7b87e351c0e06a5b7accd1f077f6155e657f8d84da"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/memory/message_send.go:377-389 | internal/store/postgres/message_send.go:890-902 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_send.go:377\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_send.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"71b17faf59ef8fe3ccf3fa6473611a2a6c34f2f6872df5b704bbff4cdda28ddb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/memory/story.go:1291-1303 | internal/store/postgres/story.go:2213-2225 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/story.go:1291\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1291}}}],"partialFingerprints":{"codehealthFindingId/v1":"d82a7ae01414a72e809f02d6d7b19e8200513d279cc267ef8cbaf4b11edcf9ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/channel_member_list.go:327-339 | internal/store/postgres/channel_member_list.go:433-445 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_list.go:327\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_list.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"a30fd29020c707544938a6139b6aa7c622dae25c60e34ebb7a514aecc924c6ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/channel_message_edit.go:432-444 | internal/store/postgres/channel_message_edit.go:528-540 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":432}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb673e1d6f0a8c6223f18f5569b6b21e2d46b42962ed522bf26916c1603544b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/collectible_username.go:309-321 | internal/store/postgres/collectible_username.go:400-412 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"a56446ec7ea4cfdf0f97439a5cb8463f13ffd6fdf9a5147231a4df4209959e9e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201313 lines \u00D7 2): internal/store/postgres/dispatch_outbox.go:131-142 | internal/store/postgres/dispatch_outbox.go:147-159 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dispatch_outbox.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"63d8605783cd72f42e4a090fe877579b1fabd49ea1b739301f016f7fbee378c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/dispatch_outbox.go:247-259 | internal/store/postgres/message_send.go:961-973 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/dispatch_outbox.go:260\u0060 calls \u0060Slice\u0060 and \u0060internal/store/postgres/message_send.go:974\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dispatch_outbox.go"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"972ab8bbbaca719531a8edff224a8207fe0d627ff7c1170c49d078d0b73ea662"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/message_pin.go:141-153 | internal/store/postgres/message_pin.go:289-301 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_pin.go:141\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbf779779afb04c6c0b64dec81bab2c82b78e1f400dee18806ef2acc7b3faadb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/moderation_cases.go:373-385 | internal/store/postgres/moderation_cases.go:572-584 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_cases.go:373\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d330b227672005d871123ea8931f0f20999bed7dba353d8a48a92c85ae81839"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 8): internal/admin/service.go:1412-1423 | internal/app/channels/service.go:2452-2463 | internal/app/peerview/cache.go:153-164 | internal/app/userprojection/durable_user_facts.go:131-142 | internal/domain/media.go:1038-1049 | internal/domain/media.go:1055-1066 | internal/rpc/channels_stubs.go:413-424 | internal/rpc/peer_projection_cache.go:267-278 \u2014 there are 8 copies across 7 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 8 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:1412\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1412}}}],"partialFingerprints":{"codehealthFindingId/v1":"b546707ee6389cbe014f2945309f4527d5dc2edad8dc9df3f6b20c49dec1fabb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 7): internal/app/bots/service.go:589-600 | internal/app/privacy/cache.go:257-268 | internal/app/privacy/service.go:476-487 | internal/app/userprojection/contact_cache.go:1141-1152 | internal/app/userprojection/projection.go:279-290 | internal/store/memory/channel_core.go:300-311 | internal/store/postgres/channel_core.go:647-658 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 7 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 7 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/service.go:589\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":589}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8cde3639ee1f3a396e0bd190cb82385d3a0a7715420afc25b906ce49db7b128"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u201312 lines \u00D7 5): cmd/telesrv-admin/botverification.go:131-141 | cmd/telesrv-admin/botverification.go:179-190 | cmd/telesrv-admin/donations.go:86-93 | cmd/telesrv-admin/server.go:2702-2712 | cmd/telesrv-admin/verification.go:59-70 \u2014 there are 5 copies across 4 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/botverification.go:131\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"d21608873d9ea6002988554c1f0eb83a4566f87a2dde0437adfe436da31ccd2e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 4): internal/loadharness/mutate.go:99-110 | internal/loadharness/seed.go:65-76 | internal/loadharness/snapshot.go:109-120 | internal/loadharness/startup.go:143-154 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/loadharness/startup.go:142\u0060 calls \u0060resolveStartupProfile\u0060 and \u0060internal/loadharness/mutate.go:98\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e6d488f92aca74579ad34d21cf31ae072b9fbdf7aa226bac822840d7ead17e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 4): internal/store/postgres/channel_member_admin.go:544-555 | internal/store/postgres/channel_member_admin.go:630-641 | internal/store/postgres/channel_member_admin.go:678-689 | internal/store/postgres/channel_settings.go:1097-1108 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_admin.go:544\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":544}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb011f8b2eb3554a5721b59f8b8cbbd5a20b24db3455bec66057a9fbe15ce923"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 4): internal/store/postgres/message_delete.go:565-576 | internal/store/postgres/message_delete.go:579-590 | internal/store/postgres/message_delete.go:593-604 | internal/store/postgres/message_delete.go:607-618 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":565}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d5ed73c169945e8cc0b033e5834b9976fa2fcc6c1fd713edc1b3d512a531935"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/app/channels/media_count_cache.go:110-121 | internal/app/channels/read_model_cache.go:70-85 | internal/app/channels/resolve_cache.go:72-83 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/media_count_cache.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"15a01a1da7871df61fc73c35434edaebe78201cc3f62cd4653a934515484d78f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201312 lines \u00D7 3): internal/app/privacy/service.go:277-288 | internal/app/privacy/service.go:451-462 | internal/app/privacy/service_sparse.go:145-154 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/privacy/service.go:277\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"a69cb321e5c1c252a0d79aa9ce46b763df140a94b43fcc925ad8826fdedcf7a3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/mtprotoedge/transport_ownership.go:134-145 | internal/mtprotoedge/transport_ownership.go:154-165 | internal/mtprotoedge/transport_ownership.go:178-189 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/transport_ownership.go:134\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/transport_ownership.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"47f2204551ee7ab8a9a97ca815879cb372513824a7c20b7db27f49722192c038"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/rpc/botapi_gateway.go:180-191 | internal/rpc/botapi_gateway.go:238-249 | internal/rpc/botapi_gateway.go:296-307 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/botapi_gateway.go:180\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/rpc/botapi_gateway.go:193\u0060 calls \u0060New\u0060 and \u0060internal/rpc/botapi_gateway.go:308\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":180}}}],"partialFingerprints":{"codehealthFindingId/v1":"473451b8357c50c3aa9c874e6e7de7aa216f7c665ddc9f3002a8c97127f98f17"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/rpc/channels_invites.go:380-391 | internal/store/memory/channel_core.go:284-295 | internal/store/postgres/channel_core.go:631-642 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_invites.go:380\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":380}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9d76cf68dcdb77f411d35840c2113eef3744db7ca975eca0da3bed8924c599a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/rpc/messages_scheduled.go:10-21 | internal/rpc/messages_scheduled.go:73-84 | internal/rpc/messages_scheduled.go:106-117 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_scheduled.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7bbcae342aba76a3788a8c7b92dcdd229aac454d88bbc01c0e11c5095bff52f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/rpc/messages_webview.go:72-83 | internal/rpc/messages_webview.go:191-202 | internal/rpc/messages_webview.go:262-273 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_webview.go:72\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ed47e305897b213ba9f55e3566199128f2bbdcb97595e88b109d5a004f7cd44"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/rpc/stories.go:2303-2314 | internal/rpc/stories.go:2359-2370 | internal/rpc/stories.go:2765-2776 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:2303\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2303}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5e512e619b3a46c5332cb0e5954f549756186a96b965ff605ac7ce158d06daf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/store/memory/channel_dialogs.go:571-582 | internal/store/memory/dialogs.go:850-861 | internal/store/postgres/channel_dialogs.go:2179-2190 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_dialogs.go:571\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"503af8432cca9e1bc7efcd111a7c89aa3cf247724c35d08c857a2b80f569fe28"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/store/memory/channel_message_delete.go:133-144 | internal/store/memory/channel_message_delete.go:177-188 | internal/store/memory/channel_topics.go:394-405 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_delete.go:133\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ad2a3c2b88df30b43319711613af732151812750641e48691f0152ad2d20afe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201312 lines \u00D7 2): cmd/bots/botcheck/main.go:104-115 | cmd/bots/botdemo/main.go:156-166 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"efb66fc778f688d89c07b52e2ba7e3abd4a051db248d723e35f655d0e3a596ea"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/app/ai/provider_http.go:105-116 | internal/app/ai/provider_http.go:136-147 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/ai/provider_http.go:105\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9236e31d796f69a5d89b55381a8f1166835c9ad6f8e7acedc338b8b8a87bde9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10\u201312 lines \u00D7 2): internal/app/auth/service.go:428-439 | internal/app/auth/service.go:451-460 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/auth/service.go:428\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":428}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebcb362b671f6fb60f15044181b290e84b772c67a68554b0c85f9cf838eba395"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/app/bots/miniapp.go:362-373 | internal/rpc/messages_webview.go:653-664 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/miniapp.go"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"65429a191738349d6cc9cd834154e9f106ac4cfc1f2b35f1deb0c7cb854c7ba7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/app/bots/stickersbot.go:323-334 | internal/app/bots/stickersbot.go:364-375 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/app/bots/stickersbot.go:322\u0060 calls \u0060handleStickersEmoji\u0060 and \u0060internal/app/bots/stickersbot.go:363\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9b7ecb73b316306ea28a7d0b06b6b6f62a1e3223da723f19100702f008bb1dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/app/donations/wallet.go:75-86 | internal/app/donations/wallet.go:100-111 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/donations/wallet.go:75\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/wallet.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"94cee70f123ee506717588234d14eef6f852b8c0f293b37ad4bfde7161a4cde1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/app/ephemeral/service.go:455-466 | internal/rpc/bots_callback.go:270-281 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":455}}}],"partialFingerprints":{"codehealthFindingId/v1":"0397d839178027b44188f299f9485caa30485d221978d20fb6456b7ba1b4573e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/app/files/retention.go:372-383 | internal/app/files/retention.go:416-427 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/retention.go:372\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"000cc861fd4aa799d8e75b11843618fb76b038abc512c66a550d78877a4a53be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/app/translation/service.go:209-220 | internal/app/translation/service.go:232-243 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/translation/service.go:209\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/service.go"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a20211d15b89044287aa1b9ae8a12d2c089d87da9bce3b84a077904c2684768"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/botapi/ephemeral.go:197-208 | internal/botapi/ephemeral.go:307-318 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"23784e150caff2b357ac54b39227d7585b0a2b281215678114fe12235a498c0a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/botapi/server.go:533-544 | internal/botapi/server.go:666-677 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":533}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0bc1112d428f318743a5469b23992237f1109214c5409c886b5a9d9b153a836"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/botapi/server.go:1165-1176 | internal/botapi/server.go:1249-1260 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/botapi/server.go:1165\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1165}}}],"partialFingerprints":{"codehealthFindingId/v1":"06464f69a69d86b0458b6a3a8e19b9f85e1ac9aaa2ada910121c58f05c48530d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u201312 lines \u00D7 2): internal/mtprotoedge/encrypted.go:670-681 | internal/mtprotoedge/layer_rpc_execution.go:137-144 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/encrypted.go:670\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":670}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ace9533ccd5bb3ce4405ae488cd41a5e9bcb78097cc6d0edcb71112ba4daca8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/mtprotoedge/session_manager.go:365-376 | internal/mtprotoedge/session_manager.go:1083-1094 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/mtprotoedge/session_manager.go:363\u0060 calls \u0060RLock\u0060 and \u0060internal/mtprotoedge/session_manager.go:1082\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdffbec23537430d8df86f983b72fe007c9a99ee7929a09a2ff5e6d7f32d7e31"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/mtprotoedge/session_manager.go:1739-1750 | internal/mtprotoedge/session_manager.go:1826-1837 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:1739\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1739}}}],"partialFingerprints":{"codehealthFindingId/v1":"96dd7bc9c61dcd406006ac37b4a01b255c9f94482211898fbdb6f05e9994c8b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/account_phone.go:12-23 | internal/rpc/account_phone.go:35-46 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_phone.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"298402a461cfefe5803df174651e0d610ea4afc8f76673a0da1e5905674c0c49"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/bots_longtail.go:251-262 | internal/rpc/bots_longtail.go:277-288 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8576015c653c70f342ddee726ea20df6721705070b549123fb3f78f77f8f632"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/bots_longtail.go:309-320 | internal/rpc/bots_longtail.go:337-348 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"e70ee86e9cdc1793c9c3e04f81f8bad704fc335f95b4dc9e8e7dc4ffd081845f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/channels_members.go:227-238 | internal/rpc/channels_members.go:521-532 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"2469c599ba6c80e6936a4becf112397a8f43422d220329b5897d6fff81ae5b1a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/channels_settings.go:82-93 | internal/rpc/channels_settings.go:96-107 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f0e0f9ad10d8f50957e18ca5f6c8ef006813f4f8f7d264e8470741b45964fed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/channels_settings.go:382-393 | internal/rpc/channels_settings.go:444-455 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_settings.go:382\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":382}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b37e4b579ba957f6f6fdf86becd3f76c373f8ad08879012a943638cec4d2195"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/channels_settings.go:410-422 | internal/rpc/channels_settings.go:462-474 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_settings.go:410\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd4607fd816b39d24acce2f24647853d0d2613aa981810578b8ed1b9ca0f816c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/convert_media.go:567-579 | internal/rpc/convert_media.go:625-637 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_media.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7ebd5a32b2db66ce32604861655d672cfd0c5e7c9085f732b07ea1a7d0362ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/messages_forward.go:77-88 | internal/rpc/send_media.go:302-313 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_forward.go:77\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"076fd03bdd1d83a9670c72a00416a4f3e2dec63fa2b7cbd4d0d7bb4306e016aa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/messages_send.go:362-373 | internal/rpc/messages_send.go:381-392 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_send.go:362\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e9cdd8675299d8b52c3f13a57c26f8b0eeb52188b77299ccd41998ca02d06f9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/payments_star_gift_collections.go:14-25 | internal/rpc/payments_star_gifts.go:1092-1103 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gift_collections.go:14\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_collections.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"babaf30b7b03fde827466873dfb93f521d534100f1b7e981d157b448fcb6cd32"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201312 lines \u00D7 2): internal/rpc/payments_star_gift_lifecycle.go:37-48 | internal/rpc/payments_star_gift_lifecycle.go:113-123 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gift_lifecycle.go:113\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"e61b7445821e8fdbfdb328531a6fe2ddb3ecc34eac387e6611d6d5a7647590ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11\u201312 lines \u00D7 2): internal/rpc/phone_group_call.go:492-502 | internal/rpc/phone_group_call.go:527-538 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":492}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c8cb55a15e2ca2dcf3b7ca5610ab66afab82ba7bd89876162fb95dc4f698517"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/stories.go:2318-2329 | internal/rpc/stories.go:2374-2385 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:2318\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2318}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6db03d6168ce2c0003e24eafb1769ad8bf9eb0ece2c2166ce56caf8a6a8603a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/bot_verification.go:1007-1018 | internal/store/postgres/bot_verification.go:1339-1350 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":1007}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4cbd95f4f27654e1af8dacf05ef961abea3b9d7d368136f5a464009cf564d95"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_helpers.go:291-302 | internal/store/memory/channel_helpers.go:328-339 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_helpers.go:291\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"b82d8dd945401ef171b3c2b8cf1d233921dd97eb4694a506f9919e8b56b9fa14"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_helpers.go:525-536 | internal/store/postgres/channel_helpers.go:809-820 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_helpers.go:525\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":525}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9be08bb0c07c1d07cc9a895ab50b7ed5e7d87a101746ee6745f47a333ff84e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_helpers.go:545-556 | internal/store/postgres/channel_helpers.go:858-869 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_helpers.go:545\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"bab4d3599309fd77e5eb8ec3226418db31c8442a254543a2618879e297b4e23d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_helpers.go:708-719 | internal/store/postgres/channel_helpers.go:1026-1037 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"765d66b0c42c97a9715ead51189a66ac5c9c971ae1ff37533574426e301115b2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_invites.go:668-679 | internal/store/memory/channel_members.go:816-827 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_invites.go:668\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":668}}}],"partialFingerprints":{"codehealthFindingId/v1":"c847fefdfdd543b99dbbca4f1a54e52089881c74c4f78f50a5a6775ee0c62949"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_members.go:304-315 | internal/store/postgres/channel_member_admin.go:44-55 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:304\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff7d802a3c3f5a7dd0e6dd0d0765fb50348b0b925e5c7375a079f1f8fc5a76a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_members.go:338-349 | internal/store/memory/channel_members.go:521-532 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:338\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/memory/channel_members.go:336\u0060 calls \u0060refreshChannelCountsLocked\u0060 and \u0060internal/store/memory/channel_members.go:520\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"0132aee5a88d4280457d5b216c95f75b8ce81a4f09cdc44f997805504ca3bba7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_message_edit.go:265-276 | internal/store/memory/channel_message_edit.go:338-349 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_edit.go:265\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"b85988bb8d5c7b65f9240d46b432051bf250a39dd45f910df62ca310cd81aaf6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_message_send.go:343-354 | internal/store/postgres/channel_message_send.go:390-401 \u2014 \u0060internal/store/memory/channel_message_send.go\u0060 and \u0060internal/store/postgres/channel_message_send.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 4 separate duplicated blocks between them, totalling at least 43 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":343}}}],"partialFingerprints":{"codehealthFindingId/v1":"78ab5d8e240d018aaac2a0380a3f7e7386d85ca383453f2ead8a965adc2d90d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_reactions.go:32-43 | internal/store/postgres/channel_reaction_messages.go:12-23 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe44f0d291a41dfd8a6bc2498e3674755d061c85d4451245f78d68a7204a12f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/channel_settings.go:750-761 | internal/store/memory/channel_settings.go:813-824 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":750}}}],"partialFingerprints":{"codehealthFindingId/v1":"68bcbb239a5897ffc8a78a933a1c2274650cac05e49d6ddb7030e34268e6c7da"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/contacts.go:51-62 | internal/store/memory/contacts.go:364-375 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/contacts.go:51\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"88d0eeef45d159def857d51ca2f491b61b735013b3814ff61fedd6bc529bda38"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/groupcall.go:289-300 | internal/store/postgres/groupcall.go:489-500 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/groupcall.go:289\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"24a03120648d8bfb04b1c62ddf053788f4ef77c8516afaddfac0b01b05617850"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/login_code.go:131-142 | internal/store/memory/login_code.go:151-162 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"7644d8b40336ede565635a9e6d16157a8acfce684c61db2f777dd894ac318396"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/login_code_delivery.go:42-53 | internal/store/postgres/login_code_delivery.go:44-55 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/login_code_delivery.go:42\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/memory/login_code_delivery.go:40\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/postgres/login_code_delivery.go:43\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code_delivery.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"168729185ce0398727f6773f88aaf7afcbede67c93d71e58bad30f4d80fb55d8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/media_search.go:121-132 | internal/store/memory/media_search.go:191-202 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/media_search.go:121\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a91ddbeacff6979dabdd61c861cd8b701209c95288fd160f56d1e40a6a5e192"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/media_search.go:175-186 | internal/store/memory/media_search.go:224-235 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/media_search.go:175\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a0309cb21d4429dd82293eb58f699f813036f41154d9660d755812055437217"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/media_search.go:246-257 | internal/store/postgres/media_search.go:110-121 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/media_search.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c45918adc25c4b0bebcbc74913dc8623aaa72fb30a104403e45e287921b2f84"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/message_no_forwards.go:47-58 | internal/store/postgres/message_no_forwards.go:47-58 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_no_forwards.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"95d4207a23d236250b3aa4b99f91af02a20b764bcc71213da159993ac98d58fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20\u201321 lines \u00D7 2): internal/store/memory/moderation.go:466-486 | internal/store/memory/moderation.go:541-560 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/store/memory/moderation.go:541\u0060 is reached only past a guard at line 527 that tests \u0060item.ID\u0060 and leaves the function early, and \u0060internal/store/memory/moderation.go:466\u0060 reads \u0060item.ID\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"d00e27aa91929034eb412d896091587b68d5b23fe4e44f7198b37fd8b50e9765"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/saved_dialog.go:52-63 | internal/store/postgres/saved_dialog.go:16-29 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"40997fb079263cb16bdbbbdab73d97c9f1a38be324ee58f41b4d62a43acd8121"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/star_gift.go:491-502 | internal/store/postgres/star_gift.go:656-667 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/star_gift.go:491\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"4537f4bfaed178f250c7c9f9118391cb93c10f66fb63edeecc06f65fcbbcb41b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/star_gift.go:676-687 | internal/store/postgres/star_gift_collectibles.go:697-708 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/star_gift.go:676\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":676}}}],"partialFingerprints":{"codehealthFindingId/v1":"d607728e6b07c04b8ae9c9eda3330b30cb07fd7ecd5b3f712112a38aceb2604d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/star_gift.go:826-837 | internal/store/postgres/star_gift_collectibles.go:961-972 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":826}}}],"partialFingerprints":{"codehealthFindingId/v1":"e21cdd1a89a9a89a96b1823b478a84e45aaa3a04c51f2db7d36b4b6ce36b4807"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/story.go:482-493 | internal/store/memory/story.go:529-540 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/story.go:482\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":482}}}],"partialFingerprints":{"codehealthFindingId/v1":"2528be26ccc99e92ae21930ccf36ca198ccb9a0820b6e72ceffd363d1268b702"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/story.go:891-902 | internal/store/postgres/story.go:1563-1574 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/story.go:891\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":891}}}],"partialFingerprints":{"codehealthFindingId/v1":"b82f87c2c7396c1f72083ccf999240da3e6526b3ba279f665239e3f22f241496"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/updates.go:205-216 | internal/store/memory/updates.go:245-256 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/updates.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"6df9a2e6c4f6c5867566d2602d7e8caf01ca7a83f151830fd2ecb3f473828e71"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/memory/verification.go:404-416 | internal/store/postgres/verification.go:588-600 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/verification.go:586\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/memory/verification.go:403\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":404}}}],"partialFingerprints":{"codehealthFindingId/v1":"23a36da3f90d011c2eba4a6ba05bd8a8aeaa215adf1a05132de9f70ccef4db90"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/channel_message_edit.go:213-224 | internal/store/postgres/channel_message_edit.go:347-358 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/channel_message_edit.go:344\u0060 calls \u0060replaceChannelMediaIndexTx\u0060 and \u0060internal/store/postgres/channel_message_edit.go:212\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"78506aaa748851acc836d101dab1801acc0997af22cffb2976db1ff844f705e2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/channel_reaction_messages.go:164-175 | internal/store/postgres/channel_reaction_messages.go:230-241 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f2d707b0c4fe824b13c6315c4d00a315db23b5425f3d2e92163451dc90630fc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/channel_settings.go:808-819 | internal/store/postgres/channel_settings.go:857-868 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":808}}}],"partialFingerprints":{"codehealthFindingId/v1":"678a74d8bbae9cb632ebad6e89dcd3c5e300e079c90a2574e0ba259345a79b95"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/channel_settings.go:1186-1197 | internal/store/postgres/channel_settings.go:1267-1278 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":1186}}}],"partialFingerprints":{"codehealthFindingId/v1":"f344a0d3e5f03957c6afd6165d38fda03dde6e9398b477301385a943c5638490"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/channel_topic_read.go:167-178 | internal/store/postgres/groupcall.go:827-838 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topic_read.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"78e147545804120c7c6d3d69ab3963286fe65450d877d3bf6f9caffb4c6c54d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/community.go:365-376 | internal/store/postgres/star_gift_craft_auction.go:941-952 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d57b1556fe3bcfe725b0e5c963b41f36b9b03c745d12db5113bc0156122a152"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/dialog.go:1170-1181 | internal/store/postgres/dialog.go:1232-1243 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/dialog.go:1170\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":1170}}}],"partialFingerprints":{"codehealthFindingId/v1":"dca3b2bf3763ac661535a86027790b7986351f98c3f4e446134220a6f5b9195d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/media.go:786-797 | internal/store/postgres/media.go:815-826 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/media.go:786\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/media.go:830\u0060 calls \u0060removeMediaReferencesByKeyTx\u0060, \u0060stickerSetRefKey\u0060 and \u0060internal/store/postgres/media.go:798\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":786}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc6ea94b52b24d1636eb335c7149660b6c07de6be4bf5d990bfc6340baf749fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/media.go:852-863 | internal/store/postgres/media.go:872-883 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/media.go:852\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":852}}}],"partialFingerprints":{"codehealthFindingId/v1":"caef76f9419f261262efdf1df91c84eef20752f320301aa3600e297c4677594a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/media_refs.go:226-237 | internal/store/postgres/media_refs.go:351-362 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/media_refs.go:226\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_refs.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"c612e81f88455eb6b79f140f65f3b8d568bbb061980c31ef12989f3a65a5b315"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/media_refs.go:396-407 | internal/store/postgres/media_refs.go:454-465 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/media_refs.go:396\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_refs.go"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"09dec52981cb6ae57232a5cca311b89d7f067bee5997d13a936640c501372db9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/star_gift_upgrade.go:119-130 | internal/store/postgres/star_gift_upgrade.go:466-477 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"6592988bf5af26071669537014f9aeaf313126bd338954db87bb6361807b587d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 10): internal/app/bots/service.go:588-598 | internal/app/files/seed.go:1098-1108 | internal/app/privacy/cache.go:256-266 | internal/app/privacy/service.go:475-485 | internal/app/userprojection/contact_cache.go:1140-1150 | internal/app/userprojection/projection.go:278-288 | internal/store/contact_reverse_batch.go:302-312 | internal/store/memory/channel_core.go:299-309 | internal/store/postgres/channel_core.go:646-656 | internal/store/postgres/community.go:1387-1397 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 10 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 10 times. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/contact_reverse_batch.go:313\u0060 calls \u0060Slice\u0060 and \u0060internal/app/bots/service.go:599\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":588}}}],"partialFingerprints":{"codehealthFindingId/v1":"caba82d723b969c0db3b06bc53d484673c089283b91085c174a1e9b18dee7fe4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 9): internal/store/postgres/message_forward.go:157-167 | internal/store/postgres/message_history.go:701-711 | internal/store/postgres/message_history.go:773-783 | internal/store/postgres/message_history.go:845-855 | internal/store/postgres/message_history.go:917-927 | internal/store/postgres/message_history.go:989-999 | internal/store/postgres/saved_dialog.go:459-469 | internal/store/postgres/update_event.go:452-462 | internal/store/postgres/update_event.go:661-671 \u2014 before extracting anything, compare \u0060internal/store/postgres/message_forward.go\u0060 and \u0060internal/store/postgres/message_history.go\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b31d827a4e9ad4ae9efb2667b92036284e5e39711262208441acd8ba3d38fd1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 7): internal/app/rating/service.go:201-211 | internal/rpc/account.go:2208-2218 | internal/rpc/channels_legacy_chat.go:121-131 | internal/store/postgres/bot_verification.go:451-461 | internal/store/postgres/dispatch_outbox.go:245-255 | internal/store/postgres/message_send.go:959-969 | internal/store/postgres/user_lane_actor.go:73-83 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 7 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 7 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/rating/service.go:201\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/account.go:2207\u0060 calls \u0060uniquePositiveDocumentIDs\u0060 and \u0060internal/store/postgres/message_send.go:958\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/rating/service.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"d19dc18bf1567ebf22c1ea056e00fa48ef6ac2c962760905ce95c92a5de10211"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 6): internal/mtprotoedge/session_manager.go:1620-1630 | internal/mtprotoedge/session_manager.go:1659-1669 | internal/mtprotoedge/session_manager.go:1741-1751 | internal/mtprotoedge/session_manager.go:1764-1774 | internal/mtprotoedge/session_manager.go:1782-1792 | internal/mtprotoedge/session_manager.go:1828-1838 \u2014 all 6 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":1620}}}],"partialFingerprints":{"codehealthFindingId/v1":"45cf4fbde09e88142dbfd1bec249c1b62ae117ee85171aee2bbf71d0f8f0010f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 5): cmd/telesrv-admin/privateview.go:573-583 | cmd/telesrv-admin/server.go:546-556 | cmd/telesrv-admin/server.go:588-598 | cmd/telesrv-admin/server.go:2376-2386 | cmd/telesrv-admin/server.go:2421-2431 \u2014 there are 5 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"45f308490c4352fb0dd373327a6c00194f200afcc316c6eda3dd0ffbc745f6db"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 5): internal/rpc/stories.go:1209-1219 | internal/rpc/stories.go:2302-2312 | internal/rpc/stories.go:2358-2368 | internal/rpc/stories.go:2648-2658 | internal/rpc/stories.go:2764-2774 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1209}}}],"partialFingerprints":{"codehealthFindingId/v1":"87e2757be142058fc52a0c02d17b58d9dd37119b4875ff34673dadb465392817"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/app/dialogs/service.go:1460-1470 | internal/store/memory/channel_dialogs.go:76-86 | internal/store/postgres/channel_dialogs.go:422-432 | internal/store/postgres/channel_dialogs.go:566-576 \u2014 there are 4 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/service.go:1460\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":1460}}}],"partialFingerprints":{"codehealthFindingId/v1":"c98882615bc10a75a732c4f3f3e67f236a4076b8c8ef0d74baf259b46c26e48d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/app/stories/service.go:488-498 | internal/rpc/stories.go:3133-3143 | internal/store/memory/story.go:1095-1105 | internal/store/postgres/story.go:2304-2314 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:3133\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":488}}}],"partialFingerprints":{"codehealthFindingId/v1":"fec51fed4e946f3fb2ffa8b428b6ac4bea59c58e56d3dad5970052884fcb1b16"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/rpc/bot_verification_projection.go:115-125 | internal/rpc/fragment.go:310-320 | internal/rpc/messages_monoforum.go:204-214 | internal/rpc/story_peer_projection.go:591-601 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bot_verification_projection.go:115\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"67149e6295152c99cf630419795e9e8d89084f7363885db0a90811ff918763da"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/rpc/bots_callback.go:31-41 | internal/rpc/messages_edit.go:55-65 | internal/rpc/messages_edit_geolive.go:20-30 | internal/rpc/messages_history.go:549-559 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfa6efac83aa1efec870b13f16b716178914863583a574a933fa87e679593401"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/rpc/channels_members.go:45-55 | internal/rpc/channels_members.go:518-528 | internal/rpc/channels_messages.go:317-327 | internal/rpc/channels_topics.go:16-26 \u2014 there are 4 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"127f2f05d3c3f7eabb0d0977c0cea2ac0ee3c3540110073bcd1a55fa33b183c8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/store/memory/bot_verification.go:1078-1088 | internal/store/memory/verification.go:985-995 | internal/store/postgres/bot_verification.go:1406-1416 | internal/store/postgres/verification.go:1319-1329 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":1078}}}],"partialFingerprints":{"codehealthFindingId/v1":"db54bac77f298e94786ab9be8e65848009078033567104d426b6b34869435864"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/store/postgres/channel_helpers.go:356-366 | internal/store/postgres/channel_invite_requests.go:201-211 | internal/store/postgres/channel_member_join.go:308-318 | internal/store/postgres/channel_member_list.go:204-214 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_helpers.go:356\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060afterChannelID\u0060 in one and \u0060channelID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"ade7b150e28ca73d3609a3fe0c114f3f3c52564b0a3cf13feae98175485aa98b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/admin/service.go:3396-3406 | internal/web/server.go:1015-1025 | internal/web/server.go:1061-1071 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3396}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6dc09667ca313d438e52d670b8a842b47957ebc1460cfb6f35d98d4f249f53c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/rpc/communities.go:296-306 | internal/rpc/communities.go:323-333 | internal/rpc/communities.go:460-470 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdb3351b5aaacebfca474eed89afc97022342d8955c6ea3c3f933332d353e1ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/rpc/communities.go:350-360 | internal/rpc/communities.go:380-390 | internal/rpc/communities.go:414-424 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1dc3748eaca0f4170bc47dabb8688b999eb6a1ed88d4a7078e4c90b1114424e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201311 lines \u00D7 3): internal/rpc/messages_forward.go:73-81 | internal/rpc/messages_send.go:431-441 | internal/rpc/send_media.go:298-306 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_forward.go:73\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"32c80debe050f4692b1b8686ebd6b35fea4ef185320d10e239fb5d29d1132cd1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/store/contact_reverse_batch.go:305-315 | internal/store/postgres/community.go:1390-1400 | internal/store/postgres/user_lane_actor.go:77-87 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/contact_reverse_batch.go:305\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"5342cc4a19e781045b3c1405e5198f80b598f8833f25425edd9adb8a6625cad7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/store/postgres/channel_boosts.go:354-364 | internal/store/postgres/channel_updates.go:502-512 | internal/store/postgres/message_helpers.go:242-252 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/message_helpers.go:254\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/postgres/channel_boosts.go:365\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac347cbb6848d0ad01fe6ef46232035bcea4c5fb1f03ee0a2d86e5b3725f822a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/store/postgres/channel_reaction_unread.go:135-145 | internal/store/postgres/channel_read.go:612-622 | internal/store/postgres/channel_topics.go:889-899 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"235323a306e7f4d3d84ad6e498cd55609c997885f9f42aa0c1098dea9b39d9d8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/store/postgres/star_gift_craft_auction.go:149-159 | internal/store/postgres/star_gift_craft_auction.go:185-195 | internal/store/postgres/star_gift_craft_auction.go:772-782 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_craft_auction.go:149\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"50a75d63f057f7c4b273e03239e745f22314317faeac79cf17f5402ac44cf1ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): cmd/telesrv-admin/readstore.go:2226-2236 | cmd/telesrv-admin/readstore.go:2751-2761 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:2226\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":2226}}}],"partialFingerprints":{"codehealthFindingId/v1":"90935233d827001172465ac743ff920ab32c10d7529d9e82e699cd6ced3db98c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): cmd/telesrv-admin/server.go:593-603 | cmd/telesrv-admin/server.go:701-711 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060cmd/telesrv-admin/server.go:700\u0060 calls \u0060Set\u0060 and \u0060cmd/telesrv-admin/server.go:592\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":593}}}],"partialFingerprints":{"codehealthFindingId/v1":"681eb43316b7840586164318d6524700f6ed641558658ba0bce0439b797f0f6f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): cmd/telesrv-admin/server.go:809-819 | cmd/telesrv-admin/server.go:1050-1060 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:809\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":809}}}],"partialFingerprints":{"codehealthFindingId/v1":"d06c0139917a75d664a7d1455da7be6d05ca9cc269d561be771f31aeb9df05a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): cmd/telesrv-admin/serverstorage.go:271-281 | internal/app/files/blobs3.go:40-50 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/serverstorage.go:271\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Check import visibility before settling on that home: \u0060internal/app/files/blobs3.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/serverstorage.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8a20f9e1cd7f40103b0dfa7a3f15949897e0a5efb5d632620730152be18dfec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201311 lines \u00D7 2): internal/admin/botverification.go:643-653 | internal/admin/botverification.go:682-690 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":643}}}],"partialFingerprints":{"codehealthFindingId/v1":"d15dc0a9eb8ba92a5577ae2001f879107db2954e874bfc302c2d82c66af01bac"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/adminapi/botverification.go:546-556 | internal/adminapi/verification.go:346-356 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"eaecb2fb899510e6fa2002d2fdfb00d267892a183a1fab44d5182f87218fc880"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/bots/verifierbot.go:588-598 | internal/app/bots/verifierbot.go:900-910 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/verifierbot.go:588\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":588}}}],"partialFingerprints":{"codehealthFindingId/v1":"516198644b018c0ae73418b35811fded4bc81cf430fd8d57b11212e311e1f32e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/bots/verifierbot.go:1400-1410 | internal/app/bots/verifybot.go:1131-1141 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/verifierbot.go:1400\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1400}}}],"partialFingerprints":{"codehealthFindingId/v1":"87f324f778ecbfbdbbed2bffe865be79f3ce033a923a482d8a4749b6495b1251"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/contacts/service.go:254-264 | internal/app/contacts/service.go:382-392 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/contacts/service.go:254\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dd7bea2d1da1305fb2018a6821ae5641b12dd5ec7efeab6f49faafeaf937039"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/dialogs/draft_read_model_cache.go:106-116 | internal/rpc/story_sparse_projection_cache.go:206-216 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/draft_read_model_cache.go:106\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/draft_read_model_cache.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"57e5a1bd0cef0708fa3c5922647fa400fd523c71056221ba755cb27adba4cc25"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/telegramlogin/service.go:250-260 | internal/app/telegramlogin/service.go:269-279 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/telegramlogin/service.go:250\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdbed39192dcfa291cf254bcd12b5580fab0d72efdefb99dc5d77d3d27b3658f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/users/service.go:452-462 | internal/store/postgres/user.go:523-533 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":452}}}],"partialFingerprints":{"codehealthFindingId/v1":"51095aae0eca1250262ab10c38303ad27e59396b232a75c45dfd87b6def0e320"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/botapi/inline.go:563-573 | internal/botapi/inline.go:826-836 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":563}}}],"partialFingerprints":{"codehealthFindingId/v1":"bae05d70519617a487cff8b0981fc2aa02c91a91df43ccf63546c6b73dcaa9eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/botapi/server.go:354-364 | internal/botapi/server.go:1035-1045 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/botapi/server.go:354\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"de514a213f07a3a20d766faa14b183531204bf39e94c159bca9338be33543e10"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/compat/tdesktop/dialogs.go:88-98 | internal/compat/tdesktop/dialogs.go:99-109 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/dialogs.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"40313a08b0bc3aeca56214dd7ef20c852e51b6226a8085b7674b7831ff3bcee0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/compat/tdesktop/dialogs.go:121-131 | internal/compat/tdesktop/dialogs.go:132-142 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/dialogs.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca3d565a91ca24ca089089d6a1c52629f215f9f4436ae0cc0dd3ebf089955ba0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/loadharness/run.go:743-753 | internal/loadharness/seed.go:74-84 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":743}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa0df9e1f80a9ccac6de94b3e55b19f5dbee60720091e304f52b0363d646b20a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/mtprotoedge/session_manager.go:2120-2130 | internal/mtprotoedge/session_manager.go:2140-2150 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2120}}}],"partialFingerprints":{"codehealthFindingId/v1":"e623dc49a8088ac9b34edecd604947eb1b2cfd96a5527eb823e1a8d920b75ebc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/account_deletion_notifications_worker.go:82-92 | internal/rpc/account_freeze_worker.go:62-72 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion_notifications_worker.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb71fc790eb3640a4c1442e166bace7583a42afd01805bcc03ff41c3759746d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/aicompose.go:83-93 | internal/rpc/aicompose.go:180-190 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/aicompose.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"0358e2ea04dc70a63521553bc5ad543141360631c23ff4acbba353a314ed5415"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/botapi_gateway.go:253-263 | internal/rpc/botapi_gateway.go:892-902 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d8cc2018694711f1f26492eb3fa0cbc8425a41abd405b811c093e7ae779d299"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/rpc/bots_inline.go:497-507 | internal/rpc/bots_inline.go:516-526 | internal/rpc/bots_inline.go:534-545 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":497}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b8981f1895a406f121110ef5f96fa28f475bccf507f0d16287723b8ec951e13"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/channels_core.go:312-322 | internal/rpc/send_media.go:287-297 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":312}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf41530afaa8682edf413d7b42dfefac6d365e66bb4ff93195d3535c6b209e19"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/channels_members.go:396-406 | internal/rpc/channels_state_mutation.go:12-22 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"36aaac8b13d4eea0b75183d942f26a6c5e1f867ffb4946aa8beeacc0b4681fec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/channels_messages.go:260-270 | internal/rpc/channels_updates.go:17-27 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"623082d7ece3732a85f39932335d7d6f11378f3bed9c6bcb9ffd7aa21ee8f290"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/channels_read_reactions.go:14-24 | internal/rpc/channels_read_reactions.go:61-71 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_read_reactions.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb4e303193d7d86a2a525764908ae675b9066b327c3db5caffcced7e025381ba"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/channels_stubs.go:501-511 | internal/rpc/premium.go:153-163 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":501}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d2d4508a41cc879b806732b798de47e5614dcf7a40f7a8df4dea9b469bfea1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/channels_stubs.go:636-646 | internal/rpc/channels_stubs.go:658-668 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":636}}}],"partialFingerprints":{"codehealthFindingId/v1":"035bef885a9d6e27a3bc7fd2c4c5168c41652ff758d2400809d9bca611b0af11"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/chatlists.go:400-411 | internal/rpc/chatlists.go:421-432 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/chatlists.go:400\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/chatlists.go"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f68be74cc10c98fef02a79eaa6315ed881d3b97f5b602bd349453d7be3484d9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/communities.go:253-263 | internal/rpc/communities.go:354-364 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":253}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7a9ab9d91fa79038f09bbf446188a425aa2db82b5bae3692322fa5cc8503bca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/ephemeral.go:127-137 | internal/rpc/ephemeral.go:237-247 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/rpc/ephemeral.go:139\u0060 calls \u0060peerIDInvalidErr\u0060 and \u0060internal/rpc/ephemeral.go:248\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec9439ec46371688124e2261c41818e02f634fe5cc585327c76603ce693c1892"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/messages_dialogs.go:286-296 | internal/rpc/payments.go:426-436 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/rpc/messages_dialogs.go:297\u0060 calls \u0060tgUsersForIDs\u0060 and \u0060internal/rpc/payments.go:437\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":286}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc0a0b63519487d1ccf91c6997af484bea7f10d35264da4133f896b20d5bc3cd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/messages_helpers.go:354-364 | internal/rpc/messages_history.go:353-363 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_helpers.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"24e254ee407f66943b3e998f5dae642b014711e8824f7f29c7c27b0089e759a8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/messages_reactions_helpers.go:119-129 | internal/rpc/messages_reactions_helpers.go:155-165 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_reactions_helpers.go:119\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_helpers.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cebac20099ce69ea88e6714e4669d62b5f2618c94e786f7739aa3cfc8260e92"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/messages_send.go:1114-1124 | internal/rpc/messages_send.go:1154-1164 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_send.go:1114\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1114}}}],"partialFingerprints":{"codehealthFindingId/v1":"540c030adf05930468396e7db581edbe29e61840d8987fb6b37c27e740681fa8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/messages_stickers_personal.go:63-73 | internal/rpc/messages_stickers_personal.go:84-94 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_stickers_personal.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e9de54f39f9218e8602ab4cafa88ce3ad9be789d05fee36bc3cb4ef07e82b25"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/messages_webview.go:154-164 | internal/rpc/messages_webview.go:243-253 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd0328900fcfdbae583b491ffb5a620176bf379eeb5e341f1f4f6f5860596487"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/payments_premium.go:82-92 | internal/rpc/payments_premium.go:143-153 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_premium.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"901c38218210a7d9dcfb8001632411e53aabed55c4e0a0069b56fb5aa30ee98c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/payments_star_gifts.go:537-547 | internal/rpc/payments_star_gifts.go:743-753 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d5d0bb9c051d245906a67e577472d52f0384d6832848e94ff115e92b67bb1a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/phone_group_call.go:480-490 | internal/rpc/phone_group_call.go:515-525 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":480}}}],"partialFingerprints":{"codehealthFindingId/v1":"afcafb6e9bd3e264d17d64a744a37f8f366f2043987647ef588a794ac5d3d6a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/photos.go:72-82 | internal/rpc/photos.go:111-121 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b0194605c7f21372baed40fa655a8cabf730a3f2bdea68a6d62db3f0a379d8f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/stickers_creator.go:139-149 | internal/rpc/stickers_creator.go:205-215 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers_creator.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf95e487d9ea5ed87f749d7caa753c7691d32d369b38c5c50571e99bb6aa21c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/stories.go:388-398 | internal/rpc/stories.go:1148-1158 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"94b94ed6d1aa4f10ebab42030cca4ad1b27b3ddb0cf7b4116d5190f5ad9dce28"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/rpc/stories.go:2419-2429 | internal/rpc/stories.go:2503-2513 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2419}}}],"partialFingerprints":{"codehealthFindingId/v1":"4efbd9f85a4d4281938ef0b56d4c02ac227f128c14f56918c74cf7896582d0be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_boosts.go:44-54 | internal/store/memory/channel_boosts.go:110-120 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_boosts.go:44\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"f87160c4b76a5558f3e2750bbab52e54aba771fc1d1a5f9485b3f5edc9e8e4c5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_helpers.go:695-705 | internal/store/postgres/channel_helpers.go:1013-1023 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":695}}}],"partialFingerprints":{"codehealthFindingId/v1":"470c94dbf718bb53c9eccdd043b4c7368627861814551e3e5661f87c3fb58ffb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_members.go:316-326 | internal/store/postgres/channel_member_admin.go:59-69 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:316\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"d810f9fb0311fa81efcfeb3aaa0545a1ae49deda347a0095ff3a668c53ac9b7f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_members.go:650-660 | internal/store/memory/channel_members.go:675-685 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:650\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":650}}}],"partialFingerprints":{"codehealthFindingId/v1":"c76e69a5a6494026c5f918729afd458b536704961f046951e753664d63fda77c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_message_send.go:99-109 | internal/store/postgres/channel_message_send.go:166-176 \u2014 \u0060internal/store/memory/channel_message_send.go\u0060 and \u0060internal/store/postgres/channel_message_send.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 4 separate duplicated blocks between them, totalling at least 43 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_send.go:99\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/memory/channel_message_send.go:110\u0060 calls \u0060cloneRichMessage\u0060 and \u0060internal/store/postgres/channel_message_send.go:177\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c9759d9d936eb751304bc7f02986f1c738333716b6ab7f5a61ae776dbd337c5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_reactions.go:801-811 | internal/store/postgres/message_reactions.go:391-401 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_reactions.go:801\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":801}}}],"partialFingerprints":{"codehealthFindingId/v1":"953178df4990feb28f17e83275851d36da552dd93d6b1f39119eee4094e60686"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_settings.go:767-777 | internal/store/postgres/channel_settings.go:1209-1219 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_settings.go:767\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":767}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bf3dac1a298d4f81e2fd161056744cde1c5565849abb743f700fbf04a39805e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_topics.go:22-32 | internal/store/postgres/channel_topics.go:36-46 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"31bd8b1cfa715c8e9fbdc627760e3975d73a117112782896046ba7c17758774b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_topics.go:424-434 | internal/store/postgres/channel_topics.go:474-484 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"8550489a363537ddc9ddf4e75fe248db7b9428981622807e72db13c821e04c08"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/telegram_login.go:413-423 | internal/store/postgres/telegram_login.go:651-661 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Note what the matched lines are: every one of them assigns one field to another, so the block is a hand-written mapper between two data shapes rather than behaviour with a helper inside it. Extracting one shared function only works if both sites map the SAME pair of types in the same direction \u2014 check that first, because inverse or differently-typed mappers have no single function they can both call. Where they do not, the moves that exist are a generated or reflective mapper, a common embedded/base type the fields live on once, or accepting the run and covering it with a test that fails when a field is added to one side only."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":413}}}],"partialFingerprints":{"codehealthFindingId/v1":"d91b2c0fa131326d73d268dfee8d64811ad7ea63cfdea88fe2b2806573250094"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/channel_dialogs.go:761-771 | internal/store/postgres/media.go:657-667 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_dialogs.go:761\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":761}}}],"partialFingerprints":{"codehealthFindingId/v1":"729da9ce335cac07ca10f275dc4c0c4e622ee82e479ab0a7aa6d5e3bfd6dabad"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/channel_reaction_unread.go:26-36 | internal/store/postgres/channel_read.go:290-300 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_reaction_unread.go:26\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"421a7ab95348f7951ce7d209ff55a656aa4eda112ca2f53a3c1eb09d5f2dd3b9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (17 lines \u00D7 2): internal/store/postgres/moderation_cases.go:151-167 | internal/store/postgres/moderation_cases.go:241-257 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"27d27240436155c3268a266f32e62d641a87c76e489495a0b9ef996664fbff06"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/moderation_registries.go:82-92 | internal/store/postgres/moderation_registries.go:207-217 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0576018b57d580276dc41b5e705a55a665d49e74fccef35c2a617ac241a616a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/star_gift_craft_auction.go:772-782 | internal/store/postgres/star_gift_lifecycle.go:1094-1104 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_craft_auction.go:772\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":772}}}],"partialFingerprints":{"codehealthFindingId/v1":"c943882188dbc4be7be7fc6693f33897a6e71a4cf4380cd4c9188d5bb795d958"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/telegram_login.go:43-53 | internal/store/postgres/telegram_login.go:69-79 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ecb46d43ef0b2a0cd6cc07c0f4f7f728900358fb6b1037a7a18ce72d5a538bf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/verification.go:544-554 | internal/store/postgres/verification.go:634-644 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/verification.go:544\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":544}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee27ea475aa855794114a085afaa3964dd4c2eb62140612c9f9dd6d68cf044fc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201311 lines \u00D7 2): internal/store/storetest/groupcall.go:438-446 | internal/store/storetest/groupcall.go:487-497 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/storetest/groupcall.go:438\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/storetest/groupcall.go"},"region":{"startLine":438}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b93956a91b66965b8488cd387b47ad58c56481840acc381c1b9cc60c3cb2043"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 11): internal/admin/service.go:1412-1421 | internal/app/channels/service.go:2452-2461 | internal/app/peerview/cache.go:153-162 | internal/app/userprojection/durable_user_facts.go:131-140 | internal/domain/media.go:1038-1047 | internal/domain/media.go:1055-1064 | internal/rpc/channels_stubs.go:413-422 | internal/rpc/channels_stubs.go:457-466 | internal/rpc/peer_projection_cache.go:267-276 | internal/store/postgres/channel_dialogs.go:761-770 | internal/store/postgres/media.go:657-666 \u2014 there are 11 copies across 9 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 11 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1412}}}],"partialFingerprints":{"codehealthFindingId/v1":"b944303c30b26091e66bc23fac530b424e206481c4c5c2f776ae2dc0e791f277"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 10): internal/app/bots/service.go:587-596 | internal/app/dialogs/service.go:737-746 | internal/app/files/seed.go:1097-1106 | internal/app/privacy/cache.go:255-264 | internal/app/privacy/service.go:474-483 | internal/app/userprojection/contact_cache.go:1139-1148 | internal/app/userprojection/projection.go:277-286 | internal/store/contact_reverse_batch.go:301-310 | internal/store/memory/channel_core.go:298-307 | internal/store/postgres/channel_core.go:645-654 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 10 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 10 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/service.go:587\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060userID\u0060 in one and \u0060targetID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/contact_reverse_batch.go:313\u0060 calls \u0060Slice\u0060 and \u0060internal/app/bots/service.go:599\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":587}}}],"partialFingerprints":{"codehealthFindingId/v1":"218933139a38ed524175eeef6a4189a4e3350fcf066cdac4ada8682d5ad92233"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 9): internal/store/memory/channel_reactions.go:16-25 | internal/store/memory/channel_settings.go:423-432 | internal/store/memory/channel_settings.go:453-462 | internal/store/memory/channel_settings.go:483-492 | internal/store/memory/channel_settings.go:532-541 | internal/store/memory/channel_settings.go:562-571 | internal/store/memory/channel_settings.go:581-590 | internal/store/memory/channel_settings.go:600-609 | internal/store/memory/channel_settings.go:623-632 \u2014 there are 9 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 9 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c7196c03e70b1d1818477debf694f36f8236b48dcdce91f3b116a6b741c8faf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 9): internal/store/postgres/channel_settings.go:585-594 | internal/store/postgres/channel_settings.go:722-731 | internal/store/postgres/channel_settings.go:771-780 | internal/store/postgres/channel_settings.go:807-816 | internal/store/postgres/channel_settings.go:856-865 | internal/store/postgres/channel_settings.go:905-914 | internal/store/postgres/channel_settings.go:941-950 | internal/store/postgres/channel_settings.go:989-998 | internal/store/postgres/channel_topics.go:26-35 \u2014 there are 9 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 9 sites; resolving a subset leaves the remainder to drift apart. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":585}}}],"partialFingerprints":{"codehealthFindingId/v1":"45ae77b62427fc30770f1608bfe39cef56fd17f70c43a2021bd8806a06c014e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 7): internal/rpc/stories.go:411-420 | internal/rpc/stories.go:552-561 | internal/rpc/stories.go:1210-1219 | internal/rpc/stories.go:2458-2467 | internal/rpc/stories.go:2540-2549 | internal/rpc/stories.go:2576-2585 | internal/rpc/stories.go:2649-2658 \u2014 all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:411\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e308172ba4a1f43eb205839e7737067e1464df0e1e8b57476cc4e197ed2dbd9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 7): internal/rpc/stories.go:411-420 | internal/rpc/stories.go:552-561 | internal/rpc/stories.go:586-595 | internal/rpc/stories.go:1368-1377 | internal/rpc/stories.go:2458-2467 | internal/rpc/stories.go:2540-2549 | internal/rpc/stories.go:2576-2585 \u2014 all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:411\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"316cca8b0fe076f11067af58dae192dd96729d37757436c0116d09a827bb183f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 6): cmd/telesrv-admin/account_rating.go:72-81 | cmd/telesrv-admin/botverification.go:116-125 | cmd/telesrv-admin/botverification.go:163-172 | cmd/telesrv-admin/donations.go:75-84 | cmd/telesrv-admin/server.go:2691-2700 | cmd/telesrv-admin/verification.go:43-52 \u2014 there are 6 copies across 5 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060cmd/telesrv-admin/donations.go:74\u0060 calls \u0060Query\u0060 and \u0060cmd/telesrv-admin/account_rating.go:71\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/account_rating.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"65161a1998ad9f0e8ac3b3eb6a4ee7c858dfc4de08f05322875ad0271f5d144f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 6): cmd/telesrv-admin/botverification.go:135-144 | cmd/telesrv-admin/botverification.go:184-193 | cmd/telesrv-admin/server.go:2706-2715 | cmd/telesrv-admin/verification.go:64-73 | internal/adminapi/botverification.go:108-117 | internal/adminapi/botverification.go:169-178 \u2014 there are 6 copies across 4 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/botverification.go:135\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Check import visibility before settling on that home: \u0060internal/adminapi/botverification.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ba6c696084fb92588c5f290f8f7b1256627018dda66d075b92965ac20540040"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 5): internal/store/postgres/message_delete.go:565-574 | internal/store/postgres/message_delete.go:579-588 | internal/store/postgres/message_delete.go:593-602 | internal/store/postgres/message_delete.go:607-616 | internal/store/postgres/saved_dialog.go:292-301 \u2014 there are 5 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":565}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e8ec309eb59e6cbc3c6989e24039747c6b3a78b2cd63beaad079bd07bfa4a23"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 5): internal/store/postgres/message_edit.go:37-47 | internal/store/postgres/message_history.go:321-331 | internal/store/postgres/message_history.go:516-526 | internal/store/postgres/message_pin.go:44-53 | internal/store/postgres/message_pin.go:190-199 \u2014 there are 5 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_edit.go:37\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"56c28b202a61b15669c5a0ee672bb33bc8c6bc183402dc87d3ef18a275baec7f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): internal/botapi/server.go:574-583 | internal/botapi/server.go:639-648 | internal/botapi/server.go:729-738 | internal/botapi/server.go:826-835 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/botapi/server.go:574\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":574}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd292bed37fa042c6701e299b171f529ad85ade2dfa87d0fba7d9a2d95866471"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): internal/rpc/communities.go:250-259 | internal/rpc/communities.go:351-360 | internal/rpc/communities.go:381-390 | internal/rpc/communities.go:415-424 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/communities.go:250\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities.go"},"region":{"startLine":250}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a55bd8d352c74e453bd8f8bebb7543a73e7b56e508d7f7b05cff1b79635a677"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): internal/rpc/payments_star_gift_collections.go:15-24 | internal/rpc/payments_star_gift_collections.go:45-54 | internal/rpc/payments_star_gift_collections.go:73-82 | internal/rpc/payments_star_gifts.go:1093-1102 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gift_collections.go:15\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_collections.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe83f14d20bfefd3518b36965ae1ed57cf5bda626778105513662811f0ef86e6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): internal/rpc/stories.go:586-595 | internal/rpc/stories.go:2303-2312 | internal/rpc/stories.go:2359-2368 | internal/rpc/stories.go:2765-2774 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:586\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":586}}}],"partialFingerprints":{"codehealthFindingId/v1":"72679482de5113dae5604fcf37df0f4473110a449159ba0e0cae5c4ddd3122c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u201310 lines \u00D7 4): internal/store/storetest/groupcall.go:65-72 | internal/store/storetest/groupcall.go:389-396 | internal/store/storetest/groupcall.go:437-444 | internal/store/storetest/groupcall.go:486-495 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/storetest/groupcall.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"faa1a9137bb330bf19ecbdc9535f8600e1a1d0247f344bf720e38b7342572f49"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12\u201314 lines \u00D7 3): internal/rpc/botapi_gateway.go:205-218 | internal/rpc/botapi_gateway.go:271-282 | internal/rpc/botapi_gateway.go:322-335 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/botapi_gateway.go:205\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6b425df3114252e8b4ec288075f3b59706deaa7ff2a5f0b33ae50ffff81b5fe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/rpc/messages_pin.go:29-38 | internal/rpc/messages_pin.go:121-130 | internal/rpc/messages_read.go:30-39 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_pin.go:29\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_pin.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9711cdcae9324e8f867d8db67b7c50fa673d249c594851e4cfff8853e6b44e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/rpc/stories.go:2417-2426 | internal/rpc/stories.go:2501-2510 | internal/rpc/stories.go:2736-2745 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:2417\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2417}}}],"partialFingerprints":{"codehealthFindingId/v1":"b00f0919c5e6408de07814f4b0c05301a18830dc03a82a250ad347a206c2759a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/store/memory/channel_members.go:627-636 | internal/store/memory/channel_settings.go:103-112 | internal/store/memory/channel_settings.go:146-155 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":627}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba980b2c94ab8e0756befcf6492b501e1cea7ca5b072e7e781b82dab050d949e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/store/memory/contacts.go:50-59 | internal/store/memory/contacts.go:72-81 | internal/store/memory/contacts.go:363-372 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"332189d8779a7fffbb53f6d1bcaf50d61f681d2288100498445e036494450337"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/store/postgres/channel_message_delete.go:211-220 | internal/store/postgres/channel_message_delete.go:384-393 | internal/store/postgres/channel_topics.go:401-410 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"b17c2a850bd25b396a67f20cc3e857dbedfbcf5405d346758c9d35762b60de01"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/store/postgres/story.go:619-628 | internal/store/postgres/story.go:679-688 | internal/store/postgres/story.go:747-756 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":619}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a35e75070ba4d5696ce6fc96a512366ccdcd15701f4d0360e3e1e9182b1d008"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): cmd/bots/botcheck/main.go:298-307 | cmd/bots/botdemo/main.go:470-479 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":298}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4e715eff3d9cd69adfb580da7081694030ec97b49bfd203c1588761264ec574"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): cmd/telesrv-admin/botverification.go:64-73 | cmd/telesrv-admin/botverification.go:83-92 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"40819554e0171cc315f21eecab0858032947962547b5bd0bc61f8ed3faa4a89d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): cmd/telesrv-admin/star_gift_catalog.go:212-230 | internal/adminapi/server.go:1267-1285 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/star_gift_catalog.go:212\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Check import visibility before settling on that home: \u0060internal/adminapi/server.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/star_gift_catalog.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6f7f61de95ec4f49358377b088147a112f0a9891b4f243766c2c6b2e8ab9f46"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 2): internal/admin/service.go:2904-2913 | internal/admin/service.go:2949-2957 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:2904\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2904}}}],"partialFingerprints":{"codehealthFindingId/v1":"118f55c9007adbb6df9b5567c4e5de85cbc2ef05d0b8f57bcbdbeacba2bc836b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/account/service.go:264-273 | internal/app/account/service.go:334-343 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"08d6c2b52ae1aa1c90d3a6e66a24a8364f752e1e0d5f4d1b29166430b6e52f5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/dialogs/read_model_cache.go:451-461 | internal/app/dialogs/read_model_cache.go:474-484 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"1563953a554dcfde3883b22b860b3243c5acbf182b91d41b3790d99d5d6648e6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/files/diskspace_windows.go:10-19 | internal/hoststats/disk_windows.go:11-20 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/diskspace_windows.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"22c02952ad5a14c22ca5affaf07ae5f6bf3bc9d4db6d9adc076165e255ccbe68"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/files/photos.go:356-365 | internal/app/files/photos.go:682-691 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/photos.go:356\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"77a13aa52f2d7f2eff19bf8542d57c0e98817852e9cee14b89e49995c31e0ff8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/files/seed.go:1099-1108 | internal/rpc/channels_stubs.go:457-466 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":1099}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f561f6e2dcec2d614cf4f98d0754a65e3399c6d11bdfba915bede2ff5d699b5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/app/files/sticker_management.go:50-61 | internal/app/files/sticker_management.go:86-97 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_management.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"468fedfb2d7abdbd4341c6b334865709f6858dedf54be04057e39f960d91b5d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/messages/service.go:672-681 | internal/app/messages/service.go:700-709 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":672}}}],"partialFingerprints":{"codehealthFindingId/v1":"d39c1b7dc3cf6bf1eb7f47093163908ca9bd0de3f9cda4f03326bd2a8a076653"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/messages/service.go:686-695 | internal/app/messages/service.go:714-723 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":686}}}],"partialFingerprints":{"codehealthFindingId/v1":"c91ba0019e2c4bebf53bafb5c4a9c5bc6c0c8766816df62f7a58ce59bfcc3e09"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/moderation/registry_reports.go:32-41 | internal/app/moderation/registry_reports.go:72-81 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/registry_reports.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e59a9a5eb5831648a2aac7b80e96dabee7a0750560ce2cd607872e967372c5b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/readmodel/hash.go:27-36 | internal/store/postgres/dialog.go:1295-1304 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/readmodel/hash.go:27\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/dialog.go:1293\u0060 calls \u0060PutUint64\u0060, \u0060Write\u0060 and \u0060internal/app/readmodel/hash.go:26\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/readmodel/hash.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"20ac327ce2c27bcc6a517eb3e6b0acc35f5f9fd133d686c9933444ae01c1ba0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/stargifts/service.go:211-220 | internal/app/stargifts/service.go:392-401 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/stargifts/service.go:211\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"61c01d3a52ba82786b601bb844cd960b11cc62815298180e35d4439017dca781"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 2): internal/app/userprojection/projection.go:150-159 | internal/app/userprojection/projection_sparse.go:87-95 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/userprojection/projection.go:150\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a39271db11440651f89b3ada20eee64c365289353c695e0f4c75e43535f94e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/userprojection/projection.go:301-310 | internal/app/userprojection/projection.go:553-562 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"02b8ba69fe0294e82b241d3461609526856311f8a4b6ac6b8e1cd7aa4edf798b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/users/service.go:497-506 | internal/app/users/service.go:599-608 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":497}}}],"partialFingerprints":{"codehealthFindingId/v1":"91478e2c2e903d7e32b37cbcee338db902b1387659d3903dfb7c566296ddbedd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/verification/service.go:714-723 | internal/app/verification/service.go:787-796 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":714}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ebbaf4edab566c65c4d8c02219ced38593dc0ca6701eac34ba86e094313e0d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 2): internal/compat/tdesktop/defaults.go:188-196 | internal/rpc/convert_misc.go:155-164 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/compat/tdesktop/defaults.go:188\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/compat/tdesktop/defaults.go:188\u0060 is reached only past a guard at line 184 that tests \u0060list.Hash\u0060 and leaves the function early, and \u0060internal/rpc/convert_misc.go:155\u0060 reads \u0060list.Hash\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/defaults.go"},"region":{"startLine":188}}}],"partialFingerprints":{"codehealthFindingId/v1":"950a870ea46e864d57697e928d12ff7545d64c847010a1b733774f39f7f8b934"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/loadharness/run.go:1280-1289 | internal/loadharness/startup.go:344-353 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/loadharness/run.go:1280\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1280}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d787cc526098b7581e65f2308d0721ade1d3283055ca1202819ae769108842c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/mtprotoedge/session_manager.go:520-532 | internal/mtprotoedge/session_manager.go:566-578 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:520\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"edb5972c3a401722401fd5ae203865564fcb11a6bb88eb568219f9a82526f341"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/account_business.go:334-343 | internal/rpc/account_business.go:364-373 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b8dcc33777716b90c9c8cd211a9402f4329b581ba6c38eb67e644ffc4d3ac2c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/bots_inline.go:560-569 | internal/rpc/bots_inline.go:586-595 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bots_inline.go:560\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":560}}}],"partialFingerprints":{"codehealthFindingId/v1":"68a3ccaaa0f400dd70fb23ccaf83aa279f126d76414e9972a26ad0d28d049328"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/bots_inline.go:825-834 | internal/rpc/send_media.go:719-728 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":825}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bf1bb6205a44c8c00dcff2481eb09f8d9220b3c372e4ed31f06797ef5149dc3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/channel_fanout_dispatcher.go:902-911 | internal/rpc/channels_updates.go:453-462 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channel_fanout_dispatcher.go:902\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":902}}}],"partialFingerprints":{"codehealthFindingId/v1":"f56e9b789d9ebc55886d182555de34da26f7f336757d1ce0c348fe51ce72d266"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/messages_delete.go:28-37 | internal/rpc/messages_delete.go:101-110 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_delete.go:28\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/messages_delete.go:100\u0060 calls \u0060GetJustClear\u0060 and \u0060internal/rpc/messages_delete.go:27\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_delete.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"55e25d12f6cb95ea945a5f554dab3b241902ffe71aedcddcb88fa35b48ec32c2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/messages_delete.go:46-55 | internal/rpc/messages_no_forwards.go:21-30 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_delete.go:46\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_delete.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"76c5e2b89e00b93dfcb097912fabdcd972f7d6e27721f59d5bdebe7b3e5413b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/messages_edit.go:261-270 | internal/rpc/messages_edit.go:276-285 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_edit.go:261\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4c8ca2143da17ea7b908b5fa5000caf04290a5e9eec81eb72c8ee9aecb4aceb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/messages_forum.go:77-86 | internal/rpc/messages_forum.go:126-135 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd52929ed498bd9be71bfffd5d704f2bb0dbb3bddeab54704fdc8da700be261c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/messages_forward.go:160-169 | internal/rpc/messages_forward.go:420-429 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/messages_forward.go:417\u0060 calls \u0060peerIDInvalidErr\u0060 and \u0060internal/rpc/messages_forward.go:158\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":160}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a7db400a56aef14776badd578e3334370673177759f4555999432a5bac0d372"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/messages_history.go:341-350 | internal/rpc/messages_read.go:126-135 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_history.go:341\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/rpc/messages_history.go:341\u0060 is reached only past a guard at line 316 that tests \u0060req.AddOffset\u0060 and leaves the function early, and \u0060internal/rpc/messages_read.go:126\u0060 reads \u0060req.AddOffset\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":341}}}],"partialFingerprints":{"codehealthFindingId/v1":"c411d59510d50b15ea85b53df463ff274b62db76ce9f08a8db5c9727d8947ca9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/messages_sticker_sets.go:235-244 | internal/rpc/messages_sticker_sets.go:251-260 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_sticker_sets.go:235\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_sticker_sets.go"},"region":{"startLine":235}}}],"partialFingerprints":{"codehealthFindingId/v1":"936e3296a98e83fa3a43722b169c5d453918f18e9f8eb5c13f776e6a8e1f7195"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 2): internal/rpc/outbox_dispatcher.go:251-259 | internal/rpc/outbox_dispatcher.go:308-317 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/outbox_dispatcher.go"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"c761caa8303062bfae31396575467a356932e8cc6795e69d5294a8f1e7ac5191"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/payments.go:207-216 | internal/rpc/payments.go:263-272 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"034900f5674403637966d3584697f043969d2cea3a0c527d9ad14c4c9ece77cd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/phone_group_call_edit.go:228-237 | internal/rpc/phone_group_call_edit.go:256-265 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/phone_group_call_edit.go:228\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_edit.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"97a4e851f6e8a9ae1093fbeb7a4f90803521b17989559c5e5b63869e39304a23"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/stickers_creator.go:315-324 | internal/rpc/stickers_creator.go:356-365 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stickers_creator.go:315\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers_creator.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd12d38023a46267b872a48519292f8c3855b9bf8e63ad6f7942038a7cd00d57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/telegram_login.go:394-403 | internal/rpc/telegram_login.go:417-426 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"a93d4383d7560f7d016d6356ea5439e1c69faa01bba3b54a94bb5ad2201173d2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/temp_key_cache.go:45-54 | internal/rpc/temp_key_cache.go:69-78 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/temp_key_cache.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad06ee07f3fd82f63afe18d583d6bc6479b0f6cb263bb4aabda6b7182b64ba9b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9\u201310 lines \u00D7 2): internal/rpc/welcome_messages.go:22-31 | internal/rpc/welcome_messages.go:46-54 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/welcome_messages.go:46\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/welcome_messages.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a5b2206fd955705be72c32720b71cdf5eaae50ef5c97e09e92d4e1d2c9243c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/bot_verification.go:399-408 | internal/store/postgres/bot_verification.go:541-550 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/bot_verification.go:539\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/memory/bot_verification.go:398\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":399}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c49ce26f6e3ed4a688eb2cb773867c6811b55fa11652654305592eff8fd7b5f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/bot_verification.go:984-993 | internal/store/postgres/bot_verification.go:1316-1325 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":984}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e2bca51e13bdff4f13811c486ed5f387e46ed1313a297cc81dedf2d44ab8966"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_members.go:289-298 | internal/store/memory/channel_members.go:492-501 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"a90adbb188af9426332c6d4ce9bc65deab57037d60e63dd65eacc8a6b05c653d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_members.go:328-337 | internal/store/memory/channel_members.go:459-468 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"18c35197f60b3ae4e311676802e352e6386109564147157a93f5cefb7beefe5d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_members.go:700-709 | internal/store/memory/channel_members.go:728-737 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:700\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":700}}}],"partialFingerprints":{"codehealthFindingId/v1":"08239a8365fff2aa6806462577b8684c5ce16569c756b26d29c1502ebeed3536"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_members.go:777-786 | internal/store/memory/channel_members.go:796-805 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/memory/channel_members.go:806\u0060 calls \u0060TrimSpace\u0060 and \u0060internal/store/memory/channel_members.go:787\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":777}}}],"partialFingerprints":{"codehealthFindingId/v1":"28cbb1d12c3b11f25f1124260d54491e61f2be1cdce8210f67ad18afcc0460ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_members.go:891-900 | internal/store/memory/channel_members.go:962-971 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:891\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/memory/channel_members.go:959\u0060 calls \u0060publicPreviewableChannelLocked\u0060 and \u0060internal/store/memory/channel_members.go:889\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":891}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3d4244a8eb2730677ba7f04d9a24c029e0eb7ce030defaaf4568a826db5e432"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_message_edit.go:252-261 | internal/store/postgres/channel_message_edit.go:406-415 \u2014 \u0060internal/store/memory/channel_message_edit.go\u0060 and \u0060internal/store/postgres/channel_message_edit.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 4 separate duplicated blocks between them, totalling at least 56 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"45699cd5e05f0cd0311b0262b61b1152dac61c8412e77cca6ce402ce1952f474"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/memory/channel_message_helpers.go:56-71 | internal/store/postgres/message_helpers.go:19-34 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_helpers.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"aea18aec903cf515f5664f725f7203bc5df115733b8b04203ac3bdb981adde0a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_read.go:10-19 | internal/store/memory/channel_topics.go:50-59 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"308d8c807ad265e6e4e71f45cc38498134b0b775866177189212bbc065259877"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_settings.go:740-749 | internal/store/postgres/channel_settings.go:1176-1185 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"221f85f16f31e5c133441f28ba720cc77bb98128f647407a0269eb794c816513"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/community.go:140-149 | internal/store/memory/community.go:526-535 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/community.go:140\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b693a1a5ff87b7925954b6349a03b3dc8602606c33f3df432be2510453c550e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/message_reactions.go:92-101 | internal/store/memory/message_reactions.go:110-119 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_reactions.go:92\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb9503a24d7ad5910efb305f9978ed9d2a08bef0912f275106e9eef606876fcb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/moderation.go:725-734 | internal/store/postgres/moderation_cases.go:607-616 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":725}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e183a0d86d33195e2683bcf05aec1201ae93cbd622d97febb65f1adc84f83ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/authkey_session_layer.go:38-47 | internal/store/postgres/authkey_session_layer.go:166-175 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/authkey_session_layer.go:38\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_session_layer.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"158d7f5ed3571493bc1458fb311faa90034d200c2cfd93e62b0a9ea7d48c68c1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/botapi_update.go:412-421 | internal/store/postgres/botapi_update.go:450-459 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/botapi_update.go:412\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"f303fe34534f852536afabbd5bc37a044bea2c535a4fd16be58f7f152bd6c73b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_invite_members.go:22-31 | internal/store/postgres/channel_member_join.go:171-180 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_members.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"56a35ff2e2cd1f88a5c0e7fe120f9d8eac57dd2a6947211545ea77423a0c8136"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_member_admin.go:25-34 | internal/store/postgres/channel_member_admin.go:320-329 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":25}}}],"partialFingerprints":{"codehealthFindingId/v1":"90956891e0798708f0ab28f5f9b5d06740ddf77b29d7375b78a650c76d08b172"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_member_admin.go:78-87 | internal/store/postgres/channel_member_admin.go:137-146 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_admin.go:78\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"58753b3b1ffba1abd5266fa248bf6d4f4a4cf3ecff207be0043196862c413a00"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_message_send.go:56-65 | internal/store/postgres/channel_monoforum.go:38-47 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_send.go:56\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"65e5817e962616d167ab58303e273969e85b7f8233a12acd8c691bac203a2a45"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_reaction_unread.go:223-232 | internal/store/postgres/channel_read.go:701-710 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_reaction_unread.go:223\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cfc487b8541991df9ce3fe7463c9ea3c223062a3323389707fc955296c5e567"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_settings.go:176-185 | internal/store/postgres/channel_settings.go:228-237 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":176}}}],"partialFingerprints":{"codehealthFindingId/v1":"cac5814dbce9e0cdbe8b7bea656d542d7c5fa44a3245bebfecfaaee032ef00bf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_settings.go:1199-1208 | internal/store/postgres/channel_settings.go:1233-1242 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_settings.go:1199\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/channel_settings.go:1198\u0060 calls \u0060setLinked\u0060 and \u0060internal/store/postgres/channel_settings.go:1232\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":1199}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9dd21da00c47f184fcdef7f4e776aee7087551a6a825cf6700fff5f37d6f23c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_topics.go:520-529 | internal/store/postgres/channel_topics.go:567-576 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":520}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e594b9bde83f7a8817235761108c110107de117a2d130e1f8d72958b99bc728"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_updates.go:62-71 | internal/store/postgres/channel_updates.go:117-126 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_updates.go:62\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"f15351e64c0942970f74f0a57be77b3482404977441944410b267cbc4180085f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/community.go:367-376 | internal/store/postgres/dialog.go:437-446 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":367}}}],"partialFingerprints":{"codehealthFindingId/v1":"f967b4f0e165178c73c2b9a8e44659f1dcaf1d868f24327805db0537ccc1d737"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (19 lines \u00D7 2): internal/store/postgres/dialog.go:79-97 | internal/store/postgres/dialog.go:295-313 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/dialog.go:79\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"e69c952c26e9ea9394ebeeb211a8e5ebf05d46a60d061b054450671fd258e0cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/dialog.go:843-852 | internal/store/postgres/peer_username.go:211-220 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/dialog.go:843\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":843}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ab998c9a571d7170dc0294d6077d0971fbed7eb34ab3e1f0ba50e90b3687222"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/encrypted_queue.go:61-70 | internal/store/postgres/groupcall.go:88-97 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/encrypted_queue.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e454121009712352aac97523daf86aa661986bf5e2052e122a8cddb44c9cf7d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/langpack.go:302-311 | internal/store/postgres/langpack.go:341-350 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/langpack.go:302\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/langpack.go"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4bed375445de1599ab731b8434b5932f5c99bf006c719f5de1b7faa0e8fe25e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u201310 lines \u00D7 2): internal/store/postgres/message_edit.go:269-278 | internal/store/postgres/star_gift_upgrade.go:846-852 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_edit.go:269\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"781e5fb819b0a28e5e1885174acf0cb646e37e2deda009a2059b89d3eb3bcfda"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/premium.go:495-504 | internal/store/postgres/premium.go:529-538 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/premium.go:495\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":495}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d1b095e87dc2afbda67a735a7e10dbe4db9a1a373d626ee9c4eeb15000e5134"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/saved_dialog.go:43-52 | internal/store/postgres/saved_dialog.go:112-121 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/saved_dialog.go:43\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e72767dee70d83b6caf449fe4d317db0077ea86b6674aef906e4bc86b9885bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/saved_dialog.go:74-83 | internal/store/postgres/saved_dialog.go:158-167 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/saved_dialog.go:74\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"795fc1be9b03c6fb39ddb4ec7b0f00a21c322b58aa8a8f071a1cad6204f7d08d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/read_model_batch.go:93-102 | internal/store/read_model_cache.go:76-85 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/read_model_batch.go:93\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/read_model_batch.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc553adb7f778feaf0ca15d0cb2a57cac413925fc4c9feb9719cc06c1d9e2f53"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 20): internal/admin/service.go:1411-1419 | internal/app/channels/service.go:2451-2459 | internal/app/dialogs/read_model_cache.go:307-315 | internal/app/peerview/cache.go:152-160 | internal/app/privacy/service.go:194-202 | internal/app/userprojection/durable_user_facts.go:130-138 | internal/app/users/service.go:947-955 | internal/domain/media.go:1037-1045 | internal/domain/media.go:1054-1062 | internal/rpc/channels_stubs.go:412-420 | internal/rpc/channels_stubs.go:456-464 | internal/rpc/messages_sticker_sets.go:216-224 | internal/rpc/peer_projection_cache.go:266-274 | internal/store/memory/channel_core.go:213-221 | internal/store/memory/channel_members.go:891-899 | internal/store/memory/channel_members.go:962-970 | internal/store/memory/users.go:57-65 | internal/store/postgres/channel_dialogs.go:760-768 | internal/store/postgres/channel_dialogs.go:1732-1740 | internal/store/postgres/media.go:656-664 \u2014 there are 20 copies across 16 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 20 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:1411\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060userID\u0060 in one and \u0060s *Service) invalidateDialogListHashes(userID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/app/userprojection/durable_user_facts.go:128\u0060 calls \u0060uniqueDurableFactUserIDs\u0060 and \u0060internal/app/privacy/service.go:192\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1411}}}],"partialFingerprints":{"codehealthFindingId/v1":"20ba2fe32d0678a516ed951768963ff4dea248cf7197952221d32cc47aceb9b6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 18): internal/admin/service.go:1410-1418 | internal/app/channels/service.go:2450-2458 | internal/app/peerview/cache.go:151-159 | internal/app/privacy/service.go:193-201 | internal/app/userprojection/durable_user_facts.go:129-137 | internal/app/users/service.go:210-218 | internal/app/users/service.go:946-954 | internal/domain/media.go:1036-1044 | internal/domain/media.go:1053-1061 | internal/rpc/channels_stubs.go:411-419 | internal/rpc/channels_stubs.go:455-463 | internal/rpc/messages_sticker_sets.go:215-223 | internal/rpc/peer_projection_cache.go:265-273 | internal/store/memory/channel_members.go:890-898 | internal/store/memory/channel_members.go:961-969 | internal/store/postgres/channel_dialogs.go:759-767 | internal/store/postgres/channel_dialogs.go:1731-1739 | internal/store/postgres/media.go:655-663 \u2014 there are 18 copies across 13 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 18 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:1410\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060userID\u0060 in one and \u0060c *BatchCache) PrimeExpected(viewerUserID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/admin/service.go:1409\u0060 calls \u0060uniqueFreezeUserIDs\u0060 and \u0060internal/app/privacy/service.go:192\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1410}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e3d464fdf0117e78e3c8b0a0e841204884b6d76e7d8870bc9d204982481a16e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 15): internal/store/memory/channel_members.go:756-764 | internal/store/memory/channel_members.go:775-783 | internal/store/memory/channel_members.go:794-802 | internal/store/memory/channel_message_settings.go:11-19 | internal/store/memory/channel_reactions.go:14-22 | internal/store/memory/channel_settings.go:421-429 | internal/store/memory/channel_settings.go:451-459 | internal/store/memory/channel_settings.go:481-489 | internal/store/memory/channel_settings.go:500-508 | internal/store/memory/channel_settings.go:530-538 | internal/store/memory/channel_settings.go:560-568 | internal/store/memory/channel_settings.go:579-587 | internal/store/memory/channel_settings.go:598-606 | internal/store/memory/channel_settings.go:621-629 | internal/store/memory/channel_topics.go:13-21 \u2014 there are 15 copies across 5 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 15 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:756\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":756}}}],"partialFingerprints":{"codehealthFindingId/v1":"51c9f12e89db0e720e0852037cc3498bdf819e0830f8581fb65c965b598845ec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 6): internal/app/files/botfather_avatar_seed.go:36-44 | internal/app/files/chatbot_avatar_seed.go:35-43 | internal/app/files/gifbot_avatar_seed.go:35-43 | internal/app/files/premiumbot_avatar_seed.go:35-43 | internal/app/files/stickers_bot_avatar_seed.go:35-43 | internal/app/files/verifybot_avatar_seed.go:35-43 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 6 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/botfather_avatar_seed.go:36\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/botfather_avatar_seed.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2743ad3f14a0d9b38f951c1dc9c9adf6b9a5c8e12ee11b3fc213ae4e0c16132"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 6): internal/rpc/stats.go:204-212 | internal/rpc/stories.go:413-421 | internal/rpc/stories.go:1212-1220 | internal/rpc/stories.go:2460-2468 | internal/rpc/stories.go:2542-2550 | internal/rpc/stories.go:2578-2586 \u2014 there are 6 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stats.go:204\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"1eb57085465179e462172b70f405aef0c62ca7dc03df003fa33d6e78f6a695bd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 5): internal/store/postgres/channel_helpers.go:356-364 | internal/store/postgres/channel_invite_requests.go:201-209 | internal/store/postgres/channel_member_join.go:308-316 | internal/store/postgres/channel_member_list.go:204-212 | internal/store/postgres/channel_settings.go:1095-1103 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 5 call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060afterChannelID\u0060 in one and \u0060channelID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"51836cfbb59e800a9b74e1d70c300bd7c4b3632d54e0301c426bfc0f882eac51"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): cmd/telesrv-admin/server.go:855-863 | cmd/telesrv-admin/server.go:1249-1257 | cmd/telesrv-admin/server.go:2349-2357 | cmd/telesrv-admin/server.go:2718-2726 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":855}}}],"partialFingerprints":{"codehealthFindingId/v1":"9be5fae2560365d0a0d82d5a3a5b379470ac91425931033f4506715124c16ef9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): internal/app/users/service.go:451-459 | internal/rpc/presence_last_seen_batch.go:196-204 | internal/store/memory/users.go:459-467 | internal/store/postgres/user.go:522-530 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d9791ddf3bb2e3e350541b922812ad0b4cf761df26476fb86263260e36eb1ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): internal/rpc/convert_channels_core.go:16-24 | internal/rpc/convert_channels_core.go:395-403 | internal/rpc/convert_dialogs.go:359-367 | internal/rpc/premium_sweeper.go:211-219 \u2014 there are 4 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/convert_channels_core.go:16\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"064ca93596702a5001af36fbc4cd51f641c83b8888a177ed304f2e2b69b90e2c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): internal/store/postgres/story.go:379-387 | internal/store/postgres/story.go:620-628 | internal/store/postgres/story.go:680-688 | internal/store/postgres/story.go:748-756 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8041d9bfc247e8af654be878200a13c1bf0061c7ffbf69e347bc19393a93a01"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): internal/store/postgres/story.go:796-804 | internal/store/postgres/story.go:851-859 | internal/store/postgres/story.go:904-912 | internal/store/postgres/story.go:965-973 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":796}}}],"partialFingerprints":{"codehealthFindingId/v1":"a74bab012fd2a9056f136f5161fc81e2d00fb37bfc05a7b819716b4a42b7b14d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): cmd/walletminiapp/main.go:184-192 | cmd/walletminiapp/main.go:211-219 | cmd/walletminiapp/main.go:241-249 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ca26fe473a72a77fb45cafbfd9a54bbe6fc35a3729bc8f05509784574050f84"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/app/channels/service.go:445-453 | internal/app/channels/service.go:539-547 | internal/app/channels/service.go:585-593 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":445}}}],"partialFingerprints":{"codehealthFindingId/v1":"26dec9941f93e7d81ac749b276c1c0c8114049a3e7989a595858b6951fe8032d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/app/dialogs/draft_read_model_cache.go:104-112 | internal/rpc/peer_identity_cache.go:85-93 | internal/rpc/story_sparse_projection_cache.go:204-212 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/draft_read_model_cache.go:104\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/app/dialogs/draft_read_model_cache.go:102\u0060 calls \u0060uniqueDialogPeers\u0060 and \u0060internal/rpc/peer_identity_cache.go:83\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/draft_read_model_cache.go"},"region":{"startLine":104}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7cf123e868e1e690489d7ac599fdab2aa0aed67419a131d51a756ad9ae56866"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/botapi/bot_commands.go:32-40 | internal/botapi/bot_commands.go:64-72 | internal/botapi/bot_commands.go:81-89 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/bot_commands.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"97a3b3d676b7de2bb10907e3c1596cad6f4fa10048980a5b1c99922a67d49912"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/rpc/ephemeral.go:433-441 | internal/rpc/welcome_delivery_dispatcher.go:194-202 | internal/rpc/welcome_messages.go:315-323 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca8f831130f31961cd3c745b30338435abcbf5be622a993a4253082b193c088a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/memory/channel_settings.go:194-202 | internal/store/memory/channel_settings.go:228-236 | internal/store/memory/channel_settings.go:279-287 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":194}}}],"partialFingerprints":{"codehealthFindingId/v1":"48f1bec9ad1f731116a41aebc6ce991dcd89f677b34c143e64544e0da14e7c4f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/memory/collectible_username.go:297-305 | internal/store/memory/collectible_username.go:370-378 | internal/store/memory/collectible_username.go:435-443 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/collectible_username.go"},"region":{"startLine":297}}}],"partialFingerprints":{"codehealthFindingId/v1":"823363ea6a55d373999c39286cb8476c50e828d5a9b243924395e188ef4d9b5a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/memory/password.go:522-530 | internal/store/memory/users.go:57-65 | internal/store/postgres/channel_dialogs.go:1732-1740 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/password.go:522\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0343c76cde8fa113533f52a165ab38a84631d2376f62467841aef80dff07a96"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/memory/saved_dialog.go:145-153 | internal/store/memory/saved_dialog.go:196-204 | internal/store/postgres/dialog.go:1230-1238 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/saved_dialog.go:145\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5636f3b8b57fb6463330828f1e9b6455eeb99743719217c29b9c74a07fffd8f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/postgres/channel_reaction_unread.go:26-34 | internal/store/postgres/channel_read.go:290-298 | internal/store/postgres/channel_topics.go:630-638 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/store/postgres/channel_topics.go:630\u0060 is reached only past a guard at line 594 that tests \u0060member.AvailableMinID\u0060 and leaves the function early, and \u0060internal/store/postgres/channel_reaction_unread.go:26\u0060 reads \u0060member.AvailableMinID\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d8e474631953c3b69ae2b5d2bc0d98c34409d973fcb43845d42df1361f584e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/postgres/channel_updates.go:61-69 | internal/store/postgres/channel_updates.go:116-124 | internal/store/postgres/channel_updates.go:189-197 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7cb309b8e960270c4ca99db77592e103fa2052f3405f292c2e69292c61514bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/postgres/dialog.go:454-462 | internal/store/postgres/saved_dialog.go:136-144 | internal/store/postgres/saved_dialog.go:219-227 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":454}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbb5f2899503e008524ea3f1d4f7efb81b9e1a2ba5eabf858f3e79b82c4062a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): cmd/telesrv-admin/main.go:81-89 | cmd/walletminiapp/main.go:86-94 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/main.go:81\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/main.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"68f21af444f723dbeebb05d0a7ecf48f9e578caa2bdbac26139890c85df2e208"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): cmd/telesrv-admin/readstore.go:793-801 | cmd/telesrv-admin/readstore.go:896-904 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":793}}}],"partialFingerprints":{"codehealthFindingId/v1":"97485db44400369f5d6542a07151f3be19c8ab55efa14fc53e8d4fd147194441"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): cmd/telesrv-admin/readstore.go:3092-3101 | internal/store/postgres/premium.go:41-50 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:3092\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Check import visibility before settling on that home: \u0060internal/store/postgres/premium.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":3092}}}],"partialFingerprints":{"codehealthFindingId/v1":"e621db58eb15d9a5c8ffa7678eb7003dbf26f40d63572dd55c2f2211606a5c4a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): cmd/telesrv-admin/server.go:742-750 | cmd/telesrv-admin/server.go:1219-1227 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:742\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":742}}}],"partialFingerprints":{"codehealthFindingId/v1":"a41e89eda4fb9b13dba5803387bca9efd8c9afe79d5c2fe92ad12c6ddf8ff41f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): cmd/telesrv-admin/server.go:2024-2032 | cmd/telesrv-admin/server.go:2070-2078 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2024}}}],"partialFingerprints":{"codehealthFindingId/v1":"b58c2fb98a13203753363cf08a1029cb870a5c7ee1877320287b4be52b444dee"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): cmd/telesrv-admin/server.go:2920-2928 | cmd/telesrv-admin/star_gift_catalog.go:259-267 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060string\u0060 to \u0060fileName\u0060 in one and \u0060apiPath\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2920}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc7ce728506f41256c7598be0a694c3c9733e8d28597378136187dc4ce6cd7eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/admin/service.go:2187-2195 | internal/admin/service.go:2233-2241 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2187}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fc26d00642a9290a720d6905573182e2f7e51c26004e2159bc6cf500f1ca819"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/admin/service.go:2200-2208 | internal/admin/service.go:2246-2254 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:2200\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2200}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a0e493f6a832d163e11e405e468efc14d23168603bb4226d9a8ccccb4a3c818"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/adminapi/botverification.go:443-451 | internal/adminapi/verification.go:270-278 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/adminapi/botverification.go:443\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":443}}}],"partialFingerprints":{"codehealthFindingId/v1":"f82159894fbdf012c6bd9b642edfde7555c76e529009d34ecb763183c39abf38"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/adminapi/server.go:192-200 | internal/web/server.go:122-130 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/adminapi/server.go:192\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/adminapi/server.go:192\u0060 is reached only past a guard at line 169 that tests \u0060cfg.Addr\u0060 and leaves the function early, and \u0060internal/web/server.go:122\u0060 reads \u0060cfg.Addr\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"35e4586d704247aa2941dd346e81e685ea6b268466261bc847d951fd1e948222"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/app/ai/service.go:402-416 | internal/app/ai/service.go:427-441 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/ai/service.go:402\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":402}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbd5d42460ab8474d1a2d804c4827ffb5fa69f742cef251c2fd333e8d3e818e5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/ai/service.go:559-567 | internal/store/memory/ai.go:147-155 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/app/ai/service.go:569\u0060 calls \u0060Clone\u0060 and \u0060internal/store/memory/ai.go:156\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":559}}}],"partialFingerprints":{"codehealthFindingId/v1":"97f208f3a7a2e55e427b8b6c05d00e613fc8c7fa7395c2fecf6ee8f8b2cc4798"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/channels/service.go:459-467 | internal/app/channels/service.go:500-508 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":459}}}],"partialFingerprints":{"codehealthFindingId/v1":"7702cd557d483e5ce57833912aed372ca1fbdcb738dac71759031d609f71b82a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/channels/service.go:1088-1096 | internal/app/channels/service.go:1102-1110 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1088}}}],"partialFingerprints":{"codehealthFindingId/v1":"25467ea92ec9eb014952c9163b1555e78673f022b6310974a26cb232431b8666"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/dialogs/service.go:303-311 | internal/store/memory/dialogs.go:117-125 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/service.go:303\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"399c64c31bab1a1a804b360428a7a069413f808f6b92163688a0c0d5cca34322"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/files/appearance_seed.go:178-186 | internal/app/files/appearance_seed.go:203-211 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/appearance_seed.go:178\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc1aab168764bc5d175ea71796d619fb98f4f628dd5e5a7c5cab805ffbd65c24"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/files/mp4faststart.go:211-219 | internal/app/files/mp4faststart.go:229-237 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/mp4faststart.go:211\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/mp4faststart.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff351acd0e4586228d1303284161b6dc08cc1d9e5f1a1d336419ed2eaee63b02"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (4\u20139 lines \u00D7 3): internal/app/messages/service.go:472-475 | internal/app/messages/service.go:483-491 | internal/app/messages/service.go:497-505 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/messages/service.go:472\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7abed744eb17b8a2f9b69dfd8be108ca8db3a9048c091427d65d9bdbd9f3a8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/messages/service.go:572-580 | internal/app/messages/service.go:586-594 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":572}}}],"partialFingerprints":{"codehealthFindingId/v1":"6613124e3a8009a5a96663ac2e9949fa52741e2f5095c65e858109c124887493"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u20139 lines \u00D7 2): internal/app/telegramlogin/service.go:1028-1035 | internal/app/telegramlogin/service.go:1049-1057 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":1028}}}],"partialFingerprints":{"codehealthFindingId/v1":"d96f869340851838482c8bedf317cf9f986fe2931282209c24642ea0f293b4af"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/usernames/service.go:192-200 | internal/app/usernames/service.go:517-525 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/usernames/service.go:192\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/usernames/service.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"6436453f8c204e5665cb9e033d2972429616e68ef1ab81f7fa9584359e8c3677"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/mtprotoedge/inbound_layer_rpc.go:623-631 | internal/mtprotoedge/inbound_preflight.go:882-890 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":623}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0740d02c715e3e2e125d8003bd4ff79a90f6beeb06c38c1edd35acebe4e4d20"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/mtprotoedge/session_manager.go:2359-2367 | internal/mtprotoedge/session_manager.go:2451-2459 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:2359\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":2359}}}],"partialFingerprints":{"codehealthFindingId/v1":"e95b41b96d81241ec12fa81ab2e683e593d7ff2af92657b876158cbf46ddeacf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/account_themes.go:118-126 | internal/rpc/send_media.go:684-692 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_themes.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"f33846c8266323c105feb4454547745124acbf8a17b4dde347d43427123332a6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/bots_callback.go:171-179 | internal/rpc/bots_callback.go:226-234 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bots_callback.go:171\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd9478b6100f994ee0a009d8d05e010a6cbe2ec5a8ddca9056952d339cd4fd40"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/channel_fanout_dispatcher.go:1029-1037 | internal/rpc/channel_fanout_dispatcher.go:1133-1141 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channel_fanout_dispatcher.go:1029\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1029}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf75304ccdae19f46996a7f4f0c01c19aa2b0bf84efc885887eff329917aad75"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/channels_invites.go:379-387 | internal/rpc/contacts.go:184-192 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_invites.go:379\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"95d5646560debdba968fe58b1d4b18f1e52897edf4b6085b4bccd0ca8b74c397"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/contacts.go:301-309 | internal/rpc/contacts.go:335-343 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/contacts.go:301\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7b6f50caeb813bbc64ec7d355e24a325229ebc8f8a7376335dd2c11c41d583d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/contacts.go:521-529 | internal/rpc/contacts.go:546-554 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/contacts.go:521\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":521}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e678c86dd130eea6c6445f16f6154441996220cb1d0766caa407a95a7c134d8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/convert_business.go:220-228 | internal/rpc/convert_business.go:277-285 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/convert_business.go:220\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/rpc/convert_business.go:287\u0060 calls \u0060SetExcludeUsers\u0060 and \u0060internal/rpc/convert_business.go:229\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_business.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"83404219742b523f8f7268c5da83f43fd0841926edf4318deb025ab3c45845a2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/convert_markup.go:517-525 | internal/rpc/convert_markup.go:534-542 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/convert_markup.go:517\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":517}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e27e9cdf7cb24250ca2faf0e9b95c0a16047f7cb7a6ec9675dfe252851b06f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/convert_rich_message.go:276-284 | internal/rpc/convert_rich_message.go:286-294 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_rich_message.go"},"region":{"startLine":276}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a9e37b3f97403cedc0ffb9351337d281d24cbafdb2e344cb28b71988adfb25a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/layer_dispatch.go:333-341 | internal/rpc/router.go:842-850 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/layer_dispatch.go:333\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_dispatch.go"},"region":{"startLine":333}}}],"partialFingerprints":{"codehealthFindingId/v1":"dddd951514c3af1c9351b014aa6b334c76020a54437a73cfb46fca988eaa351f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/messages_delete.go:45-53 | internal/rpc/messages_reactions_lists.go:318-326 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_delete.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"105e286f3a6253dae25f0167c09a358d1b551409f1b07c1e6bdb1662905a53bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/messages_forum.go:127-135 | internal/rpc/messages_forum.go:191-199 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_forum.go:127\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"602161329fe4557bc7024e3cc34c2d16b435b026c200056b1c5cc2f07f49c2eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/messages_forum.go:436-444 | internal/rpc/messages_forum.go:457-465 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_forum.go:436\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":436}}}],"partialFingerprints":{"codehealthFindingId/v1":"b61320c2ff17d363b3ed1821846c9d0e1ffa77e876c4a9af8092e5fe8aeb6774"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/messages_polls.go:268-276 | internal/rpc/messages_reactions_lists.go:307-315 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_polls.go:268\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"df029030f77afd1405fdf102b4bf371f9a40bb4e1120d30780df6de6ed1c2ec5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/outbox_update_builder.go:243-251 | internal/store/postgres/channel_core.go:618-626 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_core.go:618\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/outbox_update_builder.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e3ce49e6566d299300ae3be3c8218fae1764912adfe0d0ff93e2cd767d17038"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/payments_star_gift_lifecycle.go:396-404 | internal/rpc/payments_star_gift_unique.go:133-141 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gift_lifecycle.go:396\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"3272228a939ee68b03151ab48764f3cfb0cfea3100b29f053d2c2f3cf37690c2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/payments_star_gifts.go:315-323 | internal/rpc/payments_star_gifts.go:541-549 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gifts.go:315\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6ce292fbf43cb83f40ad5f3a228b8189135b2e9eb96dff9629d2919cef6fa66"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/payments_star_gifts.go:747-755 | internal/rpc/payments_star_gifts.go:774-782 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gifts.go:747\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":747}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c416fbc66a510c1deef0a654645543292b06753f341ed7a4547b0ae1c9b6845"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/payments_star_gifts.go:988-996 | internal/rpc/payments_star_gifts.go:1050-1058 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gifts.go:988\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":988}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3f35a84fcc47448e3d896a1de1c322b14b7a09caaca03bbf825e08bc827a5c4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/router.go:1406-1414 | internal/rpc/router.go:1438-1446 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/router.go:1435\u0060 calls \u0060clientSessionInfoStoredLocked\u0060 and \u0060internal/rpc/router.go:1405\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1406}}}],"partialFingerprints":{"codehealthFindingId/v1":"85fec5c144bd64a9f1e1f47a3deb7325351cd0c8e8630ae6cfc94a9d1611af57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/router.go:1519-1527 | internal/rpc/router.go:1553-1561 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/router.go:1519\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1519}}}],"partialFingerprints":{"codehealthFindingId/v1":"af680ff500da3659a54065ddbef252f3769ea920996d94d7cec14b7d2063d33f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/stories.go:786-794 | internal/rpc/stories.go:807-815 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:786\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":786}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ee575d38b63f8e9c4e1add5b51d04509092ef55cd7e35d1c412a56edbbceb4f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_core.go:213-221 | internal/store/memory/channel_dialogs.go:114-122 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_core.go:213\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"675b58aebc4951b0fac95c709b2474bc41641b243da78cfbf5824181fce89cd9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_helpers.go:775-783 | internal/store/postgres/channel_helpers.go:930-938 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_helpers.go:775\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":775}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b2fbf15d250f645378af01859bf13ccae141773228a8b3b45ed1ba10dc75ca8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_invites.go:477-485 | internal/store/memory/channel_invites.go:499-507 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":477}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7db56ab77983b76ac2f9d731b548f20119ab599a3fa283936738d7ee0886c13"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_invites.go:707-715 | internal/store/memory/channel_members.go:832-840 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_invites.go:707\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":707}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cedaef0e628c768ae9100e0e58eafbbff73d5b71ad6b90724a56c37de6c8045"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_members.go:26-34 | internal/store/postgres/channel_member_list.go:33-41 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"292d2c7edd9ec0e328250eb33f0f803f2c22bc17f7cdae75564f075f1c4ae331"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_members.go:222-230 | internal/store/postgres/channel_member_join.go:184-192 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:222\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"53c0abaecf3010c7c8d7c4a1b99d3fa6a717a4e70c249ae045908b48c7cf6a9c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_message_delete.go:159-167 | internal/store/memory/channel_topics.go:368-376 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_delete.go:159\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"25763d47ab6f16bc31afce3416fac3d8aadff4fa331e3a6bfe507ecb257cd6f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_message_send.go:24-32 | internal/store/memory/channel_monoforum.go:27-35 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_send.go:24\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"4186175593eab8542f9d3f65f965ded7b549d4fb565fcb63431f58a436b08ecf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_reactions.go:69-77 | internal/store/postgres/channel_reaction_messages.go:63-71 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_reactions.go:69\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/channel_reaction_messages.go:75\u0060 calls \u0060Exec\u0060, \u0060Errorf\u0060 and \u0060internal/store/memory/channel_reactions.go:81\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"402babc0d58eae674f496eeb6e10eeb40c75730340fa0260cf002b1c7a204bc5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/dialogs.go:257-265 | internal/store/postgres/dialog.go:840-848 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/dialogs.go:257\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"09ca68defbe02d1bc8659e2c041c31f284517ba6c5e3d2d1aa71780f6b9c13a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/message_pin.go:15-23 | internal/store/postgres/message_pin.go:27-35 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"81dd8d36ecf64322ac581f90b600b61729563d55a2bf0bbaff5d9ee7849a23b7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/message_reactions.go:13-22 | internal/store/postgres/message_reactions.go:17-26 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e012a022cde6c848b65436226d53c068d2eaf82a68f76632fa8e50e5992b90f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/story.go:852-860 | internal/store/memory/story.go:862-870 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/story.go:852\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":852}}}],"partialFingerprints":{"codehealthFindingId/v1":"c99ba99202ed516ae51ed62cd4207cd8400cb146e2c0668f7292ec5787ad0261"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/story.go:924-932 | internal/store/memory/story.go:955-963 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/story.go:924\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":924}}}],"partialFingerprints":{"codehealthFindingId/v1":"68710778fcd31930ca0f73d5230fbd2f917d39c45155508045f58347ac3a92eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/telegram_login.go:110-118 | internal/store/memory/telegram_login.go:131-139 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/telegram_login.go:110\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"86717075b50dce3ca8720feec0467b61bc39409361f942dda74224c2a7945cec"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_dialogs.go:58-66 | internal/store/postgres/channel_dialogs.go:301-309 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ae91cec31b6fe755eac06783c5726722b10bd2322c0ad985b5c24aeeeecef79"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_invite_import.go:203-211 | internal/store/postgres/channel_member_join.go:102-110 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_invite_import.go:203\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"6da3eedb229a6c7570503de04fc2f72e8614231af075f79fe51a53034807ab69"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_invite_import.go:237-245 | internal/store/postgres/channel_member_join_requests.go:95-103 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_invite_import.go:237\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb54433ab686f1f6ba68066f3d27cc2acc3853d1bfceab7fcb9c26871e277837"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_member_admin.go:236-244 | internal/store/postgres/channel_member_admin.go:246-254 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_admin.go:236\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"45945756bf0cae25eece3f0a90b820535c00c5048b44b48c2baec90b7610bf47"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_member_join_requests.go:44-52 | internal/store/postgres/channel_member_join_requests.go:70-78 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/channel_member_join_requests.go:79\u0060 calls \u0060TrimSpace\u0060 and \u0060internal/store/postgres/channel_member_join_requests.go:53\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join_requests.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"97ed68945cb08e4ca35af54abe10b4f55f1b5f4e2c5ab59479c0c64c8f96c954"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_message_send.go:175-183 | internal/store/postgres/channel_message_send.go:233-241 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"80b29842f3684e5b81e5ba9524ff4226c3f4c32338efdd6af6ae1e30b4b89c6e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8\u20139 lines \u00D7 2): internal/store/postgres/channel_message_send.go:262-270 | internal/store/postgres/channel_monoforum.go:164-171 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_send.go:262\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"9502b70f53d14e225f331961d6f9ddc67bf1efb8e2c2732dc222959bae7d1454"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/store/postgres/moderation_cases.go:775-794 | internal/store/postgres/moderation_cases.go:823-842 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_cases.go:775\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":775}}}],"partialFingerprints":{"codehealthFindingId/v1":"49db31d9af01820efc5d23faf5b484f4230590a004874898a9fb11f8af7ec128"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/saved_dialog.go:119-127 | internal/store/postgres/saved_dialog.go:165-173 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/saved_dialog.go:119\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"9df8be56660d3153da036040c73ffd7955ca14ba3c72d5575fd25e1718b76629"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (16 lines \u00D7 2): internal/store/postgres/star_gift_lifecycle.go:758-773 | internal/store/postgres/star_gift_lifecycle.go:1182-1197 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_lifecycle.go:758\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":758}}}],"partialFingerprints":{"codehealthFindingId/v1":"24410a6ee1ed46ef57710d85fa8ba865615bb0f595d4ba138f5c8251dcb0425a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/star_gift_lifecycle_projection.go:155-164 | internal/store/postgres/star_gift_upgrade.go:829-838 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_lifecycle_projection.go:155\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle_projection.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"844fbe710a83f46aa95d048b95085b3b51e9f561ae212256e49beae7595985d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/user.go:921-929 | internal/store/postgres/user.go:935-943 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/user.go:921\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f52fa1b901b7518c3bcaeda6658a471bbb8b31115ddec03e8c204e224a34169"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 9): cmd/telesrv-admin/server.go:971-978 | cmd/telesrv-admin/server.go:1635-1642 | cmd/telesrv-admin/server.go:1680-1687 | cmd/telesrv-admin/server.go:2034-2041 | cmd/telesrv-admin/server.go:2080-2087 | cmd/telesrv-admin/server.go:2157-2164 | cmd/telesrv-admin/serversettings.go:241-248 | cmd/telesrv-admin/star_gift_catalog.go:92-99 | cmd/telesrv-admin/star_gift_catalog.go:375-382 \u2014 there are 9 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 9 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:971\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":971}}}],"partialFingerprints":{"codehealthFindingId/v1":"48be042daaf7ba2e08b8ddbb8ad4fcc70694bd8cfe3d5ae6b3d262aebd1c7370"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u20138 lines \u00D7 7): internal/admin/service.go:1906-1913 | internal/admin/service.go:1946-1953 | internal/admin/service.go:1983-1989 | internal/admin/service.go:2016-2022 | internal/admin/service.go:2053-2060 | internal/admin/service.go:2200-2206 | internal/admin/service.go:2246-2252 \u2014 all 7 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:1906\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/admin/service.go:2013\u0060 calls \u0060TrimSpace\u0060, \u0060TrimPrefix\u0060 and \u0060internal/admin/service.go:1904\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1906}}}],"partialFingerprints":{"codehealthFindingId/v1":"2297c6cd43411a0b91495938693ba3ad5d6ac4bca7283721d70b2d4051678286"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 5): internal/adminapi/server.go:838-845 | internal/adminapi/server.go:872-879 | internal/adminapi/server.go:915-922 | internal/adminapi/server.go:967-974 | internal/adminapi/server.go:1319-1326 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/adminapi/server.go:838\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":838}}}],"partialFingerprints":{"codehealthFindingId/v1":"7babe93ff482b3b916836b92c355a391468571a675813f7d4cfd8d7fde6db692"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 5): internal/app/dialogs/service.go:315-322 | internal/app/dialogs/service.go:1466-1473 | internal/store/memory/channel_dialogs.go:82-89 | internal/store/postgres/channel_dialogs.go:428-435 | internal/store/postgres/channel_dialogs.go:572-579 \u2014 there are 5 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/service.go:315\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2f2d2015fb28a6cb4ab3266b50a83296095a54f0802c2d488300c8e9875457c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 5): internal/store/postgres/message_history.go:693-700 | internal/store/postgres/message_history.go:765-772 | internal/store/postgres/message_history.go:837-844 | internal/store/postgres/message_history.go:909-916 | internal/store/postgres/message_history.go:981-988 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_history.go:693\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":693}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4333399310e255549ecaf3e0ce556a273c3c2eb555a30de38d24afb05fe00e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/app/dialogs/list_snapshot_cache.go:198-205 | internal/rpc/channel_interest.go:188-195 | internal/rpc/messages_dialogs.go:320-327 | internal/store/postgres/channel_dialogs.go:2227-2234 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/list_snapshot_cache.go:198\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"059a8c123a03d24c404bcd8c9bb29ce9e4fdf2c9e61576ab7c317a03a671cc66"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/botapi/ephemeral.go:116-123 | internal/botapi/ephemeral.go:179-186 | internal/botapi/server.go:555-562 | internal/botapi/server.go:709-716 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/botapi/ephemeral.go:116\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e83915871e0298abc3bbb7f1170a835bae4aa5ad079f9dd91c8de8de9c293ad"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/rpc/messages_dialogs.go:749-756 | internal/rpc/messages_dialogs.go:883-890 | internal/rpc/messages_dialogs.go:961-968 | internal/rpc/messages_saved_dialogs.go:181-188 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_dialogs.go:749\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":749}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0f4c2a648b02b7938de3d3816870ff46fa76aca4e0c0643df9848436c317da2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/store/memory/channel_members.go:649-656 | internal/store/memory/channel_members.go:674-681 | internal/store/memory/channel_members.go:699-706 | internal/store/memory/channel_members.go:727-734 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:649\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":649}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9ae14fce8afa69dc907db753a3067f1dc9bd95de07838eec96e9a1f50651402"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/store/postgres/community.go:1085-1092 | internal/store/postgres/community.go:1107-1114 | internal/store/postgres/community.go:1178-1185 | internal/store/postgres/community.go:1201-1208 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/community.go:1085\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1085}}}],"partialFingerprints":{"codehealthFindingId/v1":"d34e9b5d4ca804545c05d9e572c8c9bed59691440ecef0575a147290be769fe6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/app/ai/service.go:466-474 | internal/app/ai/service.go:508-516 | internal/app/ai/service.go:531-539 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/ai/service.go:466\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":466}}}],"partialFingerprints":{"codehealthFindingId/v1":"45f16106145fc20f175ab9ead3f8fdf8a3d4f92b1172f1f488ce5a6575cbb6ae"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/app/channels/service.go:2241-2248 | internal/store/memory/channel_message_history.go:415-422 | internal/store/postgres/channel_message_history.go:585-592 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/channels/service.go:2241\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2241}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a9806b4b2bde14f22be3463f4b93912d73fa974b67f65a6174dbc44d461673a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/app/files/seed.go:255-262 | internal/app/files/seed.go:276-283 | internal/app/files/seed.go:295-302 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/seed.go:255\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5275883e4de80935514256e622a802a1dbb01d78cbdfce4a8ed26278ae080b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/app/usernames/service.go:328-335 | internal/app/usernames/service.go:358-365 | internal/app/usernames/service.go:382-389 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/usernames/service.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"17cddbca20e3a2cce2b1313e94bbe28e2b31e76210847e636b97162dca7fef82"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/domain/story.go:92-99 | internal/store/memory/story.go:1518-1525 | internal/store/postgres/story.go:2361-2368 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/story.go"},"region":{"startLine":92}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0e5985a1b9bb84df76c8905ff5a332d75ccea741f879c8c08dfb64c54ed6946"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/rpc/channels_legacy_chat.go:177-184 | internal/rpc/channels_members.go:451-458 | internal/rpc/messages_bot_no_state.go:23-30 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/rpc/channels_legacy_chat.go:177\u0060 is reached only past a guard at line 174 that tests \u0060req.UserID\u0060 and leaves the function early, and \u0060internal/rpc/channels_members.go:451\u0060 reads \u0060req.UserID\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee12fca4eb19ac90bf395c8f7480866e4fd5947d9543ce32de6167692b955792"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/rpc/channels_read_reactions.go:17-24 | internal/rpc/channels_read_reactions.go:64-71 | internal/rpc/channels_settings.go:39-46 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_read_reactions.go"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"56ddc1a6c9a4ee1a0c03620cbc463428278b27801af65413ac8e4cbb4cd3658f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/rpc/messages_edit.go:177-184 | internal/rpc/messages_edit_geolive.go:111-118 | internal/rpc/messages_todos.go:268-275 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_edit.go:177\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/messages_edit.go:176\u0060 calls \u0060enqueueBotAPIPrivateEditUpdatesAsync\u0060 and \u0060internal/rpc/messages_edit_geolive.go:110\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"2263d076c2fe59b2e63b01bd32841822d3da5f864e31a25adced0d68e367e3f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/rpc/messages_reactions_helpers.go:51-58 | internal/rpc/payments.go:329-336 | internal/rpc/stories.go:3091-3098 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_helpers.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d57fe20532f1921fec6a57a05dd8bac81938f9b2b47cf1da08ffa633ce27cf8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/store/postgres/channel_member_admin.go:73-80 | internal/store/postgres/channel_member_admin.go:238-245 | internal/store/postgres/channel_member_admin.go:248-255 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_admin.go:73\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb68825cdc4d6e5627d3a1457dcca224a130da5d43d6eb430b595b44c890b015"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/store/postgres/moderation.go:121-128 | internal/store/postgres/moderation_registries.go:86-93 | internal/store/postgres/moderation_registries.go:211-218 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation.go:121\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"204526a629817fe13b97e929b8c6fe4e500065b4680c9d83d4b84eaf90606c96"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): cmd/catalogfetch/main.go:105-112 | cmd/stickerfetch/main.go:170-177 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/catalogfetch/main.go:105\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/catalogfetch/main.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bb14d740aeea63641d553f20d706cc1d4821ea16e4367070259a4800fc28a98"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): cmd/telesrv-admin/readstore.go:2105-2112 | cmd/telesrv-admin/readstore.go:3368-3375 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":2105}}}],"partialFingerprints":{"codehealthFindingId/v1":"1840907f904dba66526f8bc2603459188ebc7d8eb31aa358c54775ed80a9fd5b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): cmd/telesrv-admin/readstore.go:3202-3209 | internal/store/postgres/donations.go:270-277 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:3202\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Check import visibility before settling on that home: \u0060internal/store/postgres/donations.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":3202}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e48715f85a9f4cc6cee7ce24baa5b2fa2af64fe534a1bc99174c0d02de352f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): cmd/telesrv-admin/server.go:961-969 | cmd/telesrv-admin/server.go:1625-1633 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":961}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cf5d7c814dcb2cc6404592a8143417be063a19e354575d3645d10fd10c85238"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/admin/service.go:2099-2106 | internal/admin/service.go:2145-2152 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:2099\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2099}}}],"partialFingerprints":{"codehealthFindingId/v1":"87c6591f4b78fc85b893090873e47f1d407ca9bad0d8436007e4e6e64af1ea89"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/adminapi/server.go:828-836 | internal/adminapi/server.go:862-870 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":828}}}],"partialFingerprints":{"codehealthFindingId/v1":"13a3e936c3aba328054d8010d8240499ae5c43df1f7b615754d0a02e2fc9a205"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/adminapi/server.go:1881-1888 | internal/adminapi/verification.go:217-224 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/adminapi/server.go:1881\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1881}}}],"partialFingerprints":{"codehealthFindingId/v1":"656f555fdf11fb6b31cf5bab9bf4cc4ec00dbdeef03d8a2b21a836d70266f2dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/bots/botfather.go:292-299 | internal/app/bots/botfather.go:372-379 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"90df454cb4e404160a8d4c17ead2ea10fcc851072aa3f50d541691e410f15a0f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (3\u20138 lines \u00D7 3): internal/app/channels/service.go:2026-2028 | internal/app/channels/service.go:2113-2120 | internal/app/channels/service.go:2144-2151 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/channels/service.go:2026\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2026}}}],"partialFingerprints":{"codehealthFindingId/v1":"6dd10a0fa16f5701c545469328b9635c00c2d6cbea851ac3191f2d17196504a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/channels/service.go:2526-2533 | internal/config/config.go:1957-1964 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/channels/service.go:2526\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2526}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd6f46cedcae84223ce629e8fdf1117e516c344fbf5d7644a557ddba76167912"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/chatlists/service.go:776-783 | internal/store/postgres/dialog.go:1073-1080 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/chatlists/service.go:776\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":776}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab14abffebe990086a202030dd929b955f719a7dacfda07a2ed266894468e827"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u20138 lines \u00D7 2): internal/app/ephemeral/service.go:107-113 | internal/app/ephemeral/service.go:244-251 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/ephemeral/service.go:107\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e69b0fee6a9ab4f13dd455fa737112481c2728db24ceaae011dea3b8830b0b9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/ephemeral/service.go:287-294 | internal/app/ephemeral/service.go:318-325 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"7076c06d206c34d6892122cff5ddb44c7d7fcafb1cab7f3d2203cf96690cf21f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/stargifts/service.go:649-656 | internal/store/postgres/star_gift_purchase.go:89-96 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/stargifts/service.go:649\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":649}}}],"partialFingerprints":{"codehealthFindingId/v1":"390f19d409d859a688abb5bee16e28dd503230ce5659e6c44e9e7c9b8d359715"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/domain/message_entity_autodetect.go:73-80 | internal/domain/message_entity_autodetect.go:169-176 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/domain/message_entity_autodetect.go:73\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad1c7f1d363e76845d4ef3d4f0b0b066ce043911e6016ab904245acd40b997a1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/mtprotoedge/outbound.go:1730-1737 | internal/mtprotoedge/outbound.go:1828-1835 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/outbound.go:1730\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1730}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ea6a7315b04d908e924d8e1e7d7bd33f20e33ff25f9ff0d8a4543c2a0c5a368"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/mtprotoedge/rpc_execution_ledger.go:260-267 | internal/mtprotoedge/rpc_flight.go:517-524 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/rpc_execution_ledger.go:260\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_ledger.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"5df547f92b57d8964b3c51bab1b08f7faa676279047ecdc4074aa49b544002e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/account_business.go:329-336 | internal/rpc/messages_helpers.go:177-184 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eca5650e8df1da081057b5bdcf436a7eb0ea77a41307c6fe352e4cc80fa46eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/bots_longtail.go:179-186 | internal/rpc/messages_pin.go:79-86 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bots_longtail.go:179\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":179}}}],"partialFingerprints":{"codehealthFindingId/v1":"da3dd733074d068f0743b5bd0ae30941229c8c5b87add2b8e38898a387c34b0b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/bots_longtail.go:372-379 | internal/rpc/bots_longtail.go:631-638 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e570a628e6d761d979174cc81f339fd52a55ef51191024a426a84d72ad2d4ed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/channels_invites.go:18-25 | internal/rpc/payments_star_gifts.go:106-113 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"c395905c2e95c420877b10e9ef1298177b448e453e693c43c73bdb59aa366c01"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/channels_members.go:660-674 | internal/rpc/channels_members.go:698-712 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_members.go:660\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fec803abc2634ecb4cf9429641fa0c7b7814403385dd331fae0185ad1eea91d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/channels_settings.go:124-131 | internal/rpc/channels_settings.go:145-152 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"44b15d29c0725c89f047f084a4b312e1b735ce15e71661339e8fed7ad97eb377"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/channels_settings.go:548-555 | internal/rpc/channels_settings.go:557-564 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ab7b78ff23fdf3d2e1214b3be4211971f132a7358256ead0672566b414d3f24"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/contacts.go:617-624 | internal/rpc/contacts.go:695-702 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":617}}}],"partialFingerprints":{"codehealthFindingId/v1":"40f7bb86d21c0ef0c49f3db0495c40db9312766c6de0dabbb167e25116d6484c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/ephemeral.go:54-61 | internal/rpc/ephemeral.go:130-137 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"7003d2cdde00db480e4854b21d62ecf771ebd76fb610ce3049935fb6c45bd689"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/fragment.go:255-262 | internal/rpc/story_peer_projection.go:568-575 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/fragment.go:255\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/fragment.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fe5cdc91ecea160fa6d0db433a2e659973e22ed92e1758bc0f8fce09f77477f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_dialogs.go:318-325 | internal/store/postgres/channel_dialogs.go:964-971 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_dialogs.go:318\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"45215118035864ede7b193776227a70abd9019de37c34e802dcb0236edc4788d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_dialogs.go:632-639 | internal/rpc/messages_dialogs.go:693-700 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_dialogs.go:632\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":632}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0f3d74836c045f81db1335486b8a58dad18e8e12221197e8f96aef2eae2a20b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_dialogs.go:653-660 | internal/rpc/messages_saved_dialogs.go:156-163 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":653}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ae006079417bc41b4c88ebccebf59a24a0c1cc63c21b4ab2a622a50c611cdd0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_dialogs.go:874-881 | internal/rpc/messages_saved_dialogs.go:172-179 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_dialogs.go:874\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":874}}}],"partialFingerprints":{"codehealthFindingId/v1":"070dc1d8788523f3a5249f63f297e49c1241b275612e9b8de91ab8b2e82c533c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_forward.go:197-204 | internal/rpc/messages_forward.go:437-444 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"c81ede5768a0ee37e87e00ea34a19e5d96ec350d03f16c298b4061561adc95df"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_games.go:24-31 | internal/rpc/messages_games.go:57-64 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_games.go:24\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_games.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a83019488bee5726c7ea5370be87e7c14d03eaea486aa3406ccf69986bd3b42"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_polls.go:56-63 | internal/rpc/messages_polls.go:73-80 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_polls.go:56\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b19d38f95c197c90bab294f718a5226c7196c6f1b33682a199a3f13397553b9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_read.go:166-173 | internal/rpc/messages_read.go:178-185 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"16d85159fe204d5cffa7e3f783eec7e2a396c03db3cc2ae4bc25fe634184e9b7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_register.go:647-654 | internal/rpc/messages_register.go:875-882 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_register.go:647\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_register.go"},"region":{"startLine":647}}}],"partialFingerprints":{"codehealthFindingId/v1":"7efd0747341ed38df73f04492d008d5de01bd0ffedfb7fcb699e1ae22edb53c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_saved_dialogs.go:93-100 | internal/rpc/messages_saved_dialogs.go:136-143 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_saved_dialogs.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"6958116b8587ca9e60f814e3383bc8f339aea5675d5f70af9bc9f08c1e3d2f57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/messages_send.go:318-326 | internal/rpc/messages_send.go:328-336 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1d82a894af92a45c52884cdff69b34518ca7723ec639625f1df57ee309719f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/payments.go:215-222 | internal/rpc/payments.go:240-247 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments.go:215\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments.go"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a9fc92f89e4cc6e00f7cd8695647b6e747909633c2d3e19bc88fbd002c5c4b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/payments_star_gift_lifecycle.go:323-330 | internal/rpc/payments_star_gifts.go:690-697 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gift_lifecycle.go:323\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a50d061b6fbbb49a26b28ba5f911176f097854542d82e8e9b057c371e8e1406"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/payments_star_gifts.go:757-764 | internal/rpc/payments_star_gifts.go:927-934 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gifts.go:757\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":757}}}],"partialFingerprints":{"codehealthFindingId/v1":"758dcc2111009f7165bd716b282651a273e14e1cc939a8a89cdce06895073fca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/bot_verification.go:246-253 | internal/store/postgres/bot_verification.go:289-296 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"935222c383e2902d8739298c2ba526893df0b9d477d1c41534329c114a86da57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/business.go:387-394 | internal/store/memory/business.go:402-409 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/business.go"},"region":{"startLine":387}}}],"partialFingerprints":{"codehealthFindingId/v1":"d66fada7263185646026d9964b0a8d76399149c5d84ce3c9f900ac3b03fc5bf6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/channel_message_send.go:145-152 | internal/store/postgres/channel_message_send.go:222-229 \u2014 \u0060internal/store/memory/channel_message_send.go\u0060 and \u0060internal/store/postgres/channel_message_send.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 4 separate duplicated blocks between them, totalling at least 43 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_send.go:145\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"139772a0aca2ab54ae21cf0f3c3e56208dcbff28e9c0f2a1089cebb509e4b46f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/channel_message_views.go:33-40 | internal/store/memory/channel_reactions.go:307-314 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_views.go:33\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_views.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"a20c74b5aab709714058f49f8a425a490ba1fb6b4fd0cb136a67de2f5da690ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/channel_read.go:330-337 | internal/store/postgres/user.go:531-538 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"557f7f1d04f09797da2d7e373335af7bf78346f78a204f97baf40ffdb28b3e55"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u20138 lines \u00D7 2): internal/store/memory/community.go:939-946 | internal/store/postgres/community.go:1209-1215 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/community.go:939\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060id\u0060 in one and \u0060communityID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":939}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4061e90667dd185d41f525ce9c0bc0b37806b73fdad6e0187472c90711dab7b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/message_delete.go:15-22 | internal/store/postgres/message_delete.go:21-28 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_delete.go:15\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_delete.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ba160a0c18827c0778de5f60ca6fdccd5293989a920c3971750923da617b433"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/message_helpers.go:265-273 | internal/store/postgres/message_helpers.go:360-368 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_helpers.go:265\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/message_helpers.go:369\u0060 calls \u0060PutUint64\u0060 and \u0060internal/store/memory/message_helpers.go:274\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_helpers.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6556455643c0bd94af8acfd3ed5157aab126d0681c62c69eee30a2a25e2140a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/message_history.go:82-89 | internal/store/memory/message_history.go:218-225 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"04ae35cc0f296efd6f1c2f94103be1d44f3cd733f95ce8e3dada62c609e8de55"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/moderation.go:504-511 | internal/store/postgres/moderation_cases.go:204-211 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/moderation_cases.go:202\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/memory/moderation.go:503\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":504}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4470556c8c7d4dc83f3e3cf56d36bab35c171f1734a06c3ea68d91957b05c0e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/moderation.go:601-608 | internal/store/postgres/moderation_cases.go:388-395 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":601}}}],"partialFingerprints":{"codehealthFindingId/v1":"759d39bd93349693940a3e4f18b49ff58ca71c54833e8234689f2733883989cc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/verification.go:203-210 | internal/store/memory/verification.go:245-252 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/verification.go:203\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f0fc170657a64dc6472d6cd49bf595ccd5edd077bb2471128c00ee941dabbc6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/verification.go:507-514 | internal/store/postgres/verification.go:710-717 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":507}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef36d44ac56cf219d74aa0a7052580258cb717b60f0abf0b10f912b842304130"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_dialogs.go:220-232 | internal/store/postgres/channel_dialogs.go:406-413 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_dialogs.go:220\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ec5a9fd9ed588eb28ce5ecbb178bb678a381a29ef4838fef2f5ce2ac9e3899a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7\u20138 lines \u00D7 2): internal/store/postgres/channel_member_join.go:256-263 | internal/store/postgres/community.go:896-902 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_join.go:256\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/store/postgres/community.go:896\u0060 is reached only past a guard at line 867 that tests \u0060domain.ChannelMemberActive\u0060 and leaves the function early, and \u0060internal/store/postgres/channel_member_join.go:256\u0060 reads \u0060domain.ChannelMemberActive\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"b670eb982509e4f97f167b75e0d8b8357442376fea652948e1fab99d81418774"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_message_delete.go:360-367 | internal/store/postgres/channel_message_delete.go:429-436 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_delete.go:360\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3da5cc3f12de9a74a5a7a03b039b5cbedc9dcc63a21cdbd632bc96a70a53d7d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_message_helpers.go:31-38 | internal/store/postgres/channel_message_helpers.go:90-97 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_helpers.go:31\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_helpers.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"f747df005be022a020e456a121c21ae7d9e3684eb48e24badee6c7662c9b2ede"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_message_history.go:66-73 | internal/store/postgres/channel_message_history.go:412-419 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d0e993b0b20b79db5595a9303648fa590ab5e61b967c4f9b4b3b949d8a2e695"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_settings.go:1227-1234 | internal/store/postgres/channel_settings.go:1257-1264 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":1227}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c749a2523d618698577f69a51ee2c1622506728d42465f3c53220d930438848"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_topics.go:134-141 | internal/store/postgres/channel_topics.go:209-216 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_topics.go:134\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"4e24ca2391ce26ac7fafca2e64eb99a4c79df21a2192a824589952d6ce28aa66"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/moderation_cases.go:120-127 | internal/store/postgres/moderation_cases.go:210-217 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_cases.go:120\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"749379779c1a406d3ee7aa810cfe7dd8c58bbcff861d9212f6052ef82f512677"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/premium.go:506-513 | internal/store/postgres/premium.go:541-548 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/premium.go:506\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c1a2b29c93d01c1f4f0cb373bf119768206e6e450f693439cb5d0dbd3365b65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/read_model_listener.go:591-598 | internal/store/postgres/read_model_listener.go:626-633 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/read_model_listener.go:591\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/read_model_listener.go:634\u0060 calls \u0060InvalidateRPCProjectionReadModelForPeer\u0060, \u0060InvalidateRPCProjectionReadModelForUser\u0060 and \u0060internal/store/postgres/read_model_listener.go:599\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_listener.go"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4c029a4a77a96280e4970c97dce2d313b627c4066add00592853747544cadd0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/star_gift_lifecycle.go:1727-1734 | internal/store/postgres/star_gift_lifecycle.go:1846-1853 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_lifecycle.go:1727\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1727}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f289f176bd034a3c232777d3bac8e76847429fce571293aa47ea3ec8ce2553d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/star_gift_lifecycle_projection.go:175-182 | internal/store/postgres/star_gift_upgrade.go:855-862 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_lifecycle_projection.go:175\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle_projection.go"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"1210c5af3ab386e948c87ab97481077b2b2bcd661492bf66413e7e6a7840bd94"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 10): internal/admin/service.go:1563-1569 | internal/admin/service.go:1906-1912 | internal/admin/service.go:1946-1952 | internal/admin/service.go:1983-1989 | internal/admin/service.go:2016-2022 | internal/admin/service.go:2053-2059 | internal/admin/service.go:2099-2105 | internal/admin/service.go:2145-2151 | internal/admin/service.go:2200-2206 | internal/admin/service.go:2246-2252 \u2014 all 10 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/admin/service.go:2013\u0060 calls \u0060TrimSpace\u0060, \u0060TrimPrefix\u0060 and \u0060internal/admin/service.go:1561\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1563}}}],"partialFingerprints":{"codehealthFindingId/v1":"44b5fdfce1e94c0b3859b4901dca0d757c6bd3692b183a8756cd32a95d87e004"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 5): internal/adminapi/server.go:830-836 | internal/adminapi/server.go:864-870 | internal/adminapi/server.go:907-913 | internal/adminapi/server.go:959-965 | internal/adminapi/server.go:1311-1317 \u2014 all 5 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":830}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0b11c68ac115ff72d3b76d4168ea1f81040e4e6518113ddea91a402a95b3286"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 5): internal/app/dialogs/list_snapshot_cache.go:197-203 | internal/rpc/channel_interest.go:187-193 | internal/rpc/messages_dialogs.go:319-325 | internal/store/postgres/channel_dialogs.go:965-971 | internal/store/postgres/channel_dialogs.go:2226-2232 \u2014 there are 5 copies across 4 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b96a9527647ba050279267b7ac1754d651e18e6906d3e76b2262a340c4c7e8c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 5): internal/app/privacy/service.go:570-577 | internal/rpc/stories.go:2897-2904 | internal/rpc/story_pinned_stories_cache.go:146-153 | internal/store/memory/story.go:1464-1471 | internal/store/postgres/story.go:2591-2598 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 5 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 5 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/stories.go:2897\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/service.go"},"region":{"startLine":570}}}],"partialFingerprints":{"codehealthFindingId/v1":"66223c7e9831c007fb0486473803fb3103f178c07399214f4d29acf085b22e75"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 4): internal/admin/service.go:2579-2585 | internal/admin/service.go:2660-2666 | internal/admin/service.go:2722-2728 | internal/admin/service.go:2779-2785 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2579}}}],"partialFingerprints":{"codehealthFindingId/v1":"b908359594d547748b60debb6d08ea595accbf7dcef53c311233cd3e5c696157"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 4): internal/store/postgres/saved_dialog.go:42-48 | internal/store/postgres/saved_dialog.go:73-79 | internal/store/postgres/saved_dialog.go:111-117 | internal/store/postgres/saved_dialog.go:157-163 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/saved_dialog.go:42\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"0099bc9d16a958fe31fc81625e11847b9e8c0cd89c17563dadf6f3a123f610e9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): cmd/telesrv-admin/readstore.go:3199-3207 | internal/store/postgres/donations.go:246-254 | internal/store/postgres/donations.go:267-275 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Check import visibility before settling on that home: \u0060internal/store/postgres/donations.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":3199}}}],"partialFingerprints":{"codehealthFindingId/v1":"17d1718dd8eff36f5f81e27edcea8f3fa22828f9c38d82aef0d3c9047c86aab6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/admin/service.go:2680-2686 | internal/admin/service.go:2734-2740 | internal/admin/service.go:2788-2794 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2680}}}],"partialFingerprints":{"codehealthFindingId/v1":"eeb7c4fab0d94fb7cbf94f5a5d64b42a711eb08b6e97cf044527012abec06713"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/adminapi/botverification.go:357-363 | internal/adminapi/botverification.go:374-380 | internal/adminapi/botverification.go:393-399 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/adminapi/botverification.go:357\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/adminapi/botverification.go:354\u0060 calls \u0060FormatInt\u0060 and \u0060internal/adminapi/botverification.go:371\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":357}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec8994958bb773f47e30e2f042b45443be93517bb0331e78616d2b153288cfd7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/rpc/channel_fanout_dispatcher.go:1067-1073 | internal/rpc/channel_fanout_dispatcher.go:1177-1183 | internal/rpc/channel_fanout_dispatcher.go:1200-1206 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channel_fanout_dispatcher.go:1067\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060originUserID\u0060 in one and \u0060channelID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1067}}}],"partialFingerprints":{"codehealthFindingId/v1":"5239b178520bfaa7467dbb085936437100361072fd10d61eda51c7e6533e2be1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/rpc/channels_legacy_chat.go:305-311 | internal/rpc/messages_suggested_post.go:42-48 | internal/rpc/phone_group_call.go:200-206 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bf062934d42b77a3358529b0dc1297f7a2b814afb35f3c7abf0ab37197153e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/rpc/channels_legacy_chat.go:431-437 | internal/rpc/channels_members.go:232-238 | internal/rpc/channels_members.go:526-532 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"a81d6561a70bb841dbfae79cfe421212d3ef99f1953be184b14a52c1e6bbfc3c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/rpc/messages_saved_dialogs.go:71-77 | internal/rpc/messages_saved_dialogs.go:94-100 | internal/rpc/messages_saved_dialogs.go:137-143 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_saved_dialogs.go:71\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_saved_dialogs.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"152d663a9c0b992cd9ca16a89c871ab47a877721741e0b89f23724c53db10579"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/store/postgres/channel_message_edit.go:123-129 | internal/store/postgres/channel_message_edit.go:219-225 | internal/store/postgres/channel_message_edit.go:353-359 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_edit.go:123\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec2820e7ecc901d330ed4db53bbcbb9e1d16b9f9c7a06d03846dc5118a9bb5f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/telegramloginkeygen/main.go:379-385 | internal/app/telegramlogin/keyfiles.go:155-161 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telegramloginkeygen/main.go:379\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Check import visibility before settling on that home: \u0060internal/app/telegramlogin/keyfiles.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telegramloginkeygen/main.go"},"region":{"startLine":379}}}],"partialFingerprints":{"codehealthFindingId/v1":"626f55e8edca3fa8acf62297ff16094a9652f28c5f77d7c305fbb16ca366e7b8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): cmd/telesrv-admin/readstore.go:1323-1335 | cmd/telesrv-admin/readstore.go:1385-1397 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:1323\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1323}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bc7fc8d46b150a92052f90d2cd85dbf87618e9e8602c902cf16940c22cd09e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/telesrv-admin/server.go:506-512 | cmd/telesrv-admin/server.go:1011-1017 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":506}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3ce14bb60a95fdbd1e0312b3959b787a025454d06d3a84a135d61c1333aa7e2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/admin/botverification.go:356-362 | internal/admin/botverification.go:413-419 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"e42591c326d1871eb3d9cb54a82bae7b70cece40277517fa606873e26c3906ef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/admin/service.go:1954-1960 | internal/admin/service.go:2958-2964 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:1954\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1954}}}],"partialFingerprints":{"codehealthFindingId/v1":"23d051e8f48f578613847d9c4a30d86f19307949e9c4e5c411588dad2416e40a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/admin/service.go:2443-2449 | internal/admin/service.go:2548-2554 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:2443\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2443}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2cb6885653fc605c5b02711be6798056e0a36647440786ad974b555f4f1e6e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/account/business.go:192-199 | internal/app/account/business.go:211-218 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/business.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"76d905450e6cbc83765a164aacdb9ef8c6fa70f050f7539e185bd241a3e6f323"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/account/lifecycle.go:236-242 | internal/app/account/phone_change.go:87-93 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/account/lifecycle.go:236\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"a33ea6828908e4ff0a6348b7485c4d0955e2a5f29ab836e4a6e2ef3d8e1e812a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/bots/botfather.go:549-555 | internal/app/bots/botfather.go:569-575 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/botfather.go:549\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"10939cd768d5124d23bd69c638cd65281885a0a45db5401776abcc476d20e042"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/bots/verifierbot.go:1227-1233 | internal/app/bots/verifybot.go:995-1001 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/verifierbot.go:1227\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1227}}}],"partialFingerprints":{"codehealthFindingId/v1":"610faaaa3e90e82abb550e447c875916dfcd0551e4b803e756bd7d31bfa5cade"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/botverification/service.go:997-1003 | internal/app/botverification/service.go:1029-1035 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":997}}}],"partialFingerprints":{"codehealthFindingId/v1":"71ac6adcb54285e3913b404e2f9c5f58a9334ee13c93acd41e91bbf8c1007117"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/files/photos.go:469-475 | internal/app/files/photos.go:556-562 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/photos.go:469\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6ab3dfe2c9a1ef6a15cb144f03f838f2bc7e72680ecea1e3478722a3aeccd86"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/files/sticker_admin.go:142-148 | internal/app/files/sticker_admin.go:186-192 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_admin.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f8580044302a2255ed026f87d531412fd44289267bb11691dd37c079a441ae8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/files/sticker_management.go:248-254 | internal/app/files/sticker_management.go:262-268 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_management.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"836fe0507425b1bf875498cc3c8c7dd693b75ffef35812f5ca255c66e362a6e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/telegramlogin/jose.go:220-226 | internal/app/telegramlogin/jose.go:241-247 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/telegramlogin/jose.go:220\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/jose.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"a89b4993fd241e4bc4d1c7dd59016bbaaefa9c41326fe18574ffb5870d47f90d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/lottieraster/draw.go:327-333 | internal/lottieraster/draw.go:349-355 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/lottieraster/draw.go:327\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/lottieraster/draw.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"f58ffb0167931bcd3fa1ffc0e24a8a2e4c4e9b9abf4c80f1533ce669cdc943dc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/account.go:299-305 | internal/rpc/account.go:312-318 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/account.go:299\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/rpc/account.go:306\u0060 calls \u0060Info\u0060, \u0060wallpaperReferenceLogFields\u0060 and \u0060internal/rpc/account.go:319\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":299}}}],"partialFingerprints":{"codehealthFindingId/v1":"c021121bf48516911a50f1842b8fc0e4461750eb1236ef4483ce19769689235c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/aicompose.go:43-49 | internal/rpc/aicompose.go:161-167 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/aicompose.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bc3a77c79e1335804bbfbbb3277c216eddd73e54bfc71b0f418a41501c2989f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/channel_fanout_dispatcher.go:1097-1103 | internal/rpc/messages_suggested_post_updates.go:90-96 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channel_fanout_dispatcher.go:1097\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1097}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b2b64c2a04e9eb800151c6d4615678d593fa0c20b41a7aeebe49006e3c4ad32"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/channels_invites.go:131-139 | internal/rpc/channels_members.go:385-393 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_invites.go:131\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/channels_members.go:384\u0060 calls \u0060invalidateChannelFullBotInfoCacheForChannel\u0060 and \u0060internal/rpc/channels_invites.go:130\u0060 does not \u2014 after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8b2d0a41144782a634f0b8f3181394263c349c27c5fbf054baada657d7159dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/channels_members.go:558-566 | internal/rpc/communities.go:443-449 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_members.go:558\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":558}}}],"partialFingerprints":{"codehealthFindingId/v1":"e13eeea31958faa8edefa2ffd139ed5ab34c57fdf794e3c082bdc30104710deb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/channels_messages.go:388-394 | internal/rpc/channels_messages.go:423-429 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"980e50d5585315803d8640ea222448c91f4c84f91f2a82e4ccb53248f1d8627b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/channels_stubs.go:554-561 | internal/rpc/convert_business.go:256-263 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_stubs.go:554\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":554}}}],"partialFingerprints":{"codehealthFindingId/v1":"41827859888793578e8ad23700c3e3ac81c52be090a7cf285b4fe4dccd1c963a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/contacts.go:679-685 | internal/rpc/contacts.go:750-756 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":679}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3d35c6c1733824ce0a6b66554ceb778a6d5f8fbc5453717a2d06f3f83818985"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/contacts.go:729-735 | internal/rpc/contacts.go:775-781 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/rpc/contacts.go:775\u0060 is reached only past a guard at line 761 that tests \u0060target.ID\u0060 and leaves the function early, and \u0060internal/rpc/contacts.go:729\u0060 reads \u0060target.ID\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":729}}}],"partialFingerprints":{"codehealthFindingId/v1":"a919e19b8563f6808813039554faa3b20dc85283315c3bbb82b504f4c045ae06"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/messages_bot_no_state.go:341-347 | internal/rpc/messages_send.go:1241-1247 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_bot_no_state.go:341\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":341}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f78da5f35291340e781c95c4a7830af5cd379e44bd5c446b0d7641117ebdca8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/messages_edit_geolive.go:73-79 | internal/rpc/messages_todos.go:220-226 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_edit_geolive.go:73\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba06a05e5a1652d2c56362c662719ac70f77ad159362ccc71e319dc5f2ebceb4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/messages_polls.go:162-168 | internal/rpc/messages_reactions_lists.go:101-107 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_polls.go:162\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":162}}}],"partialFingerprints":{"codehealthFindingId/v1":"42efa65849f060eb32499b2ff2c969392a2f100aeec6cad210cb7a274d957a57"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/messages_read.go:107-113 | internal/rpc/messages_read.go:144-150 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_read.go:107\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd3bff28b34a0a152d24d6cac4ef7431c1a1a5a8f9da3245cbb9beb8e1a08775"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/payments_star_gift_lifecycle.go:52-58 | internal/rpc/payments_star_gift_lifecycle.go:126-132 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gift_lifecycle.go:52\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"6296c1c57aef7bc5e304969c8a451ce09a71215155008c7a8f174672c2378499"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/stats.go:58-64 | internal/rpc/stats.go:76-82 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stats.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"b00d8820c3d4cdc456f7bdda7c0d3c4ec099ab9bca4444c0be0ba503cbe22858"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/stories.go:2721-2727 | internal/rpc/stories.go:3116-3122 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":2721}}}],"partialFingerprints":{"codehealthFindingId/v1":"03613b91bcce9b0d346240af3529d8ac1a2dbe55fb77fbbfde63e8442b160beb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/bot_verification.go:500-506 | internal/store/memory/bot_verification.go:711-717 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":500}}}],"partialFingerprints":{"codehealthFindingId/v1":"33f44ac6b762a73840920f4e6ed3781ed21d8045587aeb4482af3a32eb0b46aa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_dialogs.go:164-170 | internal/store/postgres/channel_dialogs.go:1150-1156 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"c28a9136718a2a43de70424201ba85441310df7d0a59fe7bc3574a8063f3b66c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_invites.go:350-356 | internal/store/memory/channel_invites.go:640-646 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_invites.go:350\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"557a4575b49d29d8ec2f3f154b85783400eecf4ef7b61721330a6c6f5ac94554"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_members.go:348-356 | internal/store/postgres/channel_member_admin.go:96-102 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_members.go:348\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":348}}}],"partialFingerprints":{"codehealthFindingId/v1":"b089d9f99f7880af7a89d46c4bf8dcb1e508c3a29ce4fcbfb05f52511ff6a03d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (4\u20137 lines \u00D7 3): internal/store/memory/channel_message_delete.go:123-130 | internal/store/memory/channel_message_delete.go:168-174 | internal/store/memory/channel_topics.go:385-388 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_delete.go:123\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ee391a09de18b8ae529c3c7740935537c4346cd455405a1895376243faf890d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_message_views.go:80-86 | internal/store/memory/channel_topics.go:609-615 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_views.go:80\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_views.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"86e313baac832d6efa1eefd2113e7f289c314c4d2608a4e4372e3a5567539999"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_polls.go:14-20 | internal/store/memory/channel_polls.go:28-34 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_polls.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d4dd74096e550106f1a1df9ab3900df590b256f9c4882a674f9ec35addcb82f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_reactions.go:304-310 | internal/store/memory/channel_read.go:73-79 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_reactions.go:304\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"88fbb10fd48f7695452eef8421c8110c9422727b490b2586e23195b8f3703fbb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_reactions.go:358-364 | internal/store/memory/channel_reactions.go:827-833 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_reactions.go:358\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad5761d8c20f3b4e7fd6931402b985dba3a4fd9f0005b733796028ce05c6c4be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_reactions.go:546-552 | internal/store/memory/channel_read.go:149-155 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f30309e71d78fb49d2bdcadc340bab11b6f21432e4d7fbcf6983099af88377d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/channel_stats.go:242-249 | internal/store/postgres/channel_stats.go:413-420 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":242}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5500c2d42c660303e9836c2a718df7667ebddf1faf6cb13c9df9c954e238650"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/channel_stats.go:303-310 | internal/store/postgres/channel_stats.go:494-501 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_stats.go:303\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":303}}}],"partialFingerprints":{"codehealthFindingId/v1":"85b6f0f02829c5ed4533de96c9be7cf082edf30b8776b50b8becf4ab2f3a91e0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_topics.go:70-76 | internal/store/postgres/channel_topics.go:117-123 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"46dabb9a538265972f623a25575b43eaf72d760fdb88760cd482f6e81f23e628"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (2\u20137 lines \u00D7 3): internal/app/dialogs/list_snapshot_cache.go:296-297 | internal/store/memory/dialogs.go:979-985 | internal/store/postgres/dialog.go:1246-1252 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/dialogs.go:979\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/memory/dialogs.go:985\u0060 calls \u0060PutUint64\u0060 and \u0060internal/app/dialogs/list_snapshot_cache.go:297\u0060 does not \u2014 after which the two agree again for 5 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":296}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f1bd9e3e69acb6d965b9c4b83a2486bd0cc556b5bd9e9c7fa2e67577215ab1a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/groupcall.go:723-729 | internal/store/memory/groupcall.go:852-858 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/groupcall.go:723\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":723}}}],"partialFingerprints":{"codehealthFindingId/v1":"339b7adb8c1b58fce12a813141bd1a6dab9729824210c078df001a8585032471"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/message_polls.go:14-20 | internal/store/memory/message_polls.go:28-34 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_polls.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"786dff6ad2b7acd3e56d7bdf0361f2627168481f3a98320d327d9f1595b3ec70"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/saved_dialog.go:117-123 | internal/store/memory/saved_dialog.go:138-144 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4607825bc25d2d6b1fb0ee8050418df77e7f3b9aaca3ab05c5c478bdd3308f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/saved_dialog.go:220-226 | internal/store/postgres/saved_dialog.go:254-260 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"728240db7dd6c49b6781b9ee3c8bde81a386a39e9f93472ff64a634d76e99eed"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/story.go:384-390 | internal/store/memory/story.go:449-455 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/story.go:384\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"aef13d1f3e6d3ae0190731f0b38fcdf22e96705a2256c46272ca0464ec314715"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/verification.go:110-116 | internal/store/postgres/verification.go:136-142 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"d282001dca80b800d625e313c94e5c91fd30b067ef263b0e5c8a01e127cf52cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/bot_verification.go:202-208 | internal/store/postgres/bot_verification.go:224-230 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/bot_verification.go:202\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2aba5931d858077508e0290b8544dcb84885abb7ed830b42bbfa98dd9258855"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/channel_boosts.go:42-48 | internal/store/postgres/channel_boosts.go:194-200 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"5712bd5d271bd5350c6e8448ffa275558330c0d49225e8dec667547cd898b892"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/channel_member_admin.go:70-76 | internal/store/postgres/channel_member_admin.go:345-351 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_admin.go:70\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"86ead5fad725b9a04ecb49e55512ad0cc9d379a3bdec94e8482891e7cc0a8c5e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_message_helpers.go:56-64 | internal/store/postgres/channel_message_helpers.go:115-123 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_helpers.go:56\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_helpers.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"f811da99d5946e2ace868ae4968620955c0698e446d8b93953a5be432af9fe79"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_reaction_helpers.go:89-96 | internal/store/postgres/channel_read.go:479-486 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_reaction_helpers.go:89\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_helpers.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"38242c83556b5173db8e0d95123b86c37655f5132d9212a96bb1bd4e4a387d0c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/channel_stats.go:185-191 | internal/store/postgres/channel_stats.go:255-261 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_stats.go:185\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"344e220be8fe1ee7e479dbf5bab20dbe378c3306a4c9a1bbc7fbd9cf80df6285"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/channel_stats.go:223-229 | internal/store/postgres/channel_stats.go:398-404 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_stats.go:223\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"3298fd9d0ff8bf2049fde2aabd24f687cd437e892f720ac0a6a9f30410c186e6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/message_history.go:377-383 | internal/store/postgres/message_history.go:412-418 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_history.go:377\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"28f24a6dbda8bafca51a4a528f7f4a9af731808d26d34b9ae6be2dd41a1dd09f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/welcome_message_delivery.go:225-231 | internal/store/postgres/welcome_message_delivery.go:245-251 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message_delivery.go"},"region":{"startLine":225}}}],"partialFingerprints":{"codehealthFindingId/v1":"35ab635e6bd7b7f2db394466f8ef63307b449b3700d290c5d91be78b774f34f1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 7): internal/rpc/messages_send.go:1142-1147 | internal/rpc/messages_send.go:1178-1183 | internal/store/memory/groupcall.go:512-517 | internal/store/memory/message_delete.go:87-92 | internal/store/memory/message_read.go:61-66 | internal/store/postgres/message_delete.go:216-221 | internal/store/postgres/message_read.go:197-202 \u2014 there are 7 copies across 6 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 7 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_send.go:1142\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1142}}}],"partialFingerprints":{"codehealthFindingId/v1":"950c7fa21a6fa5944681e3ef19876abd396c01bca0c6f7733dff663c26ccc1c3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 5): internal/app/usernames/service.go:363-368 | internal/app/usernames/service.go:387-392 | internal/store/postgres/collectible_username.go:187-192 | internal/store/postgres/collectible_username.go:299-304 | internal/store/postgres/collectible_username.go:390-395 \u2014 there are 5 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/usernames/service.go"},"region":{"startLine":363}}}],"partialFingerprints":{"codehealthFindingId/v1":"a410ce6f19a85cc6e355a5f4d1b651c7a02ed1b6b28357acb36433bd5bc957a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 4): internal/adminapi/botverification.go:356-361 | internal/adminapi/botverification.go:373-378 | internal/adminapi/botverification.go:392-397 | internal/adminapi/botverification.go:422-427 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/adminapi/botverification.go:354\u0060 calls \u0060FormatInt\u0060 and \u0060internal/adminapi/botverification.go:371\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"93060b69feb7f1dfdce5de2705b0d80e2b3122fdd5425b955cebe5675700fe32"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/store/postgres/media_refs.go:234-241 | internal/store/postgres/media_refs.go:359-366 | internal/store/postgres/media_refs.go:404-411 | internal/store/postgres/media_refs.go:462-469 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/media_refs.go:242\u0060 calls \u0060DeleteDocumentRow\u0060, \u0060Errorf\u0060 and \u0060internal/store/postgres/media_refs.go:412\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_refs.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"609ab9d5820071ff983ad066d5156f0fb6823e28ca8913cc1f766fe8dbd8121a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 4): internal/store/postgres/moderation.go:29-34 | internal/store/postgres/moderation.go:123-128 | internal/store/postgres/moderation_registries.go:88-93 | internal/store/postgres/moderation_registries.go:213-218 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation.go:29\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"eae7290e07dc8ef58ce2038f4fb68e2b90e55ab198ad5cee1867a0912d2bb3b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/app/account/lifecycle.go:237-243 | internal/app/account/phone_change.go:88-94 | internal/app/account/phone_change.go:154-160 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/account/lifecycle.go:237\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"6872ef6af524049bc52dc9fcf9048d89838566e672f6a28da6713bd6964fa959"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/app/botverification/service.go:652-658 | internal/store/memory/bot_verification.go:244-250 | internal/store/postgres/bot_verification.go:287-293 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/bot_verification.go:285\u0060 calls \u0060Errorf\u0060 and \u0060internal/store/memory/bot_verification.go:243\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":652}}}],"partialFingerprints":{"codehealthFindingId/v1":"5fc39e2ba012c75309618fe06531612471a689f9ad75db1191d91a544924acdf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/app/usernames/service.go:416-421 | internal/store/memory/collectible_username.go:496-501 | internal/store/postgres/collectible_username.go:476-481 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/usernames/service.go"},"region":{"startLine":416}}}],"partialFingerprints":{"codehealthFindingId/v1":"aba2e559b1f6e0640a6dc32497646caddd306accaebe488390089de3f23f5b1d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/rpc/messages_sticker_sets.go:242-247 | internal/rpc/messages_sticker_sets.go:258-263 | internal/rpc/messages_stickers_personal.go:306-311 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_sticker_sets.go:242\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_sticker_sets.go"},"region":{"startLine":242}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc73e6d56614d2b37edcf70b5ed96022272be9c429804e72156863b20527cdfb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/store/memory/channel_invites.go:594-599 | internal/store/memory/poll.go:168-173 | internal/store/memory/poll.go:211-216 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_invites.go:594\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c2588d7ef6f259889c939784a33950f6690536487ae417b3756805c6c991e19"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/store/memory/channel_reactions.go:357-362 | internal/store/memory/channel_reactions.go:826-831 | internal/store/postgres/message_reactions.go:412-417 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":357}}}],"partialFingerprints":{"codehealthFindingId/v1":"adb483d69d02d0abf1064a7badcf3f925f6b00eb79d6588a9a62774f8b5d3acf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/store/memory/story.go:722-727 | internal/store/memory/story.go:780-785 | internal/store/memory/story.go:824-829 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/story.go:722\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":722}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e833a41a5dc188c5ff5679b17eaae4d0af61252d1ccba05975fff1b7b768798"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): cmd/telesrv-admin/adminusers_api.go:230-242 | cmd/telesrv-admin/adminusers_api.go:278-290 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/adminusers_api.go:230\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/adminusers_api.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac956e337a396746feab221c6311435b697ed1b2fc74bdfa50972958c06514d5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): cmd/telesrv-admin/server.go:719-724 | cmd/telesrv-admin/server.go:1193-1198 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":719}}}],"partialFingerprints":{"codehealthFindingId/v1":"e565d3a08412da08131801a2775ebac0c7f69cecaa43d0218eefa9b3fad6a507"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): cmd/telesrv-admin/star_gift_catalog.go:204-209 | internal/adminapi/server.go:1259-1264 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/star_gift_catalog.go:204\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Check import visibility before settling on that home: \u0060internal/adminapi/server.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/star_gift_catalog.go"},"region":{"startLine":204}}}],"partialFingerprints":{"codehealthFindingId/v1":"098aa9959b6af4c5a731ea19e73a725fc4abd230975ea9c4b2085e4d28595c8a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/admin/service.go:2212-2221 | internal/admin/service.go:2258-2267 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2212}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6212ac3be6bded1d446292da8a5670f30d99597bf5fd806e8a01f2cca619432"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/bots/stickersbot.go:291-296 | internal/app/bots/stickersbot.go:309-314 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":291}}}],"partialFingerprints":{"codehealthFindingId/v1":"c928524e92e737fd3de9e48312c540da80622c8ca47b4e5cce87f02295710191"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/channels/service.go:1972-1977 | internal/app/channels/service.go:1997-2002 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1972}}}],"partialFingerprints":{"codehealthFindingId/v1":"91fd65669947abd26b6a118a3c6b59ae421e840345baf64e9cea7f79a4734150"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/dialogs/read_model_cache.go:522-530 | internal/rpc/inline_registry.go:729-737 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/read_model_cache.go:522\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"3503630f1470a7e16be7ad3252262a998d5d56fbed0abe5b54d23d3a47357ece"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/dialogs/service.go:1394-1403 | internal/store/memory/message_helpers.go:170-179 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":1394}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b63ff2982c5477c139cadbd5b6aa743e42d3121dd62f778b3895fef7a0db896"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5\u20136 lines \u00D7 2): internal/app/dialogs/shared_list_snapshot.go:173-178 | internal/store/memory/story.go:590-594 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/shared_list_snapshot.go:173\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/shared_list_snapshot.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"129b98c9f62fdbc193f6a50b25a288efffda002f3c5733f31b743a7de66e0d84"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/files/diskspace_unix.go:10-15 | internal/hoststats/disk_unix.go:14-19 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/diskspace_unix.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"26b359041a640decf3a2c7507cfc67c4cf70c8cce55d3e5ecf9c8550ddecdec1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/stories/service.go:356-361 | internal/app/stories/service.go:370-375 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":356}}}],"partialFingerprints":{"codehealthFindingId/v1":"71071bff11da375a499f1492a7e7718f3320d6e22c4b6a115eede34a65f65c12"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/updates/service.go:777-782 | internal/store/postgres/update_event.go:76-81 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/updates/service.go:777\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/update_event.go:83\u0060 calls \u0060String\u0060 and \u0060internal/app/updates/service.go:784\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":777}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b90a4ba7d6a54db95ca9198f8a8e9bfa16e23afd34a1d46d63870e0d116ff15"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/botapi/inline.go:555-560 | internal/botapi/inline.go:727-732 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/botapi/inline.go:555\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/inline.go"},"region":{"startLine":555}}}],"partialFingerprints":{"codehealthFindingId/v1":"2eb0bed8203ef1cb6f7ce4d99d556108ba2842658e612ff22a57ba9b8502e674"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/mtprotoedge/inbound_layer_rpc.go:1112-1118 | internal/mtprotoedge/inbound_layer_rpc.go:1139-1145 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":1112}}}],"partialFingerprints":{"codehealthFindingId/v1":"61dec54f53855d71bad6351a189aa830af8083bcf087b735784da2284d515af1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/account.go:1826-1831 | internal/rpc/account.go:1837-1842 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":1826}}}],"partialFingerprints":{"codehealthFindingId/v1":"f00d0f27ec17e2e3f904b4ce578eb4490222985234118cb877c855d952bfc1cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/bot_verification_projection.go:146-151 | internal/rpc/fragment.go:340-345 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bot_verification_projection.go:146\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/bot_verification_projection.go:142\u0060 calls \u0060applyBotVerificationIconsFromMap\u0060 and \u0060internal/rpc/fragment.go:339\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b87d7da9d1f653c28a74e7a2a11ed83aff45a97549cc5757de92d8d6ab36db4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/channels_messages.go:332-337 | internal/rpc/messages_delete.go:66-71 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_messages.go:332\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"eda9804dd9c67ff44b267b06d19fd498097e7eec9d4e6f58e9e8e527a53f3667"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/channels_topics.go:39-44 | internal/rpc/folders.go:55-60 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_topics.go:39\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_topics.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba968b340e135c94f56afc1454d08fd6446c89b2557741738c5ba4a517f80b18"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/chatlists.go:366-371 | internal/rpc/messages_saved_dialogs.go:346-351 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/chatlists.go:366\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/chatlists.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a08df3e760ee4b4963674a658225f9f5aa2a6432a42b9dc14b04f3dd2eb53be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/convert_channels_core.go:42-47 | internal/rpc/convert_messages.go:409-414 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3edd8bd57da9a8f0bab9c4ea6b274c4b7a591e2e5fb68d1d1bb6f1bf879ee6d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/messages_forward.go:334-339 | internal/rpc/messages_quick_replies.go:219-224 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"15d5f08a4f6e6a0f96ddeb64a735df8f486510fef04107ec5c9f2695790b07c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/messages_getmessages_trace.go:147-154 | internal/rpc/messages_getmessages_trace.go:173-180 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_getmessages_trace.go:147\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_getmessages_trace.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d2b884d50c79cbd95213974206f26a61e9c73fd10cbb7a9a4e4e831a5c5a1f5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/messages_monoforum.go:89-94 | internal/rpc/messages_monoforum.go:121-126 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_monoforum.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffec8685bcf7671d5b7d98eb65aee4ecaaa9cbc253244ade247caa585c61790b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/payments_star_gifts.go:784-789 | internal/rpc/payments_star_gifts.go:927-932 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/payments_star_gifts.go:784\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":784}}}],"partialFingerprints":{"codehealthFindingId/v1":"70383713aa7e62d41e688af9abec6243fa6a5c2fa962f79c9a28021f61ee108c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/phone_group_call_updates.go:100-105 | internal/rpc/phone_group_call_updates.go:156-161 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/phone_group_call_updates.go:100\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_updates.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed3645725026cc55e858f81e0bdac5c7bc22de5ad5c31bac6c7dfd3f1a86b2ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6\u20137 lines \u00D7 2): internal/rpc/stories.go:1065-1071 | internal/store/memory/story.go:468-473 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":1065}}}],"partialFingerprints":{"codehealthFindingId/v1":"b672a40ff471f41f62cb653336e251caae522bbce0dfbec1ae78d2b22396b4d1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/story_projection_cache.go:215-220 | internal/store/memory/community.go:602-607 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/story_projection_cache.go:215\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_projection_cache.go"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e0b282307f41de2151345d3ac5f1d7069e4f5ec97dd02aa93b89b1e9a506552"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/channel_reactions.go:335-340 | internal/store/postgres/channel_reaction_messages.go:416-421 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"3de50006cd2631e9c2aff95f286fdca25f933450d8058a2196426ce5a8001b2c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/channel_reactions.go:514-519 | internal/store/memory/community.go:500-505 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_reactions.go:514\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":514}}}],"partialFingerprints":{"codehealthFindingId/v1":"c567611cc20d80dbd458068338e1a0bbde8c2db45c187a3b2a3166ad713c3165"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/dialogs.go:50-55 | internal/store/memory/dialogs.go:60-65 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fe4b96ce098d8b755200d8145cc5cba2b2498a2b219264aaf909ec4bc1edbfb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/message_pin.go:93-98 | internal/store/postgres/message_pin.go:176-181 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac1003b6b0e1f2a7745e5e85d77efea158704fe2a6e63dce626410673ae8fa2e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (24 lines \u00D7 2): internal/store/memory/message_reactions.go:244-267 | internal/store/postgres/message_reactions.go:435-458 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_reactions.go:244\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":244}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bec3e675c58a01ea2aa2569596188b8524ccb753bb38d39bc7ce0bd4f7a8d33"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/account.go:245-250 | internal/store/postgres/account.go:284-289 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/account.go:245\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":245}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd8337e79057fbdc88dfd85104a605f25784698cf9f6953961f68bd360e4462e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/account.go:443-448 | internal/store/postgres/account.go:487-492 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/account.go:443\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":443}}}],"partialFingerprints":{"codehealthFindingId/v1":"4710848abb9a76e4314b542dabbf22d60bf4d546ef359dc6c05ab7a1c77e77ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/active_channel_ids_batch.go:282-287 | internal/store/postgres/authkey_session_layer_batch.go:284-289 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"d80abfa08b1d2e4426c4885b17440eb4ed844ee13da6ec940162b8120131dbd9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/ai.go:183-188 | internal/store/postgres/ai.go:201-206 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/ai.go:183\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ai.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe8f51595db736449c84707d03df2c2557c09822a6ab86109ed6c93cf62d2c65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_dialogs.go:1552-1557 | internal/store/postgres/story.go:1509-1514 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1552}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebb8cf9141d704f1ea35b0cd974a988d570ed551385bf37f04fbb4ea3ddc1dbd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_message_helpers.go:46-53 | internal/store/postgres/channel_message_helpers.go:105-112 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_helpers.go:46\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_helpers.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c7a4b48eb29a42e6ca4de9688a099b1f3dc5a3fe08671a31473026294d36ada"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_message_history.go:199-204 | internal/store/postgres/channel_message_history.go:232-237 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_history.go:199\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":199}}}],"partialFingerprints":{"codehealthFindingId/v1":"d261105f085ee7fe19d49966c766ca9572532e3a7ef686ec0cb5081c3ff008b0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_message_views.go:126-131 | internal/store/postgres/channel_reaction_messages.go:372-377 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_views.go:126\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_views.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f6f8a6f6d97fb3cddde784e86fac593d7b20f61acfe5725a2494571fdda4548"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/counter_source.go:33-38 | internal/store/postgres/counter_source.go:122-127 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/counter_source.go:33\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/counter_source.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"e37c473c3ac5b19c410156b592b99661d60bc72f0a0d76f0457ef0d1b2ddc885"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/message_history.go:38-43 | internal/store/postgres/message_history.go:184-189 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_history.go:38\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"9462a5292b16fa55eec9f61105bc3eb5775935009e069c37830b9e1d5008cdf7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/message_send.go:347-352 | internal/store/postgres/message_send.go:443-448 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"a618d9198554286aece62050471de7e1540bd8da2741f571e5eff5796073601a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/moderation_cases.go:358-363 | internal/store/postgres/moderation_cases.go:540-545 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_cases.go:358\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"298e62c635a562cb54434f797b42a7b70762257bfb0ae01d65b99be9cdad5701"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/star_gift_lifecycle_projection.go:93-99 | internal/store/postgres/star_gift_upgrade.go:773-778 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_lifecycle_projection.go:93\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle_projection.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"53ced6ee88648c29b40319cce0107839bb056445cec6b125092fd1fb48e28000"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/web/server.go:384-389 | internal/web/server.go:663-668 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/web/server.go:384\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"aafb15bfbb7839b9cd05dde9989e44c7f53980eb209ed24359634fba1e8a819f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 10): internal/store/postgres/message_forward.go:154-161 | internal/store/postgres/message_history.go:698-705 | internal/store/postgres/message_history.go:770-777 | internal/store/postgres/message_history.go:842-849 | internal/store/postgres/message_history.go:914-921 | internal/store/postgres/message_history.go:986-993 | internal/store/postgres/message_send.go:1057-1064 | internal/store/postgres/saved_dialog.go:456-463 | internal/store/postgres/update_event.go:449-456 | internal/store/postgres/update_event.go:658-665 \u2014 before extracting anything, compare \u0060internal/store/postgres/message_forward.go\u0060 and \u0060internal/store/postgres/message_history.go\u0060 as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"13bc615e245a1ad855db90de543a04fbe7dd1ec4f370db31f9bd445794556327"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 5): internal/rpc/presence_last_seen_batch.go:205-209 | internal/store/memory/channel_read.go:333-337 | internal/store/postgres/channel_dialogs.go:716-720 | internal/store/postgres/channel_message_delete.go:171-175 | internal/store/postgres/user.go:534-538 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 5 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 5 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence_last_seen_batch.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4d9aedac89f17fd2c6aad9c6d6abea1ce4472d7dd099b61618926039a39cd16"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 5): internal/store/memory/channel_invites.go:596-600 | internal/store/memory/channel_invites.go:643-647 | internal/store/memory/poll.go:68-72 | internal/store/memory/poll.go:170-174 | internal/store/memory/poll.go:213-217 \u2014 there are 5 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 5 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_invites.go:596\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":596}}}],"partialFingerprints":{"codehealthFindingId/v1":"706392a6194c2b86a72d21683b1de7559673602a6398f6b0d3e41ed40c3c2025"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 4): internal/app/dialogs/shared_list_snapshot.go:172-176 | internal/rpc/story_projection_cache.go:217-221 | internal/store/memory/community.go:604-608 | internal/store/memory/story.go:589-593 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/dialogs/shared_list_snapshot.go:172\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/shared_list_snapshot.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"179a167bdfa0b2e8402c0c10cccbb5ab878076fa84cdae127877d78524f93a0d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 4): internal/domain/message_entity_autodetect.go:72-76 | internal/domain/message_entity_autodetect.go:98-102 | internal/domain/message_entity_autodetect.go:133-137 | internal/domain/message_entity_autodetect.go:168-172 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/domain/message_entity_autodetect.go:72\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_entity_autodetect.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"99646fcdebcfa55024b3c95b75aad0332b0d196e8d8154ff68fd335a0b6dd13a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 4): internal/store/memory/channel_boosts.go:233-237 | internal/store/memory/channel_reactions.go:356-360 | internal/store/memory/channel_reactions.go:825-829 | internal/store/postgres/message_reactions.go:411-415 \u2014 there are 4 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_boosts.go:233\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"49a4c6e18fa6eeca673bb3ec2507d6c6350946c387c285a23541ec3fd83f353c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): cmd/telesrv-admin/server.go:2043-2047 | cmd/telesrv-admin/server.go:2089-2093 | cmd/telesrv-admin/star_gift_catalog.go:101-105 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:2043\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2043}}}],"partialFingerprints":{"codehealthFindingId/v1":"299e84e7ab689b0abd2109935f4ee6af556c1f538b9c46bfdce90e45853e628c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/admin/botverification.go:626-630 | internal/admin/botverification.go:666-670 | internal/admin/botverification.go:710-714 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/botverification.go:626\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":626}}}],"partialFingerprints":{"codehealthFindingId/v1":"1443e260f3f062acbe2416181abaf9a6ffbd397da46ce3fad99bd01a9053ade2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/app/updates/service.go:778-782 | internal/store/postgres/update_event.go:77-81 | internal/store/postgres/update_event.go:139-143 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/updates/service.go:778\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/update_event.go:83\u0060 calls \u0060String\u0060 and \u0060internal/app/updates/service.go:784\u0060 does not \u2014 after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":778}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5b2555b9b2136b2331fe673a0a1e0cbd5f669e8930874a08b02b173c776bbc0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/rpc/messages_dialogs.go:635-639 | internal/rpc/messages_dialogs.go:696-700 | internal/rpc/messages_dialogs.go:743-747 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_dialogs.go:635\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":635}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d637da6ed34675ab51c7b1c37ab3225801a58be79067216a09a1dbe68e2063a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/rpc/messages_quick_replies.go:223-227 | internal/store/memory/message_forward.go:92-96 | internal/store/postgres/message_forward.go:111-115 \u2014 \u0060internal/store/memory/message_forward.go\u0060 and \u0060internal/store/postgres/message_forward.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 3 separate duplicated blocks between them, totalling at least 51 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_quick_replies.go:223\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_quick_replies.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fbf1007cbb62659ff590cc1daa64b6cce84b84165d511136f42ff0fcdb7c557"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/store/memory/groupcall.go:723-727 | internal/store/memory/message_delete.go:87-91 | internal/store/postgres/message_delete.go:247-251 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":723}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc9be7606e0818cf83500db018abb2ca8e599e27c5ed29b4ce81d45de699e2ab"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/store/memory/message_read.go:61-65 | internal/store/postgres/channel_dialogs.go:716-720 | internal/store/postgres/channel_message_delete.go:171-175 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_read.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"78e158521390e4b6dd442a2a7fd3520675041f3f04ffa457231742af1b29c51a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/store/storetest/groupcall.go:259-263 | internal/store/storetest/groupcall.go:288-292 | internal/store/storetest/groupcall.go:548-552 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/storetest/groupcall.go"},"region":{"startLine":259}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3482f0c455dff750a734297da2ec7f561dc3f73b824df8dbd23458c0d6dbf72"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): cmd/telesrv-admin/server.go:2166-2170 | internal/adminapi/server.go:924-928 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:2166\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Check import visibility before settling on that home: \u0060internal/adminapi/server.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2166}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a2d459b378ee93ee45c3d33303ff8b913cacb19b3889fe57910d16a92a8a9be"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/walletminiapp/main.go:366-372 | internal/rpc/messages_webview.go:729-735 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/walletminiapp/main.go:366\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. Check import visibility before settling on that home: \u0060internal/rpc/messages_webview.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"966013826f51269ae8f2ebc28d5e34a54aa7333ba253a4dd78829b68457fa98d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/app/ai/service.go:460-464 | internal/app/ai/service.go:524-529 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/ai/service.go:460\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"05a78521288c6f17379a872872711eebc92d0991c5082a748867f3761d060940"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/app/auth/service.go:1326-1330 | internal/app/auth/service.go:1343-1347 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/auth/service.go:1326\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/app/auth/service.go:1331\u0060 calls \u0060invalidateLoginCodeDetached\u0060 and \u0060internal/app/auth/service.go:1348\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1326}}}],"partialFingerprints":{"codehealthFindingId/v1":"3604f4802158c56010a752c51e70b84f0570cc44514e0096cbdc6d33644d1255"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/dialogs/read_model_cache.go:489-494 | internal/store/postgres/channel_top_message_cache.go:192-197 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/postgres/channel_top_message_cache.go:189\u0060 calls \u0060Peer\u0060 and \u0060internal/app/dialogs/read_model_cache.go:486\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"d291b33703a9333e14dec6f47759e3b5f82561857c7f040624a3118b4b99419a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/app/files/appearance_seed.go:186-190 | internal/app/files/seed.go:437-441 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/appearance_seed.go:186\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"60319a24f644986e64db160b986cb1e55d0fa44067d4caf022e2e717ab03a729"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/loadharness/run.go:462-475 | internal/loadharness/run.go:501-514 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/loadharness/run.go:462\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":462}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fb3d358d20a0185d934caedcfa2dd46c815a9c83831060558309243f0598053"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/mtprotoedge/encrypted.go:791-796 | internal/mtprotoedge/layer_rpc_execution.go:267-272 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":791}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa2d3d4d2a4a2ff5d16c08afc84a0d2a7f228f0142401b2122b7007ef552a28d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/mtprotoedge/encrypted.go:849-854 | internal/mtprotoedge/layer_rpc_execution.go:304-308 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/encrypted.go:849\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":849}}}],"partialFingerprints":{"codehealthFindingId/v1":"da97160bde587de8c6dd3b3e091c3fa5b37fdf1ad29cf4d156e9d2fd8baade84"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/bots_inline.go:773-777 | internal/rpc/send_media.go:770-774 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bots_inline.go:773\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":773}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d8877be1ac9aabf23decad0cc5517353defe4ae087ff94458a405e84d42efb3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/channels_members.go:921-925 | internal/store/memory/groupcall.go:723-727 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d3161cd5fb3003eb529608f41ee9701d49f7c86c621d4ef8e33e13f4876ac80"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/messages_dialogs.go:743-747 | internal/rpc/messages_saved_dialogs.go:221-225 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_dialogs.go:743\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":743}}}],"partialFingerprints":{"codehealthFindingId/v1":"582ba4efbec7c7225e609da78af4f909546f6a4d00d567ccf43b1fab46363a6b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/messages_getmessages_trace.go:159-163 | internal/rpc/messages_getmessages_trace.go:194-198 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_getmessages_trace.go:159\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_getmessages_trace.go"},"region":{"startLine":159}}}],"partialFingerprints":{"codehealthFindingId/v1":"4023903406bd4d60f0163cf2149b834e177272e0ec511691ab5b5fb2da686d3d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/messages_send.go:316-320 | internal/rpc/phone_conference.go:445-449 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_send.go:316\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":316}}}],"partialFingerprints":{"codehealthFindingId/v1":"62fb4c26da8bc619f5f9a7f1f9fa827914265fa2fe1fdc8b9824822304f92fd6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/messages_webview.go:424-428 | internal/rpc/messages_webview.go:522-526 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_webview.go:424\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1b92a55bd80187c70178951e21ccbf499aba877601381753b18d97aa28a9194"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/messages_webview.go:431-435 | internal/rpc/messages_webview.go:529-533 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_webview.go:431\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8526c001e75367897291c5d85f52571edd9430db6d3bff0c7d9058af36534dc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (3\u20135 lines \u00D7 3): internal/rpc/phone_group_call_edit.go:117-121 | internal/rpc/phone_group_call_edit.go:205-209 | internal/rpc/phone_group_call_presentation.go:139-141 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/phone_group_call_edit.go:117\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names \u2014 the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/phone_group_call_edit.go:115\u0060 calls \u0060tgEmptyUpdates\u0060, \u0060Now\u0060, \u0060Unix\u0060 and \u0060internal/rpc/phone_group_call_edit.go:204\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_edit.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"9965d3a5f24afd1e42fb7371311a4f3e914695b79873e52606d2f3d4c34836ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/presence_last_seen_batch.go:205-209 | internal/store/postgres/message_delete.go:247-251 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence_last_seen_batch.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"17e31710e1116164c990875219d66831855c809f2b8b076bef5402fc6ec532ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/bot.go:782-787 | internal/store/memory/bot.go:810-815 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":782}}}],"partialFingerprints":{"codehealthFindingId/v1":"af524dfe9b7f9974d42f475a55328a896f7ea2c872182ea06f9cd916c7ec969b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/memory/channel_topics.go:582-586 | internal/store/postgres/channel_message_views.go:192-196 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_topics.go:582\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":582}}}],"partialFingerprints":{"codehealthFindingId/v1":"30207ba30ba832a13828bef25be55d2ae8f6e5850e3b31ca5f21af71cef1445d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/contacts.go:95-101 | internal/store/postgres/contact.go:221-227 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"67d9498da83813c428197213aa197b60d14acbb8ae4435788882db371c21fb31"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/langpack.go:211-218 | internal/store/postgres/langpack.go:386-393 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffd3a3262fd4cc690769b760dc93ca08d661f93a2d2764b0ad32b5956251240d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/message_reactions.go:133-138 | internal/store/postgres/message_reactions.go:343-348 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3c0ee074d95642e36838b1f3869606b7f02aa2fbcf67bced75b1d20f697b7bc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/telegram_login.go:537-543 | internal/store/memory/telegram_login.go:574-580 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b68c7e2ce4d0bb7f38843c7db6f01a913cc7feab4ad96082cd90b8f50ef5952"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/telegram_login.go:541-546 | internal/store/postgres/telegram_login.go:886-891 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":541}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0149f2aa15970507875b3cfd67ebd5b5e4d66b8861a5efd2088b9c53e18ab79"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/telegram_login.go:578-583 | internal/store/postgres/telegram_login.go:956-961 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ecd3f80088d0d9e56a8c0ed2abe1cafcca034504f76348dd69996f17d42bb10"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_message_history.go:288-293 | internal/store/postgres/channel_message_history.go:544-549 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":288}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fe9399e97f4059eb31785f2918570eb4796d9c7353215d061230264a9915ea5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_message_send.go:534-539 | internal/store/postgres/channel_suggested_post.go:252-257 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":534}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3b9301dc68333354a053a7a4107848a69483aca151e19a8d44cbb1216d124e2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/channel_suggested_post.go:151-155 | internal/store/postgres/channel_suggested_post.go:174-178 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"123c84163b56e4310756d6f9bfd9c485428fffe0844afd623032c97bc4f16d9b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/message_send.go:1055-1059 | internal/store/postgres/saved_dialog.go:454-458 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_send.go:1055\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":1055}}}],"partialFingerprints":{"codehealthFindingId/v1":"55b5526f95286dec144844f0f8a18eed9b8bbb0d3f73fd453ece834b3700959f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/telegram_login.go:215-219 | internal/store/postgres/telegram_login.go:354-358 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/telegram_login.go:215\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":215}}}],"partialFingerprints":{"codehealthFindingId/v1":"e37d9d8db20bf28ddf3ffdd82dfa9bb5c9bc3f463e2b7d833f01a28c123b58fa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (35 lines \u00D7 2): internal/mtprotoedge/bulk_rpc_scheduler.go:83-117 | internal/mtprotoedge/outbound.go:1101-1135 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/bulk_rpc_scheduler.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a61dc0d322532f9af9a2570c329598f8443452fbf79d917c107085e6b0fb08b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (18 lines \u00D7 2): internal/store/memory/channel_reactions.go:871-888 | internal/store/postgres/channel_reaction_helpers.go:250-267 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":871}}}],"partialFingerprints":{"codehealthFindingId/v1":"353d93d54ed4721e57ca72d3ad330aef6796aeb4d6c34ec94859ec371ab8ff17"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 4): cmd/otpwebhook-example/main.go:393-397 | cmd/walletminiapp/main.go:597-601 | internal/botapi/server.go:1428-1432 | internal/telegramloginhttp/handler.go:811-815 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 4 times. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060any\u0060 to \u0060body\u0060 in one and \u0060value\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. Check import visibility before settling on that home: \u0060internal/botapi/server.go\u0060, \u0060internal/telegramloginhttp/handler.go\u0060 sit under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/otpwebhook-example/main.go"},"region":{"startLine":393}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fa619ccc2d8ebc31904368f5377cd37e2562c7e57735f169880629706053f80"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/telesrv-admin/admin_command_runner.go:271-277 | internal/admin/service.go:4015-4021 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Check import visibility before settling on that home: \u0060internal/admin/service.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/admin_command_runner.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"eab3dd45d4f58cc8b9f5b061eaa618674b180ced6daa66e383ee5c66abdb7d28"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): cmd/telesrv-admin/botverification.go:522-529 | cmd/telesrv-admin/verification.go:223-230 \u2014 before extracting anything, compare \u0060cmd/telesrv-admin/botverification.go\u0060 and \u0060cmd/telesrv-admin/verification.go\u0060 as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 81 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":522}}}],"partialFingerprints":{"codehealthFindingId/v1":"8840384049f7649a1325c4acdd87186da36e2bdda38bd7f38fcadd354883ce51"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): cmd/telesrv-admin/botverification.go:548-555 | internal/adminapi/botverification.go:479-486 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Check import visibility before settling on that home: \u0060internal/adminapi/botverification.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":548}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa5acb997dde11935c8a9b20548875a7f1f04e8ed410b434ae6aa9f039dd4fca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): cmd/telesrv-admin/server.go:1000-1008 | internal/app/contacts/service.go:339-347 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Check import visibility before settling on that home: \u0060internal/app/contacts/service.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1000}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1b2769f16f9d6f934ccd8f74d0f508c07c2fe557cdcf0a22b8a779da6d09315"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/telesrv-admin/session.go:98-104 | internal/store/memory/channel_invites.go:996-1002 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Check import visibility before settling on that home: \u0060internal/store/memory/channel_invites.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/session.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e11d59b57c3b97f4897ac72ef789b3bf4e6e6271c5118bb6e337794c2f6a803"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/account/service.go:862-868 | internal/app/auth/service.go:814-820 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":862}}}],"partialFingerprints":{"codehealthFindingId/v1":"68464b7b3ecf4eded1f844ce99ed84e8cb3b2099afe0093c5738bf31df6f699c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/ai/service.go:80-88 | internal/app/translation/service.go:54-62 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"386638d35406ecbc19f36d66e69568718c5047974adda5262c0a763e83af76b6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/ai/service.go:118-126 | internal/app/translation/service.go:74-82 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":118}}}],"partialFingerprints":{"codehealthFindingId/v1":"620f39ff21229f94097171db0ccbf90fb38b1277f1d8c79e5c3ecb6693ccd5a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/ai/service.go:758-768 | internal/rpc/stories.go:1496-1506 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":758}}}],"partialFingerprints":{"codehealthFindingId/v1":"44fd9a1ef45c9029d871a696ce2741122825c6a1a0f45e122ab688258f9fff9d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/bots/stickersbot.go:629-638 | internal/rpc/messages_sticker_sets.go:189-198 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":629}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd2d4dd3a5e00c23ca29cf1661bb18f79e0068bbdb9cd83ab0984d03c1c52791"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/bots/stickersbot.go:738-747 | internal/store/memory/bot.go:770-779 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":738}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8db69120bd5debc3c889572c8f040fafbedb43336de1e3f988ea368d2e64035"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/bots/verifierbot.go:1423-1429 | internal/app/bots/verifybot.go:1235-1241 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1423}}}],"partialFingerprints":{"codehealthFindingId/v1":"244ecd55442d0ed88d47cc4466af08e557d2bc0fc0412abb03757edf4c53e580"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/app/bots/verifierbot.go:1524-1537 | internal/app/bots/verifybot.go:1314-1327 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1524}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6b4039fcd0e689caeabf6e71ab63b285aaefba1feffa499d9510de33d9e2c5c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/app/bots/verifierbot.go:1578-1584 | internal/app/bots/verifybot.go:1407-1413 | internal/app/verification/service.go:1416-1422 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1578}}}],"partialFingerprints":{"codehealthFindingId/v1":"e45a386e09892614966968ee2d2df4e018f79ce0a8e937029bc60f2fcda79ba5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/botverification/service.go:219-228 | internal/app/verification/service.go:200-209 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"08f7a2c43aa424d749b1d86116bfb34ee2d185ef0b254cf1a726975487452666"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/app/botverification/service.go:1493-1497 | internal/app/verification/service.go:1400-1404 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1493}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ffa2df4586de51d953b83647b04ba1688ae2790922fc6f6e41459c83cda5106"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/app/channels/media_count_cache.go:125-134 | internal/app/messages/private_media_count_cache.go:154-163 | internal/rpc/media_count.go:48-57 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/media_count_cache.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba5cacdc7acc7c92b0b723c85bbe80f6584eabbc569f322d7189a4f73eed94cd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/channels/service.go:1492-1497 | internal/app/messages/service.go:201-206 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1492}}}],"partialFingerprints":{"codehealthFindingId/v1":"08d7641001ad093d51066e540dc1b3fe4816eaa191dea8c5cdc6b1899519a6f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/contacts/read_model_cache.go:131-139 | internal/app/dialogs/read_model_cache.go:548-556 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/read_model_cache.go"},"region":{"startLine":131}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a1732efb1a3899ee0d93750c7a1b25079d08083a134456081bd487395373c20"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/contacts/service.go:84-93 | internal/app/dialogs/service.go:115-124 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb7efabbe217b896e5a3ded8fbc2928a804830271589ab82c14df90fe80030e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/contacts/service.go:95-105 | internal/app/dialogs/service.go:126-136 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/service.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"d54c8528b6e091e3921f9708d6c8cf239cc02b36a3e5175b93517a53199da2b1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/files/sticker_creator.go:255-261 | internal/rpc/stickers.go:536-542 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e34f2e945919900b8acd9aa002c003ef9aea326ae2338ad3d5c6fc985fa9b1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/langpack/service.go:153-160 | internal/rpc/langpack.go:148-155 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/service.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"38362717a417a8c9c9274b5f91aae5082c2c6da7f2c4b81cab66b64caa06dfff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/app/stories/service.go:443-453 | internal/store/memory/story.go:1050-1060 | internal/store/postgres/story.go:2259-2269 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":443}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b498c323111217a31a40552d39ce6aef4efbefb08bd23f58ac6846b91eb6d1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/telegramlogin/service.go:812-822 | internal/telegramloginhttp/handler.go:731-741 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060string\u0060 to \u0060raw\u0060 in one and \u0060key\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":812}}}],"partialFingerprints":{"codehealthFindingId/v1":"56e1942ae733439161baf89f2279e9e3316e6ab1a4475fdc5218ebea4ee1ee86"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/app/verification/service.go:1345-1354 | internal/store/memory/verification.go:892-901 | internal/store/postgres/verification.go:1265-1274 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":1345}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c90db528f67592cc43ba9ca67b4ea88efbbc0d69fb704d42dbaf3af2df9c582"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/config/config.go:2291-2301 | internal/domain/emailphone.go:177-187 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":2291}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d08ec7c2255968427b827cf555661e434dc4b19f31e827213b17645e0d927e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/mtprotoedge/outbound.go:3065-3071 | internal/mtprotoedge/transport_compat.go:918-924 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":3065}}}],"partialFingerprints":{"codehealthFindingId/v1":"dccb4d369f3e32ec6e4701d689cb38928ce431aa534827e60effe30136862345"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/rpc/aicompose.go:237-246 | internal/rpc/encrypted_chats.go:42-51 | internal/rpc/phone_calls.go:41-50 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/aicompose.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"d31a697bd3d74ccc58ddd1acdd64d72b3b05f370a58ea6d86ce0c183098b8fb8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 5): internal/rpc/channel_fanout_dispatcher.go:1109-1120 | internal/rpc/login_token.go:214-225 | internal/store/memory/channel_helpers.go:721-732 | internal/store/memory/channel_message_send.go:329-340 | internal/store/postgres/channel_message_send.go:376-387 \u2014 \u0060internal/store/memory/channel_message_send.go\u0060 and \u0060internal/store/postgres/channel_message_send.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 4 separate duplicated blocks between them, totalling at least 43 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_fanout_dispatcher.go"},"region":{"startLine":1109}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a443f4abb617191d3e7cb88f63be530396ce61d07dc500725d4881fccebf753"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/rpc/channels_messages.go:45-53 | internal/store/memory/channel_read.go:541-549 | internal/store/postgres/channel_read.go:997-1005 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"c317948b15cc3be39d3f9fc0ba42cdc082fc0f16ee9f7758c3ca8a7b6852926a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/channels_settings.go:226-231 | internal/rpc/channels_stubs.go:80-85 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"010c73bbd5c3777ba6b1f810c44358e20701956195c6f8306b8692ea402d709c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/channels_updates.go:479-487 | internal/rpc/privacy_invites.go:51-59 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_updates.go"},"region":{"startLine":479}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c30337982e31cca9634b30f058dce1078ddcdd9b6aeca4d1cd4f15162ec4f8e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/rpc/convert_channels_core.go:712-724 | internal/rpc/convert_users.go:192-204 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":712}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b465d4d6b84a1930218542847d6a33fe100721a948f0be6bf596456a30f9a38"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/convert_communities.go:9-18 | internal/rpc/convert_media.go:240-249 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_communities.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a7e07715381780f2be8d5e3db651efb629645b9bef5323732151d86120fbf3b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/ephemeral.go:371-382 | internal/rpc/messages_bot_no_state.go:299-313 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":371}}}],"partialFingerprints":{"codehealthFindingId/v1":"03fab1ef0b4fa9422b1e32c681367d2c97c861b6f43aafd8afe6e48c3b8d0d93"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/expiry_dispatcher.go:33-38 | internal/rpc/scheduled_dispatcher.go:44-49 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/expiry_dispatcher.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf9555c15abfeed711657bdc1d9123b1934f26ff5ce570caa96bc887f2dbd0b8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 3): internal/rpc/groupcall_sweep_dispatcher.go:41-55 | internal/rpc/phone_expiry_dispatcher.go:31-45 | internal/rpc/suggested_post_dispatcher.go:37-51 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/groupcall_sweep_dispatcher.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b371f2418847153dfeb634185ff959662b31d0933987f84534624c488993242"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/rpc/peer_projection_cache.go:280-291 | internal/rpc/update_peer_refs.go:570-581 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/peer_projection_cache.go"},"region":{"startLine":280}}}],"partialFingerprints":{"codehealthFindingId/v1":"74282a2e49a21d5d4d1072760d3c93c8ab7cb485129322cedc8177fe96256ca5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/rpc/premium.go:315-323 | internal/store/postgres/channel_member_helpers.go:537-545 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/premium.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4d9239afa41e79af85b5bee944e7d106ccfa93546f8c490e31f7ce97e8c4398"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/rpc/stories.go:3376-3387 | internal/store/memory/story.go:1541-1552 | internal/store/postgres/story.go:2384-2395 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3376}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbac3d11ee50ecccc49445100e5ebfbc1c2bf4544d253f78c1f56ecc9dbcb3a4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/story_pinned_cache.go:34-39 | internal/rpc/story_projection_cache.go:124-129 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060c *storyPinnedAvailableCache) Delete(viewerUserID\u0060 in one and \u0060c *storyProjectionCache) Delete(viewerUserID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_pinned_cache.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1e2dde2c2f1fd29c23a33ea9377053fc01faebffd2e3197413dce17e17badb8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/story_pinned_cache.go:41-46 | internal/rpc/story_projection_cache.go:131-136 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060c *storyPinnedAvailableCache) DeleteViewer(viewerUserID\u0060 in one and \u0060c *storyProjectionCache) DeleteViewer(viewerUserID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_pinned_cache.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1504cabaafb80540b377a8d440edc0e4a20e492b56c5adf95b1496bbcd23e54"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/story_pinned_cache.go:48-53 | internal/rpc/story_projection_cache.go:138-143 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_pinned_cache.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a7206cade6d5ce69b85a1f9ab28b11dedc646b8459161ad641cf195b732c403"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): internal/store/contact_reverse_batch.go:171-183 | internal/store/postgres/active_channel_ids_batch.go:147-159 | internal/store/read_model_batch.go:173-185 \u2014 before extracting anything, compare \u0060internal/store/contact_reverse_batch.go\u0060 and \u0060internal/store/read_model_batch.go\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"29beef96897d6973b0cd561d230bf70a9ac66eeb475fdf20ad58ef5b531cb1a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/bot_verification.go:932-939 | internal/store/memory/verification.go:845-852 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":932}}}],"partialFingerprints":{"codehealthFindingId/v1":"3171a2f90d1352aff122beec9255e97c5e875d84b7c5f53734bba2a51ed31b46"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_helpers.go:464-472 | internal/store/postgres/channel_helpers.go:515-523 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":464}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ffba5fff794a9f1010129690d76b7395f7fef2daee2a459350bc54064de462e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/channel_invites.go:983-989 | internal/store/postgres/channel_invite_members.go:144-150 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":983}}}],"partialFingerprints":{"codehealthFindingId/v1":"31d506fc091ddc7f73199da5fbc7cf2b3b42d42afcc4600da342fa50af753e09"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/memory/channel_members.go:1173-1180 | internal/store/postgres/channel_member_helpers.go:509-516 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1173}}}],"partialFingerprints":{"codehealthFindingId/v1":"c78032d77499d1889fe196aa3f2d107ad9c8fc0dfa6c452cf42abf7082287503"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 3): internal/store/memory/channel_message_helpers.go:16-26 | internal/store/memory/message_helpers.go:243-253 | internal/store/postgres/message_helpers.go:347-357 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_helpers.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc97f5f6de25beb1a40f89a00ad9e2cdcab9b8d07180819e5ad2a32fe2733439"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_settings.go:843-852 | internal/store/postgres/channel_settings.go:1301-1310 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":843}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9bd7f087554019da0cebde818cf18ec8913c6c792770df9d2710c6d3c9c6f10"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/channel_stats.go:323-332 | internal/store/postgres/channel_stats.go:514-523 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cae52890a651779ad62ee0be84ed765a86ca3c9a6f4958e30b62b57156ac740"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/channel_topics.go:632-640 | internal/store/postgres/channel_topics.go:1050-1058 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":632}}}],"partialFingerprints":{"codehealthFindingId/v1":"b263f3bd980a8c151db996c405a4207bb41b0a2d90e9131d9dee836652ede1e6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/channel_updates.go:342-352 | internal/store/postgres/channel_updates.go:516-526 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":342}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d9b7ca54a83c3e1551b9232a24278e39d23ff9eefc918e5d5268701c7e9a88f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/story.go:1040-1048 | internal/store/postgres/story.go:2249-2257 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1040}}}],"partialFingerprints":{"codehealthFindingId/v1":"de28461b137c8cc6cb3772e7a1feb727abbcb843a72edf57004ca7d689acdb30"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/memory/verification.go:856-866 | internal/store/postgres/verification.go:1162-1172 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":856}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9c6410a603d883e3a1eac396d3d8c585a43ca6f85d7040acb18644ed4852abd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/verification.go:903-909 | internal/store/postgres/verification.go:1276-1282 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":903}}}],"partialFingerprints":{"codehealthFindingId/v1":"9bf5db8a8240ebdd84a0a351628039c2651d80d3e91b5c49d954ff49e0e6c941"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/memory/verification.go:999-1008 | internal/store/postgres/verification.go:1333-1342 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":999}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f0b4a4e10c812048737c3d87d71e2008d1d4c1dbf97b8931946e5f3a7fcbe31"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/active_channel_ids_batch.go:256-268 | internal/store/postgres/bootstrap_update_job_batch.go:282-294 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060error\u0060 to \u0060b *ActiveChannelIDsPageBatcher) failQueued(err\u0060 in one and \u0060s *BatchedBootstrapUpdateJobStore) failQueued(err\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c116fa4b57b64995d47b85f9e189c0280ff3df09340100191124858d4e419ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/authkey_session_layer_batch.go:157-166 | internal/store/postgres/bootstrap_update_job_batch.go:168-177 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_session_layer_batch.go"},"region":{"startLine":157}}}],"partialFingerprints":{"codehealthFindingId/v1":"45231a7d7101017f90c95ba250a66a9db69a3384b624b3b30db6bee418d174b3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_listener.go:98-107 | internal/store/postgres/postgres_connection_admission.go:457-466 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_listener.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"23a10861338a7cd1e49a37a66beb107f9b759703d324162d1e08650727c1f73a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/admin/service.go:4204-4210 | internal/rpc/users.go:804-810 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":4204}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c2edb1688af54ea6a178a74fa308cfa248765983277705b048f21951f407917"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/adminapi/botverification.go:217-224 | internal/adminapi/verification.go:109-116 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":217}}}],"partialFingerprints":{"codehealthFindingId/v1":"75c43292e7a584ef95af8d634d9a83b152871b7bfe28a64e98ec005cff8e8d34"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/bots/verifierbot.go:1375-1383 | internal/app/bots/verifybot.go:1106-1114 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1375}}}],"partialFingerprints":{"codehealthFindingId/v1":"681a3b4d387a6623b11038df15a0e5d5854ff8735d669e41f895c84f9bc5e33f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/app/bots/verifierbot.go:1385-1395 | internal/app/bots/verifybot.go:1116-1126 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1385}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdbc360ff79faa299426ca877ce5c355ac6fcffbcd96a4e1677a9d684f2a78eb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/botverification/service.go:901-910 | internal/app/verification/service.go:636-645 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":901}}}],"partialFingerprints":{"codehealthFindingId/v1":"200d9b6b2fa01254bb8f642b4a60e1c7d64aab71e1427ccb3e75e82427db14a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 4): internal/app/channels/media_count_cache.go:28-39 | internal/app/channels/participants_cache.go:36-47 | internal/app/channels/read_model_cache.go:32-43 | internal/app/channels/resolve_cache.go:31-42 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/media_count_cache.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca7acdcd9cd900dc2472cc287d38799c3b6d5381e322c654354d39c8b0339ed6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/channels/media_count_cache.go:48-55 | internal/app/dialogs/list_snapshot_cache.go:120-125 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060c *mediaCountReadModelCache) invalidateChannel(channelID\u0060 in one and \u0060c *dialogListSnapshotCache) invalidateOwner(userID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/media_count_cache.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8b35d5766e1a760b10c60fa2831a406f715dc54595140ac766fe63387535131"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 7): internal/app/contacts/read_model_cache.go:115-121 | internal/app/dialogs/read_model_cache.go:418-424 | internal/app/dialogs/read_model_cache.go:442-448 | internal/app/dialogs/read_model_cache.go:465-471 | internal/app/dialogs/read_model_cache.go:540-546 | internal/app/dialogs/read_model_cache.go:558-564 | internal/app/userprojection/contact_cache.go:1154-1160 \u2014 there are 7 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 7 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/read_model_cache.go"},"region":{"startLine":115}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa89d7390a8e3bb32e02c0ce5fd12efe127d5e91788867fe98429e149ff292ff"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/contacts/read_model_cache.go:123-129 | internal/app/userprojection/contact_cache.go:1162-1168 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/read_model_cache.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0de7d2ab75a402a022089fd8a9b7594fd30dac08d2d6b53126cf7b1ad7298c9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/files/blobcache.go:107-116 | internal/store/postgres/media.go:508-517 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/blobcache.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"43e4401a1991409664e324c9fffc298bf67bb249484ac739aa44da1e9b46326b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/files/default_statuses.go:141-148 | internal/rpc/convert_media.go:762-769 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/default_statuses.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc2e1aad2f5aacfd78978ab7400d2859e731df70682f32c703c9e332a0bb20c0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/app/files/diskusage_worker.go:63-75 | internal/app/files/upload_gc.go:41-53 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/diskusage_worker.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c86207d9df505aee2a99969500172e7cf638ec205b66df959aac6d617891df8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/moderation/appeal_links.go:55-60 | internal/app/moderation/cases.go:19-24 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/appeal_links.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f117a0b90ffef9da67c04e48bea54e01997bec3f535241006d2072ea1ca2413"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/peerview/cache.go:138-145 | internal/rpc/peer_projection_cache.go:252-259 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/peerview/cache.go"},"region":{"startLine":138}}}],"partialFingerprints":{"codehealthFindingId/v1":"377c66f58d5510cabebc2b784f24e67d66d30275689e30870a0f31e37c5349a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/app/stargifts/service.go:1023-1027 | internal/store/postgres/star_gift.go:546-550 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":1023}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b9e3f0bc482c4c1d983d60b53aabf3778039240b4b245a2c61a78b658f25efe"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/app/stories/service.go:476-485 | internal/store/memory/story.go:1076-1085 | internal/store/postgres/story.go:2292-2301 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":476}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd0fb9b9bedec857b914c28aef4bed7ead439e2d5dbc991db987fc9fcc76516a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/domain/boost.go:282-291 | internal/domain/channel_errors.go:67-76 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/boost.go"},"region":{"startLine":282}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c4e5c97843072801d6ae3bcb1e3361767723252a16990046a5419525972b7a1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/channel_full_bot_cache.go:51-56 | internal/rpc/rpc_projection_cache.go:146-151 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_full_bot_cache.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0a796b9363eb8adcd45625449751e5ea6faaa473c7770e8953c914bc6f53321"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/rpc/channel_full_bot_cache.go:59-64 | internal/rpc/rpc_projection_cache.go:43-48 | internal/rpc/rpc_projection_cache.go:154-159 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060channelID\u0060 in one and \u0060targetUserID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_full_bot_cache.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"879303a58dde668455894af96a21b4a5abfdf4b5ae1578fe635213a18fb2f482"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 6): internal/rpc/channel_full_bot_cache.go:66-71 | internal/rpc/rpc_projection_cache.go:50-55 | internal/rpc/rpc_projection_cache.go:57-62 | internal/rpc/rpc_projection_cache.go:102-107 | internal/rpc/rpc_projection_cache.go:161-166 | internal/rpc/rpc_projection_cache.go:168-173 \u2014 there are 6 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060c *channelFullBotInfoCache) DeleteChannel(channelID\u0060 in one and \u0060c *userFullProjectionCache) DeleteViewer(viewerUserID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_full_bot_cache.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"3dff6a745e9720a6a7fb40f96fcfcf121447e5ccc4912d7c235e19a1e8045147"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/channel_full_bot_cache.go:143-150 | internal/store/memory/verification.go:921-928 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_full_bot_cache.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"64f743490f84a6bde85983f4857e7b6ae3a43977e1f3d020db79d3161ee74be3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 6): internal/rpc/channels_members.go:79-83 | internal/rpc/channels_members.go:85-89 | internal/rpc/channels_members.go:91-95 | internal/rpc/channels_settings.go:60-64 | internal/rpc/channels_settings.go:66-70 | internal/rpc/channels_settings.go:241-245 \u2014 there are 6 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9d9c2d40dbba2ad2cb576050b49a300cb94118bbcba3b2722d8847e69b95b7b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/messages_games.go:9-14 | internal/rpc/messages_reports.go:389-394 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_games.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"d24e35557b164db78275487b406186aa8d1a7e22e1919c515a082e54b6f2e2dd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/messages_reports.go:370-376 | internal/store/postgres/telegram_login.go:399-405 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reports.go"},"region":{"startLine":370}}}],"partialFingerprints":{"codehealthFindingId/v1":"023226f9350b8c20a5d7533f7c5048441e951c9d2e019ad90f683c4caa69ad02"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 3): internal/store/contact_reverse_batch.go:286-298 | internal/store/postgres/authkey_session_layer_batch.go:265-277 | internal/store/read_model_batch.go:287-299 \u2014 before extracting anything, compare \u0060internal/store/contact_reverse_batch.go\u0060 and \u0060internal/store/read_model_batch.go\u0060 as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 67 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together \u2014 extracting one helper per block leaves the fork in place. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060error\u0060 to \u0060s *BatchedReverseContactStore) failQueued(err\u0060 in one and \u0060s *BatchedAuthKeySessionLayerStore) failQueued(err\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":286}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9c6e3a9f2a3bfd2331b2549febedbbe4106ea9ca5753feff0e0476ee2016fc2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/store/memory/auth.go:381-386 | internal/store/memory/password.go:156-161 | internal/store/memory/users.go:43-48 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth.go"},"region":{"startLine":381}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4b79a611229daedbe852fa77c5755cb0fae28df0b114a20acbdf21e95d515f3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/auth_delivery_report.go:56-64 | internal/store/memory/ephemeral_report.go:45-53 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth_delivery_report.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"05c8698e704d4bdf7142d10cf95a3e2b1bbd2b379ec5347dc049c4f36951302c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/bot_callback.go:139-150 | internal/store/memory/ttlcache.go:113-124 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_callback.go"},"region":{"startLine":139}}}],"partialFingerprints":{"codehealthFindingId/v1":"790f07ddd113f4642432d95143acf34a3b4a5ce6cbcc80e2e25633c8b484ed78"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/business.go:524-532 | internal/store/postgres/business.go:843-851 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/business.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"7313b84b34ff46ee79ea37cd3fa8016ae907ccbc9eff2a71003d675a8d8d1590"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/memory/contacts.go:500-506 | internal/store/memory/message_helpers.go:280-286 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":500}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d544ff282673369880db627105fe9a6f1e70459b11d24f2a565c735f4923810"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/story.go:1030-1038 | internal/store/postgres/story.go:2239-2247 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1030}}}],"partialFingerprints":{"codehealthFindingId/v1":"52c0599339c6a6938beccd32334a6dfb77cb6a09ed26d5b2a79921fbf6bcb7a5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/memory/story.go:1554-1562 | internal/store/postgres/story.go:2397-2405 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1554}}}],"partialFingerprints":{"codehealthFindingId/v1":"e85a56d3b5319e521db6e54b49298e2b1c7568de8b47fe0b2a5b2c8dcd0ff0c2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/active_channel_ids_batch.go:270-275 | internal/store/postgres/bootstrap_update_job_batch.go:296-301 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"dee5f3126d126de4197ca5d526cbdf1afa65d114a5d83b954940add6abdeb3a7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/store/postgres/authorization.go:565-574 | internal/store/postgres/bot_miniapp.go:540-549 | internal/store/postgres/bot_miniapp.go:569-578 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authorization.go"},"region":{"startLine":565}}}],"partialFingerprints":{"codehealthFindingId/v1":"ace6688645f9c131f71154cbf42106e9b6c5ca4bb9cfa279b9d433fce89380dc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_dialog_cache.go:125-130 | internal/store/postgres/channel_member_cache.go:80-85 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060channelID\u0060 in one and \u0060userID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialog_cache.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5e7e2fb5026255457d5db69922c0f6212960aee496eb709687dbc44d07c71ca"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_listener.go:32-37 | internal/store/postgres/read_model_listener.go:196-201 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_listener.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ad61502d3e2976f2f47664af107d45f5004dccf04b84aff95c7305d9b1d4e85"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/channel_message_helpers.go:170-176 | internal/store/postgres/message_helpers.go:219-225 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_helpers.go"},"region":{"startLine":170}}}],"partialFingerprints":{"codehealthFindingId/v1":"49a2f5fa59286549fb923c16e68a87fb5762127058c2520ec1e71febb490c078"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (35 lines \u00D7 2): internal/store/postgres/contact.go:64-98 | internal/store/postgres/contact.go:116-150 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/contact.go:64\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2a8a5456948a970d453d2d34b66e052b19fc5b9d646c9539d688c006abe6075"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (26 lines \u00D7 2): internal/store/postgres/channel_dialogs.go:1517-1542 | internal/store/postgres/dialog.go:774-803 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_dialogs.go:1517\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1517}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1ef34d7d0457158c13c75c5bf42ae677bc5e78fc4f94525baa12732681b244d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (20 lines \u00D7 2): internal/store/postgres/contact.go:278-297 | internal/store/postgres/contact.go:372-393 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/contact.go:278\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4828701e8bc28dd212d8ee4003824d4283b07db1a744df815812f28f236a8d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/postgres/botapi_update.go:169-182 | internal/store/postgres/botapi_update.go:252-269 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/botapi_update.go:169\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ee8e1e1b7bd50d68e966f7f2ebb2da1b9d5fb057bdf60374a37ac406a57d46e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): cmd/telesrv-admin/server.go:2390-2404 | cmd/telesrv-admin/server.go:2435-2445 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:2390\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2390}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd5a2eef3790ecfe97d2b70402c5ed6506810a3a37620305c854258b92c41a74"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): internal/store/postgres/moderation_cases.go:1081-1094 | internal/store/postgres/moderation_cases.go:1121-1135 | internal/store/postgres/moderation_cases.go:1146-1160 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_cases.go:1081\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1081}}}],"partialFingerprints":{"codehealthFindingId/v1":"52fe18edd6b229424b2f7cc46bf4efd0a2e58a70f95e2c7a1d1719a673d4fc28"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/adminapi/account_rating.go:33-47 | internal/adminapi/botverification.go:75-89 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/account_rating.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4e3d1db405f9541ff2eb268199ec35410625dff339db27f47b840ec52b2b8e7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/authkey_get_batch.go:265-278 | internal/store/postgres/authkey_get_batch.go:285-297 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/authkey_get_batch.go:265\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_get_batch.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ccd4dc896ce4b9d7331610db263c9838fc8f18e6f38adc0f84432923ad1c945"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/scheduled_message.go:597-610 | internal/store/postgres/scheduled_message.go:617-627 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/scheduled_message.go:597\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":597}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c72417344d87f89687c11cc34aae3d0c34540bde6676eca7b23170c4bb839e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 2): internal/store/postgres/channel_listener.go:50-63 | internal/store/postgres/read_model_listener.go:213-226 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_listener.go:50\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_listener.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd5d54b3ab58fdce31622c6d9ff70d268f2e0ff3a9d7d913a07db23fc8cf558c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/channel_stats.go:172-182 | internal/store/postgres/channel_stats.go:196-208 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_stats.go:172\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"c311631b94b908617ef406520ff53ebff0b8085bc4d67b024330df8d2be2e548"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): cmd/telesrv-admin/privateview_store.go:518-530 | cmd/telesrv-admin/privateview_store.go:548-560 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/privateview_store.go:518\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":518}}}],"partialFingerprints":{"codehealthFindingId/v1":"be755f224f5091a30a0566a7fbfccddce7d662698b515d3ac8b1fd326a3d4c0d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/channel_message_send.go:277-289 | internal/store/postgres/channel_monoforum.go:181-193 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_send.go:277\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":277}}}],"partialFingerprints":{"codehealthFindingId/v1":"77804229102b7d51041b2d3bc14c93d09936465bb2f703fc2d0c65b61cad6218"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_stats.go:91-99 | internal/store/postgres/channel_stats.go:103-114 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_stats.go:91\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d789d3843f296e8c93475deab0d55b3cdce757a699e1a29a2aac707d7127acf"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 8): internal/store/postgres/message_delete.go:41-52 | internal/store/postgres/message_edit.go:33-44 | internal/store/postgres/message_history.go:317-328 | internal/store/postgres/message_history.go:512-523 | internal/store/postgres/message_pin.go:40-51 | internal/store/postgres/message_pin.go:186-197 | internal/store/postgres/message_read.go:44-55 | internal/store/postgres/saved_dialog.go:265-276 \u2014 there are 8 copies across 6 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 8 sites; resolving a subset leaves the remainder to drift apart. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"84c982e2d7d977a9eda7512cc525653e87a0e258c6e3dddf8d0811c9ca6fa311"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/memory/login_code_delivery.go:71-82 | internal/store/postgres/login_code_delivery.go:100-111 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code_delivery.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"2724d94655ccb439343ae262ce25d0edf63280f83b3943bdcb55c68999f94751"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 2): internal/store/postgres/authkey.go:57-68 | internal/store/postgres/authkey.go:82-92 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/authkey.go:57\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"9aaf52433c53d28b36de36becad1ee12230f196012ea52bb3aea27aed779f53f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/botapi/server.go:868-879 | internal/botapi/server.go:1217-1228 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/botapi/server.go:868\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":868}}}],"partialFingerprints":{"codehealthFindingId/v1":"b438bb84a44c2970d73a69762a41f71c9e5f72f212ce4251148947ed7a1504a0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 3): internal/store/memory/login_code_delivery.go:69-80 | internal/store/postgres/login_code_delivery.go:98-109 | internal/store/postgres/login_code_delivery.go:269-280 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/login_code_delivery.go:69\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code_delivery.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"68e6e978d59c5b9259c554b403a6b5ffcb45a46f6bc36672de745a27b073bda7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/collectible_username.go:777-787 | internal/store/postgres/collectible_username.go:794-800 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/collectible_username.go:777\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":777}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb1f7014bb933a6734a23dfacb3ecdefe0120d10e61bfdae0341c93d2d76e444"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (11 lines \u00D7 4): internal/store/postgres/channel_settings.go:610-620 | internal/store/postgres/channel_settings.go:747-757 | internal/store/postgres/channel_settings.go:832-842 | internal/store/postgres/channel_topics.go:68-78 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_settings.go:610\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":610}}}],"partialFingerprints":{"codehealthFindingId/v1":"558a0dee87bb46d635d13e8b6625d2af2ed83b15a192531a42a62a253c65d5d2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/verification.go:1115-1124 | internal/store/postgres/verification.go:1146-1156 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/verification.go:1115\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":1115}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6fd4b89f6d4c0d20624cc30ad73a262a479a903ec37df4649c1311d03a90057"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_core.go:103-112 | internal/store/postgres/channel_member_join.go:22-31 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"26fc602145c8d65aa936395fde0803f0bf2fc801d07bcfd153fafcea7c80ebcb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/adminapi/server.go:1062-1071 | internal/adminapi/server.go:1127-1136 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/adminapi/server.go:1062\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1062}}}],"partialFingerprints":{"codehealthFindingId/v1":"a24b5e5ede1557e9bc919f3b62dc6f268f79cd633032e0e0bfc880cef5172453"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 3): internal/store/postgres/user.go:266-275 | internal/store/postgres/user.go:572-581 | internal/store/postgres/user.go:666-675 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"f525e021501b684365b5ef63c8bed3745a11e52df0b09a871942ca8bb1b75e1b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 4): internal/store/postgres/channel_invite_import.go:71-80 | internal/store/postgres/channel_invite_members.go:18-27 | internal/store/postgres/channel_member_join.go:167-176 | internal/store/postgres/channel_member_join_requests.go:134-143 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"912eb79c3c61d8ef9c958e34ce66d5ea54a63198295490d097e70e2a36275a27"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_message_send.go:68-77 | internal/store/postgres/channel_monoforum.go:50-59 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"da655d42ee1d4320dd51eb70a8a9cd2423de0d7071e1197a8216a73458bce341"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/message_saved_reactions.go:254-263 | internal/store/postgres/scheduled_message.go:353-362 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_saved_reactions.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"d480365ae9d01b638e97043d66b64d61ad6f1789a89ffe6d941266c6a4a9f0c6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_settings.go:224-233 | internal/store/postgres/channel_settings.go:415-424 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":224}}}],"partialFingerprints":{"codehealthFindingId/v1":"73db7a1090e690a161d4a5afe0bcf4e0ca1f815d078d8f5e02880bb94a456fa8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/verification.go:315-324 | internal/store/postgres/verification.go:377-386 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/verification.go:315\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"51f74ab996b5f1351ed66e618c19397397d37bc1a009d1e3a9bb0efd30cd7a35"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/scheduled_message.go:56-65 | internal/store/postgres/scheduled_message.go:152-161 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ccde354f1c35d7f4805f1355f1589208f66335b1702f68441205212e4c0feef"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/username_notify.go:48-57 | internal/rpc/verification_notify.go:100-109 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/username_notify.go:48\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/username_notify.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f7ef6cd1d4f00260d525626e8814d8033975700fe3d9781facbcc9767e2ad73"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): cmd/telesrv-load/main.go:145-154 | cmd/telesrv-load/main.go:220-229 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-load/main.go:145\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-load/main.go"},"region":{"startLine":145}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fc5061e70cd6afc5e32fc69dea256c0174939a6f8f6a42f7cff48e2157a18fc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/message_pin.go:125-134 | internal/store/postgres/message_pin.go:273-282 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_pin.go:125\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad8b68e8cb3bc461f05a7ebcdd64bcd22c80a8738cd7cbe8abf1ea3ede9402a2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/messages_bot_longtail.go:254-263 | internal/rpc/messages_bot_longtail.go:272-281 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"408318b58451f564003fc866402bee393021b4a4bfd52e72e7e1afc716624bc4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_reaction_messages.go:31-40 | internal/store/postgres/channel_reaction_messages.go:194-203 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"e30c98d517f2eaad1acaded8fd0176fb359f79e9094ffd544814c89e1069de49"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/groupcall.go:1053-1062 | internal/store/postgres/groupcall.go:1239-1248 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/groupcall.go:1053\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":1053}}}],"partialFingerprints":{"codehealthFindingId/v1":"2159ae63d8e3b639320e1773d4d273dd918585388321d54f30137a96ca660ebc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/authkey.go:440-449 | internal/store/postgres/dispatch_outbox.go:314-323 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/authkey.go:440\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey.go"},"region":{"startLine":440}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c553d941d10cc23e886844a47632481ca505b2f249b336fa79eaff9ecfcb6aa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/app/files/retention.go:236-245 | internal/app/files/retention.go:256-265 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/retention.go:236\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a3add93c0b19af9f0faaa20902dfdc8d58b0eebeb2de22df44886f2c2436e8b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/store/postgres/channel_message_delete.go:27-36 | internal/store/postgres/channel_message_delete.go:75-84 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4502be111180dff116f17259de7dbe2b524b12cf93a9cd056b473308b7fafae"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/store/postgres/moderation_cases.go:184-198 | internal/store/postgres/moderation_cases.go:304-318 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_cases.go:184\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"a38e2cbea414495ca0896b228ce70a971e507fbaeeb737ab8c1d600437c163e2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_message_edit.go:419-427 | internal/store/postgres/channel_message_edit.go:515-523 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_edit.go:419\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fedebea39cdfe7dab6a66d4ba98a23a7f1c76479ae786ba639b5a920ce97235"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_member_admin.go:12-20 | internal/store/postgres/channel_member_admin.go:307-315 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_admin.go:12\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9e282af1b7277d0f3cbea48db9785793e3dffdfed0e5da40684d92c0926707b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/postgres/channel_message_delete.go:198-206 | internal/store/postgres/channel_message_delete.go:371-379 | internal/store/postgres/channel_topics.go:388-396 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_delete.go:198\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"299c5abda650c9e290cf6c102b025297e123867160560d66907ddf2faf2dcb4b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/moderation.go:66-74 | internal/store/postgres/moderation.go:145-153 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation.go:66\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dc3b945bec6770aa2f1e9dadaf0f5a0136707c01f8ed8717abe8d90392075cd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/mtprotoedge/conn_layer_profile.go:384-392 | internal/mtprotoedge/conn_layer_profile.go:456-461 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/conn_layer_profile.go:384\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn_layer_profile.go"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3fbde58efd618216b0b8615906a388339fd4a21defe76824baf339c0543f92a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/postgres/channel_helpers.go:716-724 | internal/store/postgres/channel_helpers.go:744-752 | internal/store/postgres/channel_helpers.go:789-797 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_helpers.go:716\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":716}}}],"partialFingerprints":{"codehealthFindingId/v1":"68d21d078cefb24238bbdd8a1f64a75f984dd1953367ed4d95440a8c087aeaa4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/community.go:1094-1102 | internal/store/postgres/community.go:1116-1124 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/community.go:1094\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1094}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc5299ee2a844b03cc7717b463f2d6053e406a68c3cb78f5df613aa6b4cb9cfd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/app/files/retention.go:372-380 | internal/app/files/retention.go:394-402 | internal/app/files/retention.go:416-424 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/retention.go:372\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"56ac7ad4f403c51e4f6c555bbc2b3672ba69137a232ec0b036aa76cb331eedda"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/story.go:1493-1501 | internal/store/postgres/user.go:762-770 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1493}}}],"partialFingerprints":{"codehealthFindingId/v1":"61146fa76acf38b2899a89c579c7632cff25b3c2c34dbec0b6a7e04262cd75e5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): cmd/telesrv-admin/readstore.go:1227-1235 | cmd/telesrv-admin/readstore.go:3254-3262 | internal/store/postgres/broadcast.go:373-381 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:1227\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Check import visibility before settling on that home: \u0060internal/store/postgres/broadcast.go\u0060 sits under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1227}}}],"partialFingerprints":{"codehealthFindingId/v1":"746de20bd1daf6f55ae506bc76706f6f82b1beb6d4acd709400fa3a7d41a0953"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/store/postgres/verification.go:1080-1087 | internal/store/postgres/verification.go:1097-1105 | internal/store/postgres/verification.go:1131-1139 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/verification.go:1080\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":1080}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ccc19742245685e7f08ea714861bfcf85fed324077aebee48462d6d8bc42b62"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_monoforum.go:54-61 | internal/store/postgres/channel_suggested_post.go:44-52 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_monoforum.go:54\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_monoforum.go"},"region":{"startLine":54}}}],"partialFingerprints":{"codehealthFindingId/v1":"65e9d16456828f29a590ffb47ff7ca1beb361350e2b6ce2ec258542be21409f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/themes.go:185-193 | internal/store/postgres/themes.go:207-215 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/themes.go:185\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/themes.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b410650b97a428c8366beaff2aaeb921dba8ef365f9936426a7b319eb9f0fdc"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_dialogs.go:1281-1289 | internal/store/postgres/channel_membership_batch.go:24-32 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_dialogs.go:1281\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060userID\u0060 in one and \u0060channelID\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1281}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b0cdccb20cb27ea8b62767450472eebd6c36112bf27fc134c26bc77f47eed04"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/star_gift.go:397-405 | internal/store/postgres/star_gift.go:417-425 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift.go:397\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":397}}}],"partialFingerprints":{"codehealthFindingId/v1":"ada60d73c9a88a40356c10ed6deb5504e0754a6f0ed91cce0ffa511802d18a4c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/verification.go:290-298 | internal/store/postgres/verification.go:354-362 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/verification.go:290\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":290}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b19d1d10286ff46beefef3125df014db9568e5ef61de86719979ecaab920bea"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/rpc/bot_verification_notify.go:65-73 | internal/rpc/username_notify.go:33-41 | internal/rpc/verification_notify.go:72-80 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bot_verification_notify.go:65\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_notify.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"e025b8f3b25aa8dbcc615974d2d95169e9e38189f7c772fc931e6e6b51b62d33"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/chatlist.go:209-217 | internal/store/postgres/chatlist.go:224-232 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/chatlist.go:209\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/chatlist.go"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"951b56fa95c47f1e8d8c14d9cbc506a7fb8884ba16f169bb8deeb25eb695ae1c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_read.go:888-896 | internal/store/postgres/star_gift.go:52-59 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_read.go:888\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":888}}}],"partialFingerprints":{"codehealthFindingId/v1":"d809113e8322f72ed8efce6c2da7bfe000858aed5f75c434a627deb3b83834de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/postgres/verification.go:222-230 | internal/store/postgres/verification.go:290-298 | internal/store/postgres/verification.go:354-362 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/verification.go:222\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":222}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f2b66e9fe19e904d00d68bcbd1f3dae485c887f27dfd1ce6b67d239e45fc6cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/mtprotoedge/session_manager.go:765-772 | internal/mtprotoedge/session_manager.go:794-802 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/mtprotoedge/session_manager.go:765\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":765}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7d1cc7c4d7cbb721b94e0b8e0473537f1637c857c448e8d56ef773e7d74fb31"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/rpc/bot_verification_notify.go:91-99 | internal/rpc/username_notify.go:49-57 | internal/rpc/verification_notify.go:101-109 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/bot_verification_notify.go:91\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_notify.go"},"region":{"startLine":91}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8fd61b51cfbb6be1658e64c97464606b641c77a1632c2651eb0de0ecdfeff21"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 4): cmd/telesrv-admin/account_rating.go:109-117 | cmd/telesrv-admin/botverification.go:205-213 | cmd/telesrv-admin/server.go:2728-2736 | cmd/telesrv-admin/verification.go:86-94 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/account_rating.go:109\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/account_rating.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1255b3d37bcc9fcfa4e540d463ab879d75e297d76e4830c249d3378af2a8973"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 3): internal/store/postgres/user.go:61-69 | internal/store/postgres/user.go:116-124 | internal/store/postgres/user.go:786-794 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/user.go:61\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b681e265b829e277d5302f4814196086162845181022bb0eac0d89eafc384ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/app/files/retention.go:148-156 | internal/app/files/retention.go:164-172 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/retention.go:148\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6185acd62d527b0f318b548ed537c338b26b36c0c1533d080309205719c5b3e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/verification.go:748-756 | internal/store/postgres/verification.go:783-790 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/verification.go:748\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":748}}}],"partialFingerprints":{"codehealthFindingId/v1":"229f7acb49461ca5d9ced34f48c987a98dcde1a2e0db6a676be1601307c4243b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (9 lines \u00D7 2): internal/store/postgres/channel_message_settings.go:85-93 | internal/store/postgres/channel_reaction_settings.go:22-30 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_settings.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4f69be62127a952b23bb1b4d6b218c2d4f5bbc2bb8de3cd0a5ec9a0df09fd73"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 13): internal/store/postgres/channel_invite_members.go:22-29 | internal/store/postgres/channel_member_join.go:171-178 | internal/store/postgres/channel_polls.go:52-59 | internal/store/postgres/channel_settings.go:585-592 | internal/store/postgres/channel_settings.go:638-645 | internal/store/postgres/channel_settings.go:722-729 | internal/store/postgres/channel_settings.go:771-778 | internal/store/postgres/channel_settings.go:807-814 | internal/store/postgres/channel_settings.go:856-863 | internal/store/postgres/channel_settings.go:905-912 | internal/store/postgres/channel_settings.go:941-948 | internal/store/postgres/channel_settings.go:989-996 | internal/store/postgres/channel_topics.go:26-33 \u2014 there are 13 copies across 5 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 13 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_invite_members.go:22\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_members.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"00dfae34a8298da77abbe796d8c2351752ece71a9a82f4a6c7411bdc398f87cb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/bot_verification.go:1033-1040 | internal/store/postgres/bot_verification.go:1067-1074 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/bot_verification.go:1033\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":1033}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c6b6eb7f2f1f58af41d1a297446c913707cfba93463804ac83d5e6b3f05d845"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/store/postgres/authkey.go:436-443 | internal/store/postgres/collectible_username.go:688-695 | internal/store/postgres/dispatch_outbox.go:310-317 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/authkey.go:436\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey.go"},"region":{"startLine":436}}}],"partialFingerprints":{"codehealthFindingId/v1":"dca57b88b231c60e51df819f5ad35c6e24aa4e89037c5369d0510c5e5570c038"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/media_search.go:266-273 | internal/store/postgres/media_search.go:351-358 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/media_search.go:266\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_search.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"59d48d29ba1777f2664d41abd0913dacbff297db7570410c490ce6c20ff570a1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_message_edit.go:228-235 | internal/store/postgres/channel_message_edit.go:362-369 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_edit.go:228\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":228}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c4d90c0f3f8cf75110ccc62357fbd85aa138e4ab627a1739ecdf3f788507116"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (14 lines \u00D7 3): internal/store/postgres/media_search.go:266-279 | internal/store/postgres/media_search.go:351-364 | internal/store/postgres/media_search.go:375-388 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/media_search.go:266\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_search.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"b566ca90ba97863db04656da2df72687a8bb2fa3ad920309175ad072d6116e91"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/files/retention.go:213-220 | internal/app/files/retention.go:391-398 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"5defe36fd2268b6c4635d6d038cc4181d90ee7834e9055202efbc95bd0127118"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/rpc/botapi_gateway.go:945-952 | internal/rpc/botapi_gateway.go:975-982 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/botapi_gateway.go:945\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":945}}}],"partialFingerprints":{"codehealthFindingId/v1":"b46359a7936c35fc6c66066deb0abca2529500899cd2c5d422653ab357d29bf8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_reaction_unread.go:50-57 | internal/store/postgres/channel_read.go:314-321 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_reaction_unread.go:50\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"1855974529fc6cfe49ba255b2b92137382ffc70e89f41cf3ee5ad3b274c2e1c7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/bot_verification.go:669-676 | internal/store/postgres/bot_verification.go:1199-1206 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/bot_verification.go:669\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":669}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e29ee36610e5bfb793fb939c7fcfae3a7ac2f011dcbdb50a6b48ee59738b75c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 4): internal/store/postgres/account.go:885-892 | internal/store/postgres/account_rating.go:451-458 | internal/store/postgres/account_rating.go:495-502 | internal/store/postgres/channel_update_retention.go:109-116 \u2014 there are 4 copies across 3 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060userID\u0060 in one and \u0060olderThanUnix\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":885}}}],"partialFingerprints":{"codehealthFindingId/v1":"1dfe1072480bd260626b957e4912c3e681fa6b6f905394620fac359d299fe6d4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/star_gift_lifecycle.go:1427-1434 | internal/store/postgres/star_gift_lifecycle.go:1444-1451 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_lifecycle.go:1427\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1427}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa17b5f2d1f070f73f023028cd2e01b661e4ba3bb1aaa0b23dede0a98d6fdfcb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 20): internal/store/postgres/channel_helpers.go:84-91 | internal/store/postgres/channel_invite_exported.go:30-37 | internal/store/postgres/channel_member_admin.go:25-32 | internal/store/postgres/channel_member_admin.go:180-187 | internal/store/postgres/channel_member_admin.go:320-327 | internal/store/postgres/channel_member_admin.go:384-391 | internal/store/postgres/channel_member_join_requests.go:138-145 | internal/store/postgres/channel_message_delete.go:31-38 | internal/store/postgres/channel_message_delete.go:211-218 | internal/store/postgres/channel_message_delete.go:384-391 | internal/store/postgres/channel_message_edit.go:432-439 | internal/store/postgres/channel_message_edit.go:528-535 | internal/store/postgres/channel_reaction_messages.go:198-205 | internal/store/postgres/channel_reaction_messages.go:270-277 | internal/store/postgres/channel_read.go:152-159 | internal/store/postgres/channel_settings.go:31-38 | internal/store/postgres/channel_settings.go:100-107 | internal/store/postgres/channel_settings.go:176-183 | internal/store/postgres/channel_settings.go:228-235 | internal/store/postgres/channel_topics.go:401-408 \u2014 there are 20 copies across 10 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 20 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_helpers.go:84\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"9074c803dbd4ac379f4a5972ada65454472471fe678a742574bcb62a1f467599"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/star_gift.go:97-104 | internal/store/postgres/star_gift.go:115-122 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift.go:97\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"6821782958b9018aa719094ae83244e9a4740b8f4543d9b4be3e16e74b583fc5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_reaction_unread.go:213-220 | internal/store/postgres/channel_read.go:690-697 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_reaction_unread.go:213\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":213}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5efa18e17f27313bce3d989f502fd864db8002c7ac497e27670d1571e0ac64f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/admin/botverification.go:809-816 | internal/admin/verification.go:347-354 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":809}}}],"partialFingerprints":{"codehealthFindingId/v1":"64efeb745bb079c7ff04168aae22aa9f45ced3150ccb99a2977a5f1c09fcdf1f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 8): internal/store/postgres/channel_settings.go:166-173 | internal/store/postgres/channel_settings.go:575-582 | internal/store/postgres/channel_settings.go:712-719 | internal/store/postgres/channel_settings.go:761-768 | internal/store/postgres/channel_settings.go:797-804 | internal/store/postgres/channel_settings.go:895-902 | internal/store/postgres/channel_settings.go:931-938 | internal/store/postgres/channel_topics.go:16-23 \u2014 there are 8 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 8 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_settings.go:166\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f1ab96e6ebc6deba7d93653ef7d2952e4ad1fc214a7cab827dd0fbe2fcc9a82"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/stargifts/service.go:1073-1080 | internal/store/postgres/premium.go:209-216 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/stargifts/service.go:1073\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":1073}}}],"partialFingerprints":{"codehealthFindingId/v1":"047bd0c481938e71c3d5626c806c3194a7f3f16f805051a81a415c4d60a879d0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/channel_invite_import.go:90-97 | internal/store/postgres/channel_member_join.go:53-60 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_invite_import.go:90\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":90}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec5ecff662b5ce6573b1bbd5a3dbdb40113833871ab1eec37582c72c30cb3b28"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/themes.go:80-87 | internal/store/postgres/themes.go:95-102 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/themes.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbe9602ccbc79077116afa5ea4053e840ea1da0a3a84f54837adddb32a640dcd"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/groupcall.go:362-369 | internal/store/postgres/groupcall.go:398-405 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/groupcall.go:362\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":362}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a365743a142102272cdcb0df7c234323be289e136ed561fe4a29d64dbe33a0a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/ai.go:85-92 | internal/store/postgres/ai.go:97-104 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ai.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"74e9fd7b3f79e973dec444831665492d03b52ce850cbf443cd095c9defd17c65"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/groupcall.go:746-753 | internal/store/postgres/groupcall.go:758-765 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/groupcall.go:746\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":746}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bf1ac9eb2c52c9cc95dc91ae6b436aa445c2984abbc00348c4aa8ff04f3ad60"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/loadharness/startup.go:769-776 | internal/loadharness/startup.go:851-858 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/loadharness/startup.go:769\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":769}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e4456a97f99be481e3762874ce0e205d66473ed8c8c9ed7744845780da44b76"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 9): internal/store/postgres/channel_settings.go:166-173 | internal/store/postgres/channel_settings.go:575-582 | internal/store/postgres/channel_settings.go:712-719 | internal/store/postgres/channel_settings.go:761-768 | internal/store/postgres/channel_settings.go:797-804 | internal/store/postgres/channel_settings.go:846-853 | internal/store/postgres/channel_settings.go:895-902 | internal/store/postgres/channel_settings.go:931-938 | internal/store/postgres/channel_topics.go:16-23 \u2014 there are 9 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 9 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_settings.go:166\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":166}}}],"partialFingerprints":{"codehealthFindingId/v1":"aeb578fd7e1bc0966bc8a5446aab11da13d747d05e1fcf0726d30f0d9998d890"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/app/groupcalls/service.go:266-273 | internal/app/phone/registry.go:117-124 | internal/app/secretchat/service.go:311-318 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/groupcalls/service.go:266\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/groupcalls/service.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4d92609c874ada21babcf7fd238e5ed2479594fa0826c975252787a509ab16f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 6): cmd/telesrv-admin/readstore.go:566-573 | internal/store/postgres/account.go:886-893 | internal/store/postgres/account_rating.go:452-459 | internal/store/postgres/account_rating.go:496-503 | internal/store/postgres/channel_read.go:894-901 | internal/store/postgres/channel_update_retention.go:110-117 \u2014 there are 6 copies across 5 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 6 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:566\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind \u0060int64\u0060 to \u0060userID\u0060 in one and \u0060olderThanUnix\u0060 in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH \u2014 their common supertype where they have one, or a new abstraction over them where they do not \u2014 and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. Check import visibility before settling on that home: \u0060internal/store/postgres/account.go\u0060, \u0060internal/store/postgres/account_rating.go\u0060, \u0060internal/store/postgres/channel_read.go\u0060 sit under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"06310c87df4fbb13b05e085c714f0c8e40a5a2cf803a5d60ef2bb1741b0e0254"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/store/postgres/user.go:47-54 | internal/store/postgres/user.go:77-84 | internal/store/postgres/user.go:95-102 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/user.go:47\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea7b3fe451d171965c0b62bc73ec96ede8b640f27930351ca87be7554c5ca599"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): cmd/telesrv/main.go:272-279 | internal/adminapi/server.go:190-197 | internal/web/server.go:120-127 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv/main.go:272\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Check import visibility before settling on that home: \u0060internal/adminapi/server.go\u0060, \u0060internal/web/server.go\u0060 sit under a restricted \u0060internal\u0060 directory, which only code inside its own subtree is permitted to import from \u2014 so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5a9debecf8891345f9018ad65c68dd114d93ad7abb1ab16be17e7ad338294aa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/app/bots/verifierbot.go:306-313 | internal/app/bots/verifybot.go:245-252 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/verifierbot.go:306\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2b99b20d4a0d699e05ef48deb7d434651045b20d69a77009932f3cb7e5e854b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 3): internal/store/postgres/channel_stats.go:36-43 | internal/store/postgres/channel_stats.go:183-190 | internal/store/postgres/channel_stats.go:253-260 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_stats.go:36\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cf57abc7b550a3252ca9ef38202a3690dfe7f9b9dbd773df8662a465ee494de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/admin/service.go:3515-3521 | internal/admin/service.go:3564-3570 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3515}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a4ba5677c6720f42b2f7422d33664885d6f2395736269731b3827c5815041fb"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/story.go:1707-1713 | internal/store/postgres/story.go:1725-1731 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1707}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e1732a1608aeee1ab5e6b567d530b030ee1be4406655ee76d33e6226a07541f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/telesrv-admin/readstore.go:483-489 | cmd/telesrv-admin/readstore.go:1073-1079 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/readstore.go:483\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f67630936f9f346fd42b0db17a019c0e84ac4c1c6ee4d88f58ad62079a41ea6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/botverification/service.go:1446-1452 | internal/app/verification/service.go:1292-1298 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/botverification/service.go:1446\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1446}}}],"partialFingerprints":{"codehealthFindingId/v1":"a73bd6b612a6255e4b137d814e6030fea2d8034db4de68bab77d55e4fdc87e26"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (13 lines \u00D7 2): internal/store/postgres/peer_username.go:185-197 | internal/store/postgres/peer_username.go:261-273 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/peer_username.go:185\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/store/postgres/peer_username.go:185\u0060 is reached only past a guard at line 177 that tests \u0060peer.ID\u0060 and \u0060peer.Type\u0060 and leaves the function early, and \u0060internal/store/postgres/peer_username.go:261\u0060 reads \u0060peer.ID\u0060 and \u0060peer.Type\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/peer_username.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c9f6cf68a521f35879ef04bb869f128774bfa3c626f91462cdaa063bf050af8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 4): internal/store/postgres/channel_member_join_requests.go:13-19 | internal/store/postgres/channel_member_join_requests.go:39-45 | internal/store/postgres/channel_member_join_requests.go:65-71 | internal/store/postgres/channel_message_settings.go:13-19 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_join_requests.go:13\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join_requests.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f8e0a8f4eef48eb7184387327e5b08b7516f3d65505b6febfba1f16d6cc9163"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/moderation_registries.go:134-140 | internal/store/postgres/moderation_registries.go:256-262 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_registries.go:134\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3516ab8c669250ebefafb54d8333846de401f87aaa22f4fbf953a675d81e11e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/channel_history_ttl.go:64-70 | internal/store/postgres/history_ttl.go:123-129 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_history_ttl.go:64\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_history_ttl.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"d453e2ea29a609b0ac968c85feb6fb44947ecba5ac6a7258398db2a4cad31a94"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/message_history.go:308-314 | internal/store/postgres/message_history.go:503-509 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_history.go:308\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"c71510d58c7598163c112070162451917b45646f1edcbe58071c5e4783d4ea27"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/botapi/server.go:525-531 | internal/botapi/server.go:658-664 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/botapi/server.go:525\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":525}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2f9c56886596979cb469fba392404c438bf5a57dec08d18c0004962fb8c38f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/bot.go:302-308 | internal/store/postgres/bot_miniapp.go:30-36 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/bot.go:302\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"1988f73033b2dde28d2b3a617d9104f30a49f29afbfff3d01ad5271b408ac023"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (12 lines \u00D7 2): internal/store/postgres/message_edit.go:132-143 | internal/store/postgres/message_edit.go:210-221 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_edit.go:132\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"165dc95bd98c8ca4ded84ef53cb0d27da8cb37bd9c6ba328dff1edeadb59dfe1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/moderation_cases.go:596-602 | internal/store/postgres/moderation_cases.go:636-642 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/moderation_cases.go:596\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":596}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cd002e995c920583ed2628b29a818f0df4735be784ee771a4a43082e63e5739"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/message_send.go:239-245 | internal/store/postgres/message_send.go:420-426 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_send.go:239\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/message_send.go:427\u0060 calls \u0060reservePts\u0060, \u0060Errorf\u0060 and \u0060internal/store/postgres/message_send.go:246\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"3d4a2f3a3c628fa3f1f141565321d09d59de5259c45128999603405ac1b09590"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/app/files/blobfs.go:114-120 | internal/app/files/blobs3.go:87-93 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/blobfs.go:114\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/blobfs.go"},"region":{"startLine":114}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6a84dbe16dd25a1c3274fcba6d013b2b094fdc87a0c8cf40efd2e290cf2510b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/bootstrap_update_job_batch.go:358-364 | internal/store/postgres/channel_member_list.go:388-394 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/bootstrap_update_job_batch.go:358\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bootstrap_update_job_batch.go"},"region":{"startLine":358}}}],"partialFingerprints":{"codehealthFindingId/v1":"cdcffcfc75aeb1c1ad608ec5d9fbf0f69b51f809332f91f20b78c795af87a512"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/telesrv-admin/server.go:1726-1732 | cmd/telesrv-admin/server.go:1832-1838 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/server.go:1726\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1726}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3046a79a15ef4236701c73a9b77cde858730333766727ba5ec2dc9e6d44623b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/phone_calls.go:107-113 | internal/rpc/phone_calls.go:195-201 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/phone_calls.go:107\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_calls.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"14ea30806d1fd7da58d306a9a344fcaa3a06aaaae6fa287d098f22da0851ef73"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): internal/store/postgres/channel_helpers.go:716-722 | internal/store/postgres/channel_helpers.go:789-795 | internal/store/postgres/story.go:1992-1998 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_helpers.go:716\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":716}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9b9fbe720dadbff42325aae03907280dbb04fedf13a083a537bac5b87416dd4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/story.go:1652-1658 | internal/store/postgres/story.go:1670-1676 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1652}}}],"partialFingerprints":{"codehealthFindingId/v1":"9248619016512e70752b97667d88546be4bbadd1eb6f8672a104a3589b9a86b1"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/account.go:468-474 | internal/store/postgres/account.go:512-518 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/account.go:468\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"e596b8297c72cb5e95793405dbbbe5ae15ec85312a1240ee9ae8a96dc12ffa6d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/star_gift_collectibles.go:106-112 | internal/store/postgres/star_gift_collectibles.go:120-126 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/star_gift_collectibles.go:106\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"8205dff08fcb0e59733af943695ab8f937f619f6e71dd42dc6f2cc6bd1d19d1d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/loadharness/dataset.go:372-378 | internal/loadharness/types.go:115-121 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/loadharness/types.go:122\u0060 calls \u0060Slice\u0060 and \u0060internal/loadharness/dataset.go:379\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":372}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8fb95638040c7767e036cd6642e8189a71bee6ec9b2e94cc264847f1bce9965"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 3): cmd/telesrv-admin/server.go:2026-2032 | cmd/telesrv-admin/server.go:2072-2078 | cmd/telesrv-admin/star_gift_catalog.go:188-194 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2026}}}],"partialFingerprints":{"codehealthFindingId/v1":"530b0dbf84fd631fa20dafad7caa7f37781fb2b59fb4e7e16a3d707b4684cc9d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/channel_member_helpers.go:142-148 | internal/store/postgres/peer_username.go:92-98 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_helpers.go:142\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a \u0060defer\u0060-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead \u2014 before the caller uses what it releases \u2014 so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_helpers.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"691254bc4b4a8e32389e5078332a48c9d2946efa927c6253cf96ef2e1afd3e95"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/telegramloginhttp/handler.go:295-301 | internal/telegramloginhttp/handler.go:362-368 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/telegramloginhttp/handler.go:295\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1fe2876efd0af465ef4dde274d4dbd346ae7d100dadde97d0cb1f7d812f6d3a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/store/postgres/message_send.go:516-522 | internal/store/postgres/message_send.go:590-596 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_send.go:516\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":516}}}],"partialFingerprints":{"codehealthFindingId/v1":"e477111891b41b1f8e4c6dbd6623e3a4fa11c1f19d6e9d924a9efbe0f9480480"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/stickerfetch/main.go:284-290 | cmd/stickerfetch/main.go:414-420 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerfetch/main.go"},"region":{"startLine":284}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e88c2eac82d0528203644ed6a9c541b5bef12736a4ad5f53255bab67b0da152"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_message_history.go:211-216 | internal/store/postgres/channel_message_history.go:231-236 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_history.go:211\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd8b12e2f0b702c4a1a987163a3ab3382331e31a3284eab2020591d527df95f0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 4): internal/store/postgres/message_history.go:829-834 | internal/store/postgres/message_history.go:901-906 | internal/store/postgres/message_history.go:973-978 | internal/store/postgres/saved_dialog.go:446-451 \u2014 there are 4 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_history.go:829\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":829}}}],"partialFingerprints":{"codehealthFindingId/v1":"3111dd9e1071603cd1099ea201638e63c766b8672b87e6e32c0938a0d2d68257"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/app/files/encrypted_file.go:26-31 | internal/app/files/photos.go:350-355 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/files/encrypted_file.go:26\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/encrypted_file.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"6142dfc2e9dbfdf445e1e484a0b3cf6cea868395501897acb7d92cecf4cb450f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/message_delete.go:405-410 | internal/store/postgres/message_read.go:245-250 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_delete.go:405\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/store/postgres/message_delete.go:412\u0060 calls \u0060authKeyIDToInt64\u0060 and \u0060internal/store/postgres/message_read.go:252\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":405}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d3293c9a1e711b664ed149a33ebfa574bcda26f71d73dc3f817a7dff89260de"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_message_edit.go:501-506 | internal/store/postgres/channel_message_edit.go:587-592 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_edit.go:501\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":501}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6a7b721762059a8f166e2094db852e85c0116e69076d07f2cf26dbd1a32385e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/message_edit.go:185-190 | internal/store/postgres/message_edit.go:281-286 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_edit.go:185\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":185}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc26b21f5beef3de1c141c621706e2981da3e3630af31e078dfaecc4e58daaa2"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/channel_message_history.go:134-139 | internal/store/postgres/channel_message_history.go:157-162 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_history.go:134\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"aed1cb0187c9a0d3ae2751428ecb30e253e9ab9f3197784907256aacbfceebf9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/adminapi/botverification.go:41-46 | internal/adminapi/botverification.go:60-65 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/adminapi/botverification.go:41\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"af0b272c5181bd469e085c46156272c95a8df5174f3bdda53a612719c843f1e8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): cmd/telesrv/main.go:489-494 | cmd/telesrv/main.go:553-558 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv/main.go:489\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dc452f6c3a1be624be9c02c17fde4e50b51d865f72ab19686247539810f88f4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/langpack.go:38-43 | internal/store/postgres/langpack.go:61-66 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/langpack.go:38\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/langpack.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"bea128fccb73457a1a1f96297b600419e71935a6f4149fafda7ea7b3ae617b5e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): cmd/telesrv-admin/server.go:1297-1302 | cmd/telesrv-admin/server.go:1347-1352 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1297}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbe77a706baa71e31bbb6f5ec86e0caae5d788dd7825157cb9f2a8b36d4bc7f7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 4): internal/rpc/botapi_gateway.go:186-191 | internal/rpc/botapi_gateway.go:244-249 | internal/rpc/botapi_gateway.go:302-307 | internal/rpc/botapi_gateway.go:886-891 \u2014 all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, \u0060internal/rpc/botapi_gateway.go:193\u0060 calls \u0060New\u0060 and \u0060internal/rpc/botapi_gateway.go:308\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":186}}}],"partialFingerprints":{"codehealthFindingId/v1":"207a810f6aa9da13faa57ff85aa56b40e337dd653f64fd28e6785a510326fd45"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/telegram_login.go:870-875 | internal/store/postgres/telegram_login.go:940-945 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/telegram_login.go:870\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":870}}}],"partialFingerprints":{"codehealthFindingId/v1":"408393d4601493305476fcf437433dbb4b410f754430aa31a8f1c8f5157a6d39"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): cmd/telesrv-admin/botverification.go:75-80 | cmd/telesrv-admin/botverification.go:94-99 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060cmd/telesrv-admin/botverification.go:75\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"cda120ad0dee34e7b6611e6005dc9bfffbe997276f3f8f77511e3c3d4f1f007e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/web/server.go:749-754 | internal/web/server.go:808-813 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/web/server.go:749\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/server.go"},"region":{"startLine":749}}}],"partialFingerprints":{"codehealthFindingId/v1":"d393fdce0cd3c4aebecd9c8f1a10d61fac32e13e85de8a665c608fe6eca53844"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/groupcall.go:234-239 | internal/store/postgres/groupcall.go:246-251 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/groupcall.go:234\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"0215158ed34167431db0951610bacfdda91b0e7ff3d21333382ddc85472779e4"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 4): internal/store/postgres/channel_message_history.go:74-79 | internal/store/postgres/channel_reaction_unread.go:223-228 | internal/store/postgres/channel_read.go:701-706 | internal/store/postgres/channel_topics.go:965-970 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from all 4 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_message_history.go:74\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"62abc4080a864b5dd2318063cf883a175db36fc1d6e35bd2cbdee80cd8493755"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/postgres/message_edit.go:146-151 | internal/store/postgres/message_edit.go:225-230 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/message_edit.go:146\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":146}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7a2394a6570c25debf812e00c19c1c1c9fbdde00cce46d05ffb6eb33c7dea12"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (2\u20135 lines \u00D7 3): internal/store/postgres/channel_member_admin.go:89-93 | internal/store/postgres/channel_member_admin.go:157-161 | internal/store/postgres/channel_member_admin.go:364-365 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_member_admin.go:89\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"c147e0362ba2dff301eed0c78aecd5e26fe46d0010d572e6b00288fd6ab8cbf5"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/telegram_login.go:881-885 | internal/store/postgres/telegram_login.go:951-955 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/telegram_login.go:881\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":881}}}],"partialFingerprints":{"codehealthFindingId/v1":"145e4ea8fea0860d132148ea6b956c8c1810b79babc05089583f1092507c3d03"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (8 lines \u00D7 2): internal/store/postgres/telegram_login.go:910-917 | internal/store/postgres/telegram_login.go:978-985 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/telegram_login.go:910\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":910}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3ff230812697a0ca3089b0860d451ef92f7944aef7960dfa3eae8dce66221db"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/channel_invite_import.go:219-223 | internal/store/postgres/channel_member_join.go:121-125 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_invite_import.go:219\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":219}}}],"partialFingerprints":{"codehealthFindingId/v1":"baabdf2812c75110929a1814f883bd15cbce5d43dd5a8d5085535596417c6588"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/telegramloginhttp/handler.go:528-532 | internal/telegramloginhttp/handler.go:537-541 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/telegramloginhttp/handler.go"},"region":{"startLine":528}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cc2503b6eb815a6229d9b178982d7e44e156a80e8bfd0c2c297949ca77b5ed7"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/app/bots/stickersbot.go:409-413 | internal/app/bots/stickersbot.go:443-447 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/bots/stickersbot.go:409\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b5283110473fce2f250203739a8308f58e4f5ec153ee5c46f2755a91309c9db"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/read_model_listener.go:428-432 | internal/store/postgres/read_model_listener.go:451-455 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/read_model_listener.go:428\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_listener.go"},"region":{"startLine":428}}}],"partialFingerprints":{"codehealthFindingId/v1":"1dc4cb2e86deb6545c5cd8bc0a28dd75f202fb1bb7d05b5608beb22e2af6978a"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/telegram_login.go:829-833 | internal/store/postgres/telegram_login.go:840-844 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/telegram_login.go:829\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":829}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2e88d75248cdfda75623073161f5e15207c51404829a21757c7a94edd7cc2e3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/layer_dispatch.go:287-291 | internal/rpc/layer_dispatch.go:512-516 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/layer_dispatch.go:287\u0060 it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows \u2014 the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members\u0027 bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run \u2014 a one-line delegation has no helper inside it to lift \u2014 so generate the run from the set it enumerates, or accept it and keep each member\u0027s own documentation with it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_dispatch.go"},"region":{"startLine":287}}}],"partialFingerprints":{"codehealthFindingId/v1":"49139e8f22572166545748e966d264cec18646ebe3f3a512bc7d25e3907a8fd3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/store/postgres/telegram_login.go:491-495 | internal/store/postgres/telegram_login.go:502-506 | internal/store/postgres/telegram_login.go:513-517 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/telegram_login.go:491\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":491}}}],"partialFingerprints":{"codehealthFindingId/v1":"13be1491c934ee14339799d42a846bc55d1f4e936e31a0535747aee3d5c12663"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/telegram_login.go:103-107 | internal/store/postgres/telegram_login.go:114-118 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/telegram_login.go:103\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee7ce859784c4742624be98515f7634c04b82f63a4528ca4ba1efb6e3e096f6d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): cmd/telesrv-admin/botverification.go:263-267 | cmd/telesrv-admin/botverification.go:282-286 | cmd/telesrv-admin/botverification.go:301-305 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd8615f426fa0bc273847334725abcad47487906a9d77f234a88537bd963b304"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/channel_stats.go:211-215 | internal/store/postgres/channel_stats.go:386-390 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/postgres/channel_stats.go:211\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"2480dce59fa5f17a5f380b14ed1422aeb7d116e6f82ffe2b6f0ab4bba2b84cd9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/app/account/lifecycle.go:230-234 | internal/app/account/phone_change.go:81-85 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/account/lifecycle.go:230\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"008b372ad6c550b1ec93682d39412f484b32182ff90ee2a8a617aff54a3d9be0"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): cmd/telesrv-admin/verification.go:141-145 | cmd/telesrv-admin/verification.go:160-164 | cmd/telesrv-admin/verification.go:179-183 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/verification.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b18357bfb37bb3a3c9f1f5b92f12a15bd9fa6cacdfa2d5d14c48505a07cc156"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/storetest/groupcall.go:205-209 | internal/store/storetest/groupcall.go:225-229 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/storetest/groupcall.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"51c00f7a57ca8000bec5e46c6cd9df9ace947726bc6cc9f3e47f6ff5f7996ee8"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/memory/message_send.go:258-262 | internal/store/postgres/message_send.go:662-666 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_send.go:258\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_send.go"},"region":{"startLine":258}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cd16f5f6615435315dffdb5c7db1241ea0e71f5b1111b52717d7016c75c2a1e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/postgres/channel_message_edit.go:133-137 | internal/store/postgres/channel_message_edit.go:304-308 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":133}}}],"partialFingerprints":{"codehealthFindingId/v1":"c662332bc620f7a909d0589581817b0684bf9819564e15ac47a028877277288f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/admin/service.go:2194-2198 | internal/admin/service.go:2282-2286 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/admin/service.go:2194\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2194}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9bf46bf7cda56e278621b8bc40053aac075d7a03fceb6597843637ce1881818"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/app/bots/stickersbot.go:275-279 | internal/app/bots/stickersbot.go:352-356 | internal/app/bots/stickersbot.go:458-462 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":275}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd1ec00b5cfdc949289a762aee4b9f7818fb6c84fa0a5e9c572acc69459ea331"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/messages_attach_menu.go:110-114 | internal/rpc/messages_webview.go:176-180 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/messages_attach_menu.go:110\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_attach_menu.go"},"region":{"startLine":110}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfdb7c0ea48f48a13ed11d391a115a6ce6dbf76bbba68b162bb64b030c90d89e"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/app/channels/read_model_cache.go:103-107 | internal/app/dialogs/read_model_cache.go:567-571 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/read_model_cache.go"},"region":{"startLine":103}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5a9df0c57fce679655d90c7f35b52704889218e6f215ef898592506c5f7119b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 3): internal/app/telegramlogin/service.go:1092-1097 | internal/app/telegramlogin/service.go:1176-1181 | internal/app/telegramlogin/service.go:1234-1239 \u2014 all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites \u2014 resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/app/telegramlogin/service.go:1092\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":1092}}}],"partialFingerprints":{"codehealthFindingId/v1":"a156be4a1877978b6db76d645099f7efcf98627ea07a92a9e8c7690925594613"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/mtprotoedge/rpc_execution_budget.go:201-206 | internal/mtprotoedge/rpc_result_subscriber_budget.go:144-149 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_budget.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"96555207727d382ae4e615fc5b7217dd682d2bbccf20911162b10e18085d9241"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/channels_legacy_chat.go:448-454 | internal/rpc/channels_members.go:509-515 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/channels_legacy_chat.go:448\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: \u0060internal/rpc/channels_legacy_chat.go:448\u0060 is reached only past a guard at line 423 that tests \u0060req.Rank\u0060 and leaves the function early, and \u0060internal/rpc/channels_members.go:509\u0060 reads \u0060req.Rank\u0060 with no such check. What separates these copies is not which lines they run but which PRECONDITION they enforce, so one of them is operating on state the other one refuses. Decide which is intended BEFORE unifying them \u2014 extract the shared part and whichever copy is missing the check keeps running unchecked, and if the guard is the correct behaviour then that hole is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":448}}}],"partialFingerprints":{"codehealthFindingId/v1":"b26415e74307f05cd47e340841a6ba62f52c13f61f55a210bb4f7c40f78f2e9f"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (10 lines \u00D7 2): internal/rpc/deps.go:363-372 | internal/store/bot.go:36-45 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":363}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1a67666897a41380164daa0ec677f1b0522df3a4ef16a6589bebda306824dc3"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/deps.go:524-528 | internal/store/account.go:110-114 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/deps.go:524\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"2df9bcef1d7747ee231dd4316d9908bb07f617315097b1e7ec64fe883086f95c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (15 lines \u00D7 2): internal/rpc/deps.go:800-814 | internal/store/channel.go:70-84 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":800}}}],"partialFingerprints":{"codehealthFindingId/v1":"da7d2dd50bd08827fe00e117e8cd3370ecf47a30df06a5c4e37841de7419b27d"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/deps.go:1281-1286 | internal/store/star_gift.go:64-69 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":1281}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdf4dfdbbfa8a62429e8db916ff3ef5cecefc90cac2192ff4f274486ae5116b6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/inline_registry.go:779-783 | internal/store/postgres/media.go:582-586 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/inline_registry.go"},"region":{"startLine":779}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c05d49bbe265232ef414832cbd9c03eaffe3a6cb1e41e9a62c6e480bb80cbfa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): internal/rpc/messages_forward.go:135-141 | internal/rpc/messages_forward.go:294-300 \u2014 both copies are in the same file, so extract the block into one function there and call it from each site \u2014 the copies drift apart the first time only one of them is edited."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"4098b50334b3e0eb5126af8f2c09afaecdaae3c6fa8233a8351c5ce18d1a9e16"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/rpc/messages_sticker_sets.go:12-17 | internal/store/account.go:73-78 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any \u0060return\u0060 inside it is the body\u0027s own exit and keeps its meaning in the moved unit."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_sticker_sets.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"1540cd564fc3a326a817b69e070f94380965e218eaa540c05b4cf30365f1533b"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/phone_group_call.go:289-293 | internal/rpc/phone_group_call_rtmp.go:43-47 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe0d5a250b51bba4b5abcb47afa58fbdefd383ccf19610f77b5b201e381b87a9"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/rpc/phone_group_call.go:375-379 | internal/rpc/phone_group_call_rtmp.go:99-103 \u2014 the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach \u2014 a file they already depend on, or a new one alongside them \u2014 and call it from both call sites, so a change lands once."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d3f89098fd6a9e3bb588e44476b486ae85ff2b8b05e43f841289b618bd299d6"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 3): internal/rpc/presence.go:778-782 | internal/rpc/update_peer_refs.go:280-284 | internal/rpc/update_peer_refs.go:296-300 \u2014 there are 3 copies across 2 file(s) \u2014 more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/rpc/presence.go:778\u0060 it runs out through the closing brace of the declaration holding it \u2014 the window is that declaration\u0027s tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/rpc/update_peer_refs.go:279\u0060 calls \u0060removeKnownChannelRefs\u0060 and \u0060internal/rpc/presence.go:777\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":778}}}],"partialFingerprints":{"codehealthFindingId/v1":"40a85dffa02c2d470f7677710d853eec3655d3a1c8bbc2862bf1ddd6bedbeffa"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/channel_message_edit.go:78-83 | internal/store/postgres/channel_message_edit.go:151-156 \u2014 \u0060internal/store/memory/channel_message_edit.go\u0060 and \u0060internal/store/postgres/channel_message_edit.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 4 separate duplicated blocks between them, totalling at least 56 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/channel_message_edit.go:78\u0060 it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"78f250d02af706799687475e4f065a71ed0f59b92d9fa0f90446a70f16f9e531"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (5 lines \u00D7 2): internal/store/memory/channel_stats.go:231-235 | internal/store/postgres/channel_stats.go:526-530 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"21ff9edc20217a90ebdd14333f86b4d9803133f554fdab1ea567d749059a1966"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (6 lines \u00D7 2): internal/store/memory/message_forward.go:52-57 | internal/store/postgres/message_forward.go:62-67 \u2014 \u0060internal/store/memory/message_forward.go\u0060 and \u0060internal/store/postgres/message_forward.go\u0060 are one unit implemented once per sibling directory, so they are most likely parallel implementations of one contract rather than a copy of each other \u2014 this scan matched 3 separate duplicated blocks between them, totalling at least 51 lines. If both are selected at run time, neither can be retired in favour of the other, and the lines that DIFFER between them are the reason both exist. The move that pays here is to hoist the identical part into a shared location the whole family can reach and give what differs a parameter or a seam, so a change lands once instead of once per sibling; extracting one helper per block leaves every sibling to drift on its own. Read the line range as the matched WINDOW rather than a finished unit: at \u0060internal/store/memory/message_forward.go:52\u0060 it does not close everything it opens, so those exact lines cannot be lifted as they stand \u2014 widen the region to the smallest complete statement or declaration that contains it, and extract that. \u2605 These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, \u0060internal/store/memory/message_forward.go:50\u0060 calls \u0060RUnlock\u0060 and \u0060internal/store/postgres/message_forward.go:61\u0060 does not \u2014 after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_forward.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b6c95ef766653c26336cff843eb154706d4dfcc730f082cb372d361ff20017c"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/bots/aiogramecho/echo.py:163-169 | cmd/bots/ptbecho/echo.py:130-136 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"146d46ac38d67feb3bee9fc16dd6320b6ff1133131ecb79d336e101be71fd1ce"}},{"ruleId":"D4","level":"warning","message":{"text":"Duplicated block (7 lines \u00D7 2): cmd/bots/aiogramecho/echo.py:304-310 | cmd/bots/bedolagaformat/demo.py:449-455 \u2014 the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach \u2014 a location they all depend on today, or a new shared one if there is none \u2014 and call it from each site; until then, every change has to be made twice. The \u0060return\u0060 at the foot of the matched lines is the enclosing body\u0027s own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that \u0060return\u0060 occupied \u2014 no decision has to be handed back and re-acted on."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":304}}}],"partialFingerprints":{"codehealthFindingId/v1":"e49268c495bd4c232c992f8bda98033ccab8e3ebe4e57ed08a856076e576da46"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: Service (LCOM4 8): Service\u0027s methods fall into 8 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \u2014 your repository\u0027s bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 8 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected \u2014 and which would otherwise dominate this list \u2014 are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/service.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"903bf08544b7ca3903bf9886008420a5f7e9f55a92620ab690321da8d7296f8c"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: appServer (LCOM4 4): appServer\u0027s methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \u2014 your repository\u0027s bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected \u2014 and which would otherwise dominate this list \u2014 are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"295904590f1d6c459c887619609dc231c2506bddd3aea87bd8fac706d830b3b9"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: Service (LCOM4 4): Service\u0027s methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \u2014 your repository\u0027s bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected \u2014 and which would otherwise dominate this list \u2014 are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e531fd7cfcf36398589a985587d0e819de8fa5d27c7464c213386ef879d1f0e"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: layerRPCResultEncoder (LCOM4 4): layerRPCResultEncoder\u0027s methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \u2014 your repository\u0027s bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected \u2014 and which would otherwise dominate this list \u2014 are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/layer_rpc_execution.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"510bda377cffacb4b23e42820831a6695d7d07b88421ca4909cdef79a9d1b485"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: Router (LCOM4 4): Router\u0027s methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \u2014 your repository\u0027s bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected \u2014 and which would otherwise dominate this list \u2014 are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae1bee67851c2c5a56fde19cb5107fa0bff5b9f81409801d459c5d2b0fa498f0"}},{"ruleId":"D6","level":"warning","message":{"text":"Low cohesion: CommunityStore (LCOM4 4): CommunityStore\u0027s methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable \u2014 your repository\u0027s bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected \u2014 and which would otherwise dominate this list \u2014 are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":20}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0a659f1b400faf3d0ba8e4eea96b3c5399207f50906f89b61c88b96e5417d3f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/appearancefetch/main.go: 0.0% line coverage (0/305)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/appearancefetch/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dd407c363d454bccc52a206d9a0f280d00cfee6dda29a6b88ca2cfada281d70"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/blob-migrate/main.go: 0.0% line coverage (0/178)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/blob-migrate/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"89d8f4370d6ae363997a593f7a450a00bf4dd69fec17daf10daeec66771c2757"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/bots/botcheck/main.go: 0.0% line coverage (0/209)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7f7571572e8ea8b62bfc2065ae8c5913a2f35473e72b40aafdd9638d01d07c8"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/bots/botdemo/main.go: 0.0% line coverage (0/289)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botdemo/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"29c568401ab21178a7c7df069bb729fca1cf3529110ce502f3a600c677ad8bcc"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/catalogfetch/main.go: 0.0% line coverage (0/90)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/catalogfetch/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5375ccd8671594f7154900d719c960fe6d082fd12bb5acce13baa83c13c3dfc"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/langpackfetch/main.go: 24.5% line coverage (47/192)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/langpackfetch/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"588e157ffed3071923aaa69ef2c5b0f7a58fc9d93c916a2edd51f28fe2068518"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/otpwebhook-example/main.go: 49.0% line coverage (120/245)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/otpwebhook-example/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"906d141e8c421f824c76de58fab1e530fdab1980d90a11abf960170dff324026"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/owpengram-ctl/main.go: 0.0% line coverage (0/146)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/owpengram-ctl/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bdfad977e4d64af091c235408e320ae02716ab3f2197cf86467ce973b05c7bf"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/stickerfetch/main.go: 6.2% line coverage (15/241)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerfetch/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b69ed5e9f1df79d5c01822e9a89246c13b8ef62fd0c1475105fefea3469ab2c0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/stickerseeddeploy/main.go: 20.9% line coverage (56/268)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerseeddeploy/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb2d051439d9d84902557b9a6d49c3072ba917e2ab8211ca158a462c6d6c6557"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/account_rating.go: 0.0% line coverage (0/81)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/account_rating.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ae7c41d579558c6b7f5d48a9beb515c769212ad8050e9dd6bc60e77f2ec4d96"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/activity.go: 0.0% line coverage (0/92)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/activity.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e915b6002e7db3d253b58fedcb1ad9ef2e2cf1bce6edd0c04de5d2156b659922"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/addserverlink.go: 0.0% line coverage (0/11)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/addserverlink.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b03124a4777dff9e5561c902d50be689ac7ae213b0430e3a9d963f8f821839df"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/admin_command_runner.go: 0.0% line coverage (0/254)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/admin_command_runner.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9710d6c08ad41c4d5d881110b56d2a9b2b050b3f7f71edd24ab2ace1cfd9e72d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/adminusers.go: 0.0% line coverage (0/55)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/adminusers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"52a7688d803220914e119c609c2e21987b48f6ee97e12c39f356b41e88c09c15"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/adminusers_api.go: 7.5% line coverage (16/212)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/adminusers_api.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d681bf8e2fb2b92f1e6296ea7fab7d41a11c6e5ba4ab8ff4f7934db52d640cea"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/audit.go: 40.7% line coverage (11/27)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/audit.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4927651cb8636f39cede540c5919d6b39a3527472bc8d40dbae3f26bf6907b6f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/donations.go: 5.8% line coverage (10/171)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/donations.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"66edd2140640bc5d7c774d057ac3a627ba320df5a54f123e1d1b4d284ec09f9a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/main.go: 11.2% line coverage (13/116)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c2be0cadcd5c7079aa3841b5ad601afe9f748025dcff4cb0f6e81108dd0fd80"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/premium.go: 0.0% line coverage (0/55)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/premium.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"534b3418a4c1f8b1c6393d520d0eea4e4ddd9d0919af5e4cb6ec417b1b261226"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/privateview.go: 27.7% line coverage (119/430)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c6244895cbda3bea9ea7dcd7a7b3b350e3613e28702ef2bef9a646d083f33de"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/privateview_store.go: 12.7% line coverage (74/581)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bac5561c182d81b40d3d4304eddf27d63b37a3d0c74ca2479d5dd4c95de9aec"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/publicbranding.go: 0.0% line coverage (0/27)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/publicbranding.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c00919158a563b14e892bd03d7bd4dffff16857a6544fbeb5021f96495debc18"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/readstore.go: 0.2% line coverage (4/1934)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/readstore.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"42b9e1649c4f2f8c28a29d264a104b9956f52efabf673a9b8c0ddcb00dbc5ed5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/server.go: 23.3% line coverage (491/2105)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fef227cffdf92bacae93ecd281dbd1df37e4946d0b1af83eb89e8cbb8027f239"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/serversettings.go: 15.0% line coverage (32/214)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/serversettings.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bac11e9d98ae6acbf09b60348b32e7bb39eb53616cbc8e105a79451c2e00d6e8"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/serverstorage.go: 32.8% line coverage (61/186)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/serverstorage.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5980409e23e7dd52edc0bc05c49df8057deb7cde5fccae6a3917fbbef514adf"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/star_gift_catalog.go: 2.9% line coverage (9/307)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/star_gift_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"543cf23bdd6363e29a4cdbaa191569769b196d0d22fe310ecf425cf8fd786f6c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-admin/statscache.go: 39.2% line coverage (40/102)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/statscache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cde0f37edbde3447723a0d5b88dd661ad6950e93df21b566b1e00e2e4f80b82"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-load/main.go: 0.0% line coverage (0/397)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-load/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e85e9c1e63947fd3162eef7f3595e35f61d0149b5cae2c337906be442fc765b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv-update/main.go: 0.0% line coverage (0/76)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-update/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a61c2229420d0843548c5e9c1481c63f70a4aa4f6a2957e731319e613da486c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv/buildinfo.go: 0.0% line coverage (0/25)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/buildinfo.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dab690eee5a10922113f6106bf369ab62620488ac3044347313ed3acee1e78d6"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv/log_encoder.go: 0.0% line coverage (0/116)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/log_encoder.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"62c7194660d0b97c6e2c2d627cfe8b9a92551d137787c245cb0d1655977d45e2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/telesrv/main.go: 1.1% line coverage (18/1606)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6232d3c7ccd1cbcc5f42ce9be8c12b785595e9d37b74d6ebe5fb53237550eb41"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/tl-coverage/main.go: 0.0% line coverage (0/429)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/tl-coverage/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"baced252e49a7acf97b7f3cb1d276c28b15393e8506bb0b732b96172f29b5248"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: cmd/walletminiapp/main.go: 19.6% line coverage (81/414)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"29cde004ae2be993f9736521094f312f8967ff20b0f22fdc9f5ef9c55efd6857"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/admin/account_rating.go: 0.0% line coverage (0/104)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/account_rating.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4568b42dda57111cf271c2470a695b0818aec0c7b14208ca3f2819121572468"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/admin/private_media.go: 0.0% line coverage (0/17)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/private_media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"15d24e48aed0c49eb4bc8c44144ece515502e9bf81cb9b89e314dc7fab9bff27"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/admin/service.go: 34.2% line coverage (816/2387)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bcee83bb27085bda841a9238b445887a993a13a7af116ea864ad0f70b2008c2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/admin/star_gift_catalog.go: 0.0% line coverage (0/349)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/star_gift_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d0108bc348c0ead7288ebb972f8e4be3328fb65c3450f4e498222b748825e5c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/admin/system_notice.go: 0.0% line coverage (0/4)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/system_notice.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f567864b47d1aad2c93fd8067ba7ed1fa4b3874c0dcc08366e72bff74dddc22d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/adminapi/account_rating.go: 0.0% line coverage (0/111)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/account_rating.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"630251ff5d9996e3a83673c94f41e664baedf025ff103a8be7bee85d42d968e4"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/adminapi/server.go: 27.3% line coverage (372/1363)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d1566b428997985c97736957f7a56665d20ec308356ee09fa2635836152e9a4"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/account/lifecycle.go: 43.2% line coverage (120/278)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd92ac80a0595865af00a09f465c160a95f030d0eaf1aec8ff79bac9033cac7c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/ai/provider_http.go: 41.4% line coverage (161/389)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f992341dbc19e8a3e31eb1312220c252b9ee05abe204e96e9c5a583734451f6b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/bots/miniapp.go: 42.0% line coverage (110/262)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/miniapp.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"80f41384bba87ac90fec2ad5e07ef8271a41f3f78c701c0eab65df88f03521fb"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/bots/premiumbot.go: 37.6% line coverage (76/202)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/premiumbot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2acbf743b3de6e4419e873398fbba816888fac9c8c377a6e796621af6bb53d8"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/botverification/seed.go: 0.0% line coverage (0/29)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad4a2a285d9b7a52ee35ac84dda3ddb4c11967b26b96ea2805cb108a2c709a80"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/broadcast/worker.go: 0.0% line coverage (0/46)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/broadcast/worker.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f39b6c19cfc82aed6dc2401700731cf3f2c2b2828e7bd8e91a0f39d2c10d20e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/channels/service_groupcall.go: 27.8% line coverage (5/18)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service_groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f57c520419332afb7cd5ab1889a6f81e9e253f3caa8ffc0899edd3040843006"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/channels/service_suggested_post.go: 25.0% line coverage (4/16)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service_suggested_post.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e031d5efbb785f6db192d42697696a861ac5fb997a418a1101916156f5606ad"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/communities/service.go: 42.5% line coverage (45/106)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/communities/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1dae7baefd74e1105b6875c4202925942d07b8cc064eab192040193582ef39bd"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/donations/balance.go: 0.0% line coverage (0/71)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/balance.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7033d4bd29e28387569ffe88c62492e99e0799d050445cf4427761bad0bee492"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/donations/pricefeed.go: 0.0% line coverage (0/105)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/pricefeed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5733f91ec971761f4461d1a36fa4e24beab9333a8d45c0142c4130b0fa40cf0d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/donations/pricing.go: 0.0% line coverage (0/19)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/pricing.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4c1db4e4e64f991442ae07dd94357709e60c77eefb33378c27c4ef9868da695"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/donations/service.go: 6.4% line coverage (19/297)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc589946e4da67f033979ec5e77f54290bfce595a91e170ec9e087e8cf94fba0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/donations/sweep.go: 38.2% line coverage (81/212)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/sweep.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"01c3e7ea86c2465d0d9d0192a9bbb1771660cec182b6d054116e27b7daefea81"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/donations/watcher.go: 1.6% line coverage (4/243)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/watcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"76b2c979b26e7134ba5aac0d64660071631f28c012a01e088e77d5f2fe156c8f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/blobs3.go: 14.5% line coverage (16/110)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/blobs3.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f64679ee9fea8dd02f03c865924d76a1c8da98bbfbf6b52f3a84c2bfdb7e6593"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/botfather_avatar_seed.go: 0.0% line coverage (0/26)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/botfather_avatar_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"75f0e3246e2670984dd3562619acfe82df774aec46900ce540c445536b749099"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/chatbot_avatar_seed.go: 0.0% line coverage (0/26)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/chatbot_avatar_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b967ce005164787564e5251a5de02175bfa809efd917a1befdb956888a418c3a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/diskspace_unix.go: 0.0% line coverage (0/5)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/diskspace_unix.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e5f8494b49430e4c9e79cee871dd3de739c00e2ebf5b5c49a937331a66cfd91"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/diskusage_worker.go: 0.0% line coverage (0/31)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/diskusage_worker.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9058661255721f9ad916b6f0d6e830b6bbfe87f8b6b1fe320f417614798c76d7"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/emoji_animation.go: 0.0% line coverage (0/54)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/emoji_animation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e9dad9dc757a636438e1b1f3c8e50f057920788634c91c905bd96196b7c7cda"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/emoji_group_icons_seed.go: 13.6% line coverage (9/66)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/emoji_group_icons_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2bed6148ebf4606ae6a1cee60a4d8a785e65c97e221346ca453af44299c7908"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/encrypted_file.go: 0.0% line coverage (0/32)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/encrypted_file.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"747ef55c548c1b7e04da0675d453a4bb730f446815c00856507356982b97d282"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/external_media.go: 48.8% line coverage (63/129)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e3d6e0345a4edc4e4ecdf0ad9ec9de7a2d06abfe95682e22c06f9580aad8e06"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/gif_admin.go: 0.0% line coverage (0/190)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_admin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c54769b64b373b9e01350af82b303490a7c5f35779a14cd7644dbf6e3c7755e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/gif_classify.go: 0.0% line coverage (0/7)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_classify.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"291b2394667d8ca76ea5a973547a51f134370f624d4a053b8ea98d6ab60d04b3"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/gif_seed.go: 0.0% line coverage (0/74)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"05aabcd6401f34646c1440d48ad0a632ccd27d0b12cb75d7ed73e344fb6d62ce"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/gif_transcoder.go: 3.4% line coverage (4/118)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_transcoder.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"20b7f5ee8dbc05e51731ddb3661609895555c7ab34c6507af567c545b705a727"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/gifbot_avatar_seed.go: 0.0% line coverage (0/26)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gifbot_avatar_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"aee049334d41d4222c18e0c065440e0c7eca00b8e7fa5d597bfd81823bb18173"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/guarded_backend.go: 0.0% line coverage (0/27)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/guarded_backend.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd165b07b0e9d33f0b6999501266e08c70a02494c807a6464b208cd2970be590"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/premiumbot_avatar_seed.go: 0.0% line coverage (0/26)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/premiumbot_avatar_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f471a83c97c24084d55bbb12ce405168e2d3f5f062f52e1bc8e9c2822d720ca"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/retention.go: 41.3% line coverage (123/298)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9ac9a2a0065f435bf1bae5fa81908770a53091d4ba288cf12d8a7be324a8dde"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/sticker_admin.go: 13.8% line coverage (22/159)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_admin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"88663ba08970116910e66f62f29c2a7826c4b982f9fafe8ab5166607f5f4ef84"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/stickers_bot_avatar_seed.go: 0.0% line coverage (0/26)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/stickers_bot_avatar_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0db5f3d729a4ca18ea77ca83e216af17bbe2a66f2c4fdacc7283c183c002a16f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/system_avatar_seed.go: 0.0% line coverage (0/30)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/system_avatar_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b3903ccce90cad4a220717169a8c9d5fd2a354bdc36c9f926a72d32e089383b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/upload_gc.go: 0.0% line coverage (0/37)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/upload_gc.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb2f5dfe2933c14163fb7a66e1d21b334e9c2462fa1432dec06fed99582b3a82"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/verifybot_avatar_seed.go: 0.0% line coverage (0/26)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/verifybot_avatar_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1ffc3f0e23ddf9d2339ce9831c55409b197da3d543cc1593b4d0f431c81687f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/files/video_thumbnail.go: 4.9% line coverage (4/82)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/video_thumbnail.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b82e515579ef1726542188e61debf372f120f1fd440613813701d68e360fb37"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/livestream/rtmp.go: 0.0% line coverage (0/31)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/livestream/rtmp.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"42d28e4e011680564208d524162eccd584fb20b7e9a6de1342756d36d2ef8ccd"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/livestream/segmenter.go: 0.0% line coverage (0/179)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/livestream/segmenter.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b33118082a084af47371f003890a7eb93ad0ad70617d5bed6084eb37a273cd7"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/livestream/service.go: 0.0% line coverage (0/98)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/livestream/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"de7ecdc914b72ffb63af247fc6842da78761ef273d9099c4ca58af7e1ee9cb59"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/messages/album_group.go: 42.9% line coverage (6/14)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/album_group.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8775b5a796142fc9a853224545a70843fb656a88c16604883b0e11db94e1ab5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/messages/service.go: 39.1% line coverage (223/570)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"96bc533ebab4a5437955cf1c995bdedbb9c8309e16fc4733221d975873d50c8d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/moderation/actions.go: 40.9% line coverage (147/359)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/actions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb52f13005f09e45460c4985ba537467ac7593ca15607df80d80a2e2b5292973"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/polls/service.go: 40.0% line coverage (8/20)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/polls/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d3902d2edb34ccb429f2284416dc5c94870d75d5ee9045ed39d949b692958c9"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/premium/service.go: 0.0% line coverage (0/64)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/premium/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"66c7d6a6e5a45de825c8a35aec4357ad6e418f9c5f530f0de263b6fccb0f16ec"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/rating/service.go: 0.0% line coverage (0/243)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/rating/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a22e30fe55218a7e108ff98de7ad3100ef9263231e72ef0ca0d103a61d23424f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/rating/worker.go: 0.0% line coverage (0/43)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/rating/worker.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a816cce61538de27df9da0a956b70270dd9a4405a977965d11adcf3fcb77948e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/stargifts/animation.go: 49.6% line coverage (66/133)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/animation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f8abff77214ac630cb7fb32b584e8732b9f38089ce7caef667b214afd0d15daa"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/stargifts/local_withdrawal.go: 0.0% line coverage (0/33)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/local_withdrawal.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6de58130dcdf6149d86747ebea94c849a48b9c14021aa40289a26a8e93e80979"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/stargifts/service.go: 24.8% line coverage (170/685)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3517c021f3328251957bd47ed42ac7661b9ef5d0c735088f3525c20a75a8810a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/translation/ai_provider.go: 0.0% line coverage (0/64)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/ai_provider.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0baba4d613601e0a5667c74b55958256fdfe26f8ddd805a1fb73a11e56d15f11"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/userprojection/contact_cache_sparse.go: 0.0% line coverage (0/122)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache_sparse.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1988e30c097234c0649f9d4cec89c6bb012bdde64b58d49c51760a794a6f651"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/app/verification/worker.go: 37.2% line coverage (16/43)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/worker.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"255323ea3a88bf620d8eb949ec1d6eb7bf7902344d8d9974c7cab626ee4789a0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/botapi/rich_message.go: 47.9% line coverage (34/71)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/rich_message.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"096db30b2001f14d225fa254c7676948096d57eeecb3c4e6425a0b4b38af543f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/botapi/server.go: 45.8% line coverage (533/1163)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"34f058b5f6555e00928f5ec8b1e235dad13a712650e2427f4fcc07358dae5175"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/botapi/webhook.go: 46.1% line coverage (82/178)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/webhook.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"327213609c11e58ab6110eb5de2d6ed708c1fc0c499baa34fc5d55a0e20e3fd5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/domain/business.go: 44.4% line coverage (20/45)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"67c44e38d9a861bc032c651ecaa5120e6c81afea945ff0dcf85ecb98c4a3fb74"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/domain/channel_errors.go: 37.5% line coverage (6/16)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/channel_errors.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcf808efb63fd81197fed02f2e34c1df752ff3be49c08de7008d823c3f17a526"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/domain/donations.go: 37.5% line coverage (6/16)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/donations.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8334af82d059411421a410bdb5bdba873ff2d15dacc95cfad812cd525890ec52"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/domain/gif_catalog.go: 0.0% line coverage (0/8)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/gif_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6347ebba0862c0de05b4764bdfd51996a62f2a7fca636430e574d1250530aff2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/domain/media_refs.go: 0.0% line coverage (0/28)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/media_refs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"941609dd89acca466a4f6c59ec35adb0e6a3038e3581b642976abd7ac7a3dc39"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/domain/premium.go: 6.3% line coverage (5/80)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/premium.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"29e875156341cd294e72a224859123655348556f19d5e1e98c81bb098c53bc0c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/domain/star_gift.go: 40.0% line coverage (126/315)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d4602e50d3ea972ab5e4b835166237c2a5efd7330c01d0103e077b037fd661d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/embeddedpg/embeddedpg.go: 7.7% line coverage (5/65)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/embeddedpg/embeddedpg.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8bae9d3193023ebdedd9e72e9bc48b65e7fa05e6ac22d9f630f129664a2d7b7"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/embeddedpg/hidewindow_other.go: 0.0% line coverage (0/1)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/embeddedpg/hidewindow_other.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9430856099f15b1864f35333f6da8c3c55e9247d96baeb97860b201ce3626d8f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/hoststats/disk_unix.go: 0.0% line coverage (0/5)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/hoststats/disk_unix.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"db3629ae6b028a4dc7e23c24aa7ee576743ca8a4de3c6fa050aee4c25de04d9d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/client.go: 11.7% line coverage (11/94)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/client.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"13530d1b4bf532c933556432fafa74664e827edbbfc3cea6a20c399a0a4b917e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/mutate.go: 21.8% line coverage (111/509)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d12571e5e0cd108e61195fc884488de4eee25de91c47f4e870cb0077e869d1f3"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/process_limit_unix.go: 0.0% line coverage (0/9)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/process_limit_unix.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a0c1595298c1cefb1941b772070111dd685b842b765cb1b0a5a843ecc655090"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/provision.go: 9.8% line coverage (18/183)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/provision.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6e8f9b22f1a26400ad5642f5a0afa9e616f669c07c4ac4086768592b30bca14"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/rich_state.go: 22.5% line coverage (36/160)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/rich_state.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e4b40d69fe487222eece9efbd993ec9cad8e6199546638c57bc53e741c8341f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/rpc_retry.go: 48.8% line coverage (20/41)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/rpc_retry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff9f1113695e788f19af8fcfca2ec2b6185c1ce691a77d9ebfbe4e799c50c1df"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/run.go: 15.0% line coverage (150/1000)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cf9603f5ab3d770c8a85f72ab46e02bd2758bec8cdce63df90711f9871e9ed7"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/seed.go: 18.9% line coverage (87/461)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"74879a5a9177552124f73cd04fb7d1854ba95ecb941231a106e234b7cfe8acba"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/snapshot.go: 28.8% line coverage (136/472)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/snapshot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"862038a5a365c300ea229cbd7d80ae422cb9e542c0de3d9ab8854e6ebf0df094"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/loadharness/startup.go: 17.2% line coverage (123/715)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6878e38aa5f928feffcd8154b8e71d9783bf43068f0a3b572755d1e4ae08ebc4"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/mtprotoedge/rsakey.go: 0.0% line coverage (0/30)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rsakey.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1813d238a3c40fcc6afe84ecb74beef725c3384d4972072c514012319eb4a8f2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/otpdelivery/smtp/sender.go: 21.8% line coverage (26/119)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/otpdelivery/smtp/sender.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"15e7f1c396ca7cc74a4c95f557aed4a6569c6dd756cb24931fbf72c7209728db"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/procctl/adminurl.go: 0.0% line coverage (0/49)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/adminurl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5b1ec93f11a0cd2c56e686c316ef49f21cf31236b0a1c780233a21d7421b91fc"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/procctl/hidewindow_other.go: 0.0% line coverage (0/1)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/hidewindow_other.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1735623723003438057999bf862ddc0519b9b592922f1c3fac4e1da2bc9cf77b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/procctl/procctl.go: 44.5% line coverage (129/290)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/procctl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c7d5328f0c73a4106b8e4c3c757e3d3395b51378a3903f5cd53e688eed74d01"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/procctl/serverinfo.go: 0.0% line coverage (0/42)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/serverinfo.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b3ee85bc96c627016cff965435f765cc55a175f21a1143c257ceadb8fdcfd86"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/procctl/supervisor.go: 2.4% line coverage (6/250)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ba01ce2903e0b47d291bab4dda4a2834aedee9b1dd9abc78375c490c86fe718"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/account_business.go: 42.0% line coverage (194/462)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"554151d804ea1c0a7ae97caeafcb250618fefecec580966b9875cffa9c5349a2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/account_deletion.go: 36.1% line coverage (43/119)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3335b1f1a66e5b5a6ceb61798c45fafa5a44c522f012a961c9ee9932e963de67"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/account_freeze_worker.go: 47.0% line coverage (39/83)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_freeze_worker.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b30b5a7aa2eb83200947f81ea12404336b157930e636f8bded78ac22ea6b8fb9"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/account_reports.go: 21.3% line coverage (16/75)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_reports.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9e2800abd4d4faf24b2d58c0774555fc069ed03e3f4151efe9503322fef31fa"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/account_settings_cache.go: 37.7% line coverage (23/61)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_settings_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"da5b8b9117b9f64dc43c024ad17bb4b415aba2447e4f46ef5ffce6e47cffb1c2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/album_group.go: 46.2% line coverage (12/26)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/album_group.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8c16c9effd6f358f3d8d18748fb7463ed7294a4e0bfe6be8bf6fda7c8718d75"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/bootstrap_updates.go: 40.9% line coverage (47/115)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bootstrap_updates.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a816347fd04480b94ce4203ba2371e9acce686602d15e5c807aceabc429b2712"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/botapi_gateway.go: 29.1% line coverage (239/821)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4461450ba364c5ec755c53f6d20006c27cffd7dca43eca261b2ffda4d42eb768"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/botapi_rich_projection.go: 45.2% line coverage (159/352)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a035fffd90cdf29f7ee03a96100172dcf49d902591b3065f612bfeba54d09270"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/botapi_update_notifier.go: 40.0% line coverage (28/70)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_notifier.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a269d8f11ac2c851b3d8f54d9c1e0eb12b924ae29fd58ee8051a51f758b5ec2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/bots_errors.go: 35.8% line coverage (19/53)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_errors.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"24b0647f1d23caee8931293f410bbd43fb1ebf55a753c550bb6a81e5779b88e0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/bots_longtail.go: 40.0% line coverage (285/712)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9af6056f58d065af4d0314d7303797bac978dedc1f492bed7f8fb957beda1cda"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/channels_register.go: 36.3% line coverage (106/292)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_register.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9b721d7987975b65a5d551463f113f7adada414e3cdb0d67cee32dd37a688902"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/chatlists.go: 43.8% line coverage (189/432)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/chatlists.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a52e17b0a22073e0114debc8f249c52b5463cce417f82274d386f4fb56597dbf"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/communities_register.go: 33.3% line coverage (9/27)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities_register.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"49bb27c36bc39dc1321a0be3ab382bca85decfb0ed2a8ba3e25b881e379b9259"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/convert_business.go: 37.1% line coverage (127/342)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"70a16bb6c1e9e3057034139b9578a083d0ddd3f23dcbf64add45123c1cbfd132"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/encrypted_register.go: 44.2% line coverage (19/43)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_register.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2868bcec42f66679c9c12d95c478d27f99b0bbe81403b33e33bef4646385659f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/ephemeral.go: 22.0% line coverage (85/386)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5ed38122111acc407f3122f46c5ec07e1de6b3934dc13bf3dc5755339393250"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/expiry_dispatcher.go: 0.0% line coverage (0/66)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/expiry_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bb4e0be3097757c795627e8599eddfc6093b0ef7208b2f45453911b2989637f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/groupcall_sweep_dispatcher.go: 40.4% line coverage (21/52)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/groupcall_sweep_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f2819fed2e06ef55681f8827a374ab98d7d741e4c3d7d07f5bcd045d27fb74c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/handles_method.go: 0.0% line coverage (0/2)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/handles_method.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"beeff764f48a3336e667e7090024a7e6555992064055cd3ce331dc2c146e4592"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/messages_attach_menu.go: 25.0% line coverage (52/208)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_attach_menu.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e84b73f0e38d64ae2f2277e6eed8ffb6c2d6d34072117b83483ab7c58e6cab49"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/messages_edit_geolive.go: 49.6% line coverage (58/117)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"170983f9114fd54c3c6ebbf23f36939e0e309ed92b4762fdee2e5114a606f903"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/messages_polls_updates.go: 39.1% line coverage (68/174)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls_updates.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f363e01732d03bda293b066b43880127b9bea235d089cb99a33871cfe5ad3a41"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/messages_quick_replies.go: 27.5% line coverage (89/324)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_quick_replies.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"afd9e0046d68900b497cff551ecf5dd4d04bd34293d2d39ffe484877c8c2fa56"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/messages_reactions_lists.go: 25.2% line coverage (78/309)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_lists.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8639fbf48ba33d5e89a2d184eb9c2b270b3eb04ccf483ccf3e554ee3398c91c4"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/messages_ttl.go: 45.6% line coverage (36/79)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_ttl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e7af6e4b1838fe31f0ba80d1f09f1f1c18aa42e2dcb7e26aab6bc50eba0cd27"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/payments.go: 29.7% line coverage (92/310)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"727e0a2a57863b1ab462cd700f1134722d346467b2f94b531eb98c7c21c6498e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/payments_premium.go: 10.3% line coverage (20/195)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_premium.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9094b088f0396e74c2148ca0df5d1deb31f01aeb35bda89291cff69fbd6e8b44"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/payments_star_gift_collections.go: 0.0% line coverage (0/187)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_collections.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"61be9e88457cbe7937a242683f493323b550f2f807957b8dde6e65216c97b6a2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/payments_star_gift_lifecycle.go: 0.5% line coverage (4/886)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"93e515f2f342610fd43b48e2d364788200a058d2bd814f7ad0d286dc582496c0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/payments_star_gift_unique.go: 14.0% line coverage (48/342)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_unique.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"80dbc75c27ed04caae404abcdddfca03d6e2cd58f2f101291c4010c9d19fcad9"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/payments_star_gifts.go: 0.1% line coverage (1/1476)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b425731361a95fd84372697a38d84bf026facf36cd5852f3712479ba528fb6d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/payments_star_gifts_admin.go: 0.0% line coverage (0/65)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gifts_admin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee1aea57aaee4d3c1f50290fd10efa55fd2cf174000db3d523412a9e1727dd86"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/phone_expiry_dispatcher.go: 44.4% line coverage (12/27)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_expiry_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7925bc21a88f49957a9090d5cdc50542bfee2d7301f3c5b14e19da6afc4fab23"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/privacy_gifts.go: 0.0% line coverage (0/14)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/privacy_gifts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"508b5e717421722937fe64b956127acb8cf35fa63b5a5010e7c00190c4829866"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/scheduled_dispatcher.go: 0.0% line coverage (0/33)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/scheduled_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd980acdee0345e5e006ef87ea456aa472a55aaf13e88d2ba7415a137ba0a116"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/upload_webfile.go: 34.7% line coverage (68/196)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/upload_webfile.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec278d731d0580587c24d88a698dc64c1f88e70635fc151bb2a5382438e3f27f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/wallpaper.go: 40.8% line coverage (71/174)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/wallpaper.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d65ef93ebc7296386a704e6bcba4e187d934d2cbd73c3fc3ef44af13ea8297fd"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpc/welcome_delivery_dispatcher.go: 48.5% line coverage (100/206)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/welcome_delivery_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"892adc878d3ab69b44e5a0b7ddcc7778dcd97b45a0b709bcaee1b0eefc940199"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/rpcresult/replay.go: 36.0% line coverage (9/25)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpcresult/replay.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2410fa4aa87b513b95238e6f598015aae2a326f24dad44f5d1dd7f494df07cd9"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/delivery_effect.go: 0.0% line coverage (0/14)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/delivery_effect.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8a08d120519598d479d32165b8233ee39718e196e0718396d4c83b337b609ec"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/memory/active_channel_ids_page.go: 0.0% line coverage (0/13)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/active_channel_ids_page.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a00f11c3df46025ebf449e0d825831a96d4954721c30b24d322171fe5e649a40"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/memory/channel_polls.go: 39.0% line coverage (32/82)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9a7bbf164123eeaafa511ddf0cdcfd22c47256e60b3023387a08f6e9b47437f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/memory/dialog_list_snapshot.go: 0.0% line coverage (0/13)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialog_list_snapshot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a93dec30a1fd0fc3fce9ce22f84595ab8b06b67f30c44b138aa42b4fcb12a143"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/memory/star_gift.go: 22.5% line coverage (160/710)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5531700e75f842f4e4f72bdf3f1af7aaad9781bdbae020ecbdeb352d65723f1a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/memory/sweeper.go: 26.7% line coverage (4/15)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/sweeper.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"63fe1ae0ede0f3911703a0302b056266f3055cdfc973d89bdeb66d817a199ac0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/memory/user_cache.go: 0.0% line coverage (0/21)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/user_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad32b113a87f00cfebf3303bcfa73048183d095f78693e6b61b0444aa4d1337d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/message_pin.go: 0.0% line coverage (0/15)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/message_pin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"de833eff41995c8f999a70a4d9906e7f65c97fe978de4f2c8d1f0691c2c39d4d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/account.go: 0.0% line coverage (0/837)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bc7ed88acd5acad03ea697e5f889b492a2ea958ba57cbf37d5cfcf128df5850"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/account_deletion_notifications.go: 0.0% line coverage (0/69)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_deletion_notifications.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0e01e79c3812151fb80845ba1515451d34b657cd3e660e13ba18597bd0bfd85"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/account_lifecycle.go: 1.5% line coverage (7/464)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_lifecycle.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecc6d67ab3ade31c49fd9aa767b7614b70ce760b54b35046afc7357651b84b32"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/account_rating.go: 0.0% line coverage (0/391)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_rating.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed93b13bac995b6cb6b74260b4e2f00be529f79f92df9ac933d9fbec14525fde"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/active_channel_ids_batch.go: 43.5% line coverage (107/246). 5 more line(s) were executed in some of the 3 runs of the suite and not in others, so they are not counted as covered."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f401bbbf7b5f0446e984f66a3209f34a56f9be7dc73c154ca1233130c9bd101"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/admin.go: 0.0% line coverage (0/317)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/admin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdd61d39180903206f1236e1d980a3d1e388598f809049eaa2188ef300f8a4f4"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/ai.go: 0.0% line coverage (0/159)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ai.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca66230aae020f46cab7d1927b44ba1f864d7ecac22dee529cf31e5a48c21c00"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/album_group.go: 0.0% line coverage (0/128)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/album_group.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a0529a4036e48c6965aebf6bd644f3ee5ad11bbb45b7065d2ca9ea2e966f578"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/auth_delivery_report.go: 0.0% line coverage (0/124)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_delivery_report.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b33f2cfb219a5e108bd72db8ea315cda66533766a22307297345ea8a268054a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/auth_identity_lock.go: 0.0% line coverage (0/120)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_identity_lock.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c38227e7a59e49a99a7daa73a84e792c41d3ec62f8ed5f3a7dc8f76bcd18f0b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/authkey.go: 0.6% line coverage (2/362)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d742b54d4b8e8ea9bfc71e03a69c88d7cce1c4481044673a8c52d72bf6bc35dd"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/authkey_get_batch.go: 0.0% line coverage (0/197)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_get_batch.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bbac5afafa519ba07aff11a0b59580e7d5927f730d2a388006bf6077753cf014"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/authkey_session_layer.go: 0.0% line coverage (0/189)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_session_layer.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a25ac7a3c8e9947222e53339e18d828f079f2f131f73269ff056bc47bf1daa38"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/authkey_session_layer_batch.go: 4.6% line coverage (12/261)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authkey_session_layer_batch.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"614555da2fcea4ee304de07ab92ac9b7ea2bb9e97c8f7e818fc5a72c04dc864a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/authorization.go: 0.0% line coverage (0/458)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/authorization.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"372ec7e001a9b43f26450d5600a238d87e2c5b55970d39a603eb5af6d5b8c7a0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/blob_migration.go: 0.0% line coverage (0/71)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/blob_migration.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a25ee7994d863b55e3fed7dfd988880923b5ed325786c5add6d1fb1d0b2bc46b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/blob_storage_lock.go: 0.0% line coverage (0/49)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/blob_storage_lock.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9fcb3f4c5012ba50049e387cf24e13027fb7b73bb99a962e071913ef4099eca"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/bootstrap_update_job.go: 0.0% line coverage (0/149)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bootstrap_update_job.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a3b39685f1c5b0ac9eef3d71f7d30f7d2fecfd0ea512b9ab32f85afaae493a3"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/bootstrap_update_job_batch.go: 47.7% line coverage (102/214). 5 more line(s) were executed in some of the 3 runs of the suite and not in others, so they are not counted as covered."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bootstrap_update_job_batch.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"62079311c52f2c5a04679c08ae7140e4784d7dd00d040ac0ea737e125a26aedd"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/bot.go: 0.0% line coverage (0/395)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7759df092f16125455d298a1ad9f2b2f9c1ea382e59a137ccad3d7ae7a36bdd"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/bot_miniapp.go: 0.0% line coverage (0/472)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_miniapp.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d05673b124bc0706581471a9e22d7ed95efb4f73965c3f3637dc3d96751a75b5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/bot_verification.go: 0.5% line coverage (5/921)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"74c5603ef6905f23edf39156f72a74114d64ea5ad13f0013d03db9fe5f87534c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/botapi_update.go: 0.0% line coverage (0/620)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"852c7e4c5553869a54aa159aa3c9c1464f4578034e6d6b65a43be1afca01fef1"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/broadcast.go: 0.0% line coverage (0/290)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/broadcast.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa0f34f800059a9ead79a6a920573600c477ece37e23881f0dca56caecd79245"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/business.go: 0.0% line coverage (0/701)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cab60f5a111eda65d37dfd6523eae6dae387629d013865b2497c52fa67574e65"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_admin_log.go: 0.0% line coverage (0/137)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_admin_log.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"afecf00905b83bc7b5df475027c5d66a7d9b2c0e1e03bef07bbdb936fcbe31d7"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_boosts.go: 1.1% line coverage (5/446)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a516db37ba1aa7c38dd2e659109934afff2e7a15ece8cdceee32494c3e1568f5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_core.go: 0.0% line coverage (0/567)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"485c1cc43ff31d69c2808c3dcb9d6be341e613cad890da3cee51913d961307d0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_dialogs.go: 0.0% line coverage (0/1912)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d09536edf902f610f6d04ad2f770988598715ba87c68526dfa7c13fb41a3414"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_groupcall.go: 0.0% line coverage (0/57)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e130c2c871fcfa9e66391100b4621fb273fab6bec8e57e2de0f4bea60109c96e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_helpers.go: 0.0% line coverage (0/867)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb7170508a618532a1cda620648c1f6ee1a209195626267bb7a7ff0d12a91b06"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_history_ttl.go: 0.0% line coverage (0/69)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_history_ttl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c7939085f6f6bf5c1db946ae209f06d892da2a855ed61b1bb6444c582b18baf"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_invite_exported.go: 0.0% line coverage (0/504)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"796369e3d4aaadf80c00297f98629bb518ebbe1d79b90dbaca9d3f26da9e30b5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_invite_helpers.go: 0.0% line coverage (0/3)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4a142b234079232b9351a5e69110f540ae43d54ef0c4809b2bebf2c718dfad5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_invite_import.go: 0.0% line coverage (0/268)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f88b3d2b9452066e974e2a4c02c27a9cfd22a76110e3e74cfb2a6cd13f036c8"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_invite_members.go: 0.0% line coverage (0/123)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_members.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cce9c8b8717c54a7f21dfdf0e58863d4d1e1100dc4db6c8f1aea7f98ab70d07"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_invite_requests.go: 0.0% line coverage (0/183)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_requests.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cde9fc21f8beb54a28a77d8aeef5808f22206fecfb830a3a496e0db6bf5d5a8"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_listener.go: 0.0% line coverage (0/53)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_listener.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"493940d0e797d0864ae25a6e9a163de6709f7adaf9c703ad301898f0f2e184b9"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_member_admin.go: 0.0% line coverage (0/628)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"670749d0e2b300347a067d811ebe91059afd5e3d5a1130db250546e486d1994d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_member_helpers.go: 0.0% line coverage (0/415)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea078c09ea00dd44403f54c2f11045cdd6a14b74295fbca2b65fa020fc285a39"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_member_join.go: 0.0% line coverage (0/265)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"39419d551dd4e0f3c101493664b12ecf3f1f2bfecfbcdfbdff925250e9ea7d52"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_member_join_requests.go: 0.0% line coverage (0/150)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join_requests.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5630cd7103fef15e0d0a242626d6d49b63bd5ac1062274f26287aaff05f12bf1"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_member_list.go: 0.0% line coverage (0/398)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_list.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a1979487760de28ea3125477b4fd9a50026736519678ae93e272d171874b0c3"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_membership_batch.go: 0.0% line coverage (0/240)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_membership_batch.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"612e23013de1e96c41efc2ebdf68f3dbc85c3ae121a26749e9d6ce0351f61d94"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_message_delete.go: 0.0% line coverage (0/507)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9016a5bd581e502c54b706bea163bf3e6d85e8044d8d892455d18887fe40517b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_message_edit.go: 0.0% line coverage (0/594)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eace53dd9b16c009a76e1a5ab1e66ed8fc1a073bffceaea14563425ce259383d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_message_helpers.go: 0.0% line coverage (0/153)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8fa20c9b051b086dce74ebe2bb9b1c6bcab70949ff2d7a8a546c2e0d5e858e8"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_message_history.go: 0.0% line coverage (0/932)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a074c4ddc8c5b2185a179d7da8df53dfdbbf30312757d19e9433c3e39a68886a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_message_send.go: 0.0% line coverage (0/571)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f47ce367f6d67307d4a5488f0e58cd1543f13fc5ce725b927c8c58055dd09d4"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_message_settings.go: 0.0% line coverage (0/154)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_settings.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc6f73201d750473970e43470d57806abd8ae038220fd499e21d4f8cde06431e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_message_views.go: 0.0% line coverage (0/218)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_views.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"078e6205e3f1e1e834a42820c93912dae299c62067109c4aedd688e9c77f5581"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_monoforum.go: 0.0% line coverage (0/343)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_monoforum.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb55b896cf81bcb2093986916f9a20edbc7a53aaef814217735e0a0bd271281f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_polls.go: 0.0% line coverage (0/174)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab95bb55be18484aa6278e38a3d0dcca3e352196e6ba742fef31abf4b3660ffc"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_reaction_catalog.go: 0.0% line coverage (0/98)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb231d60c4089b850ebeb8a97d2eba068b2cf96f76c55074bd736c983bcc8505"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_reaction_helpers.go: 0.0% line coverage (0/201)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"87a572f1f2638c38b01fc5fd26f67b1d1822ed34406ea293959443c7964ad6cc"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_reaction_messages.go: 0.0% line coverage (0/489)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_messages.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b19c8568db1a81fb0c503e2c5939911a7494978e59c7d9d091d138493149ee97"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_reaction_settings.go: 0.0% line coverage (0/29)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_settings.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"011a96a3ce8c4294a6c9be221d3d5cb4c2d3a28d8f864b938007d9426dd55de3"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_reaction_unread.go: 0.0% line coverage (0/372)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eebb7a65fefef866c7808e3235444ce82aa361be43e27581152b6197486aa5a8"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_read.go: 0.0% line coverage (0/884)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d67f95f4ccfd09e0f1d7d99382300a5f7d23d073cf3eb761728d78824010b713"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_settings.go: 0.0% line coverage (0/1151)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec4919b9dcee492d751c4f6f65f7fd00a68aaeb1bf137eccd0d2eb86f7b5f1d1"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_stats.go: 0.0% line coverage (0/480)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_stats.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1b1db574ef248ac0c3d7cca7f179d97a6d2c24b3161b9d8ff9bdd9622193f3e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_store.go: 0.0% line coverage (0/49)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_store.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"09ddfce5cf9cf1036bc113066672591618cd8fa08468aca534fab34ff295f9ff"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_suggested_post.go: 0.0% line coverage (0/538)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_suggested_post.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"51ccd8f68d1e50709fc76a31d552c4564956d6c7683cc420ca04ad8028643dda"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_top_message_cache.go: 30.6% line coverage (45/147)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_top_message_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"db0408a2cbd67a0793952b66c1ae2853a22529eefd6c83f44962e83219aadd72"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_topic_read.go: 0.0% line coverage (0/182)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topic_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cd742985dd87a1c01fd8a0e5a3b219a17c7d81cf7849226726ce6b9e06c7a8f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_topics.go: 0.0% line coverage (0/923)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a70ea2030fea637bc3596747dd2ac9d6bba4810141c955d7bc9064cf8db243bc"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_update_retention.go: 0.0% line coverage (0/221)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_update_retention.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5aeddfe794fa3102cff60a330554ec205d6934d931794570c113eabf784a51f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/channel_updates.go: 1.6% line coverage (9/568)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_updates.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb62cbaf00cbf8a925ee15b90653b3dfbe981f38129c5f47a5a250a4314bb4fb"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/chatlist.go: 0.0% line coverage (0/205)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/chatlist.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6124ffcc4279aea2fdffbc194a5da92b266815a4eb3ccebd0c93d0b92f14d534"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/client_telemetry.go: 0.0% line coverage (0/120)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/client_telemetry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7af6fa2226c4a304cad4004b967972aa9b300e693e8c7b19818f44e10173f638"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/collectible_username.go: 0.0% line coverage (0/603)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5339f254def6472f8b672d3ab3c9473a3966f130344dba7798e27838a2254bf"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/community.go: 0.0% line coverage (0/1159)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2dd196ffe7d48798090934c2865ed422a92a78177f5a4eddb5da7d4fa2da4da"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/community_catalog_cache.go: 44.4% line coverage (8/18)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community_catalog_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3222ec30ee733a3f21f52fc6aa5d47a2b836c927cdcbf74b22a40d765e840719"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/contact.go: 3.3% line coverage (34/1036)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/contact.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd61f2ce800ea694c31708058dfbe18c83be5f9315dc6b02d58aaf1408e12b23"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/counter_source.go: 0.0% line coverage (0/87)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/counter_source.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d58142f98836016d4b9f46441e3eccfd0301056ea013e9bdfc61f077fcb7234e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/delivery_effect.go: 0.0% line coverage (0/13)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/delivery_effect.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d3aee217b7370ffcc22cd383838b2cc358468aeef3b60d87149cf99aa686bc2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/dialog.go: 0.0% line coverage (0/1079)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0b5677cea29ea3321703c651eb9e14d8a042e7b35016cc871d7da42cf2c5606"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/dispatch_outbox.go: 2.1% line coverage (5/239)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dispatch_outbox.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"56c067bce94c322926ec1c64b63987db6b8a012dad52fb5291577b01b9e64c30"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/donations.go: 0.0% line coverage (0/361)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/donations.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e68812e700708c586338fd28f7a7963cc8c8c21a93003bdcb28cb807df459b74"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/encrypted_queue.go: 0.0% line coverage (0/214)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/encrypted_queue.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d96e4244c22c3845d138c6a401caecc78e491fab2f42e9061e0db7ac91bf330"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/ephemeral_report.go: 0.0% line coverage (0/90)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ephemeral_report.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9158fc167b0993766f0b4810485b08a356711d352496b3c9300a7b40e1ccf571"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/gif_catalog.go: 0.0% line coverage (0/77)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/gif_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"82b2242b6ef4b191b4ca77ca81d26b0079911b4171c8f89aa223cf83a96e0371"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/giftpacks.go: 0.0% line coverage (0/60)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/giftpacks.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cadacafc2885dd834dadde9e287ab10fbd97974d11943ba2579262375e8bef90"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/groupcall.go: 0.0% line coverage (0/1092)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e24b266be9e07507c3be9a3ac6f4427bf1cd3b6e62c8b87b201e6577fcd9442"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/help.go: 0.0% line coverage (0/106)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/help.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"20cf689c9edea1662e9d2266cbb43e88577733512f3c610bdc39eada62280111"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/history_ttl.go: 0.0% line coverage (0/124)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/history_ttl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a7c1b9ed3b5b590ba60946326135119f1a46e17600082765413cc655232e3d3"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/langpack.go: 0.0% line coverage (0/378)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/langpack.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e185f35bbd01b1f1e049f0780a9193001e9c67b386d728eae399f85d148c68c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/login_code_delivery.go: 0.0% line coverage (0/259)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/login_code_delivery.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aa5c2ac5c57533fe33f21ea11c4025943e39864186cccfa43aaf6a5ec0f3e48"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/login_code_delivery_retention.go: 0.0% line coverage (0/19)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/login_code_delivery_retention.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5744d7a9d553307ca65b163905501bce2037d9ef437aeea5a22fcd10d2b074c0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/media.go: 0.0% line coverage (0/1266)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"372c4a6333dc045fdecb6dbd929b89ccf849d17f01c1f853d696ebd445cb2006"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/media_codec.go: 19.4% line coverage (20/103)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_codec.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4c17825d06acd9fa376d60907be602e2026f04ca951a08d10040dc56ae479b0c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/media_index.go: 0.0% line coverage (0/46)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_index.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"82058a9c0d76d8af827972ac017d6c7e02b48bb45562afccdfa0335a98377ff1"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/media_refs.go: 0.0% line coverage (0/280)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_refs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6247e298f3bfbf92f77a846eee12f17129bdc92503c02db4ef7185881648977d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/media_search.go: 0.0% line coverage (0/298)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_search.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1bb5ef3112f355eddbc4ec3149b089b7d0ce1a3bd3d205e37a60e898626c9e63"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_allocators.go: 0.0% line coverage (0/24)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_allocators.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"db1ebec0e23e401405992e81d5d5f6cb03fdb414f10c05383e442c773ad63c76"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_delete.go: 0.0% line coverage (0/540)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_delete.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbc3dfd68d85d3560d93c7d45703cb69d5cd2b6be0755829e003138dca72ef83"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_edit.go: 0.0% line coverage (0/265)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4a09d0b7dc1c1324b6e1a2383fce2a65ce678cd5572fe2697375456709ee812"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_forward.go: 1.9% line coverage (3/155)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"75fbce40106d9e27463d82bc65b695bb3b1aacf4b4498536bf7b0ad12e86ffae"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_helpers.go: 27.0% line coverage (70/259)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e5d118c249e0bc03fb0ef82115167f94049d19cfce0ccc87417852fccbfe6b6"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_history.go: 3.1% line coverage (34/1105)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"225295d3e8a710b3762028bcf15c8cb3d7cd1eae6a45c2ec699e0ae4c8165c35"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_no_forwards.go: 0.0% line coverage (0/201)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_no_forwards.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d0b494478f520f510578891db9a37641467bc07b827c56495c53323bb2f4c24d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_pin.go: 0.0% line coverage (0/262)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"db8a9f4fd740a84c182b0cd1351f0189c794978757d52858e694af720e4570f2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_polls.go: 0.0% line coverage (0/93)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"45fbf980852bd8c0c33faa35a16d7ca7dd813d051e37525a73693ecee833e5dc"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_reactions.go: 0.0% line coverage (0/378)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f116e1f2b2e2499aed94c5c1b0cba9b9101779bc8c3bf8b8a7331074472436a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_read.go: 0.0% line coverage (0/398)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"56f64b39a0eed79416d9cb0d610a8f1e45fc2268db3b42b8d48664486dab2e00"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_saved_reactions.go: 0.0% line coverage (0/268)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_saved_reactions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8da6c77995b5b53ae1597d339eff556be1333a5a15f8cc7eac5def5cf097d2e7"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_send.go: 0.0% line coverage (0/894)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a563ab95739d3f84cbf528fe33c3b3e45eda496491aa1a0bbdbf3953a3a764be"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_send_batch_actor.go: 22.2% line coverage (58/261)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_actor.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5ca0c695b4e85afd3fe3f7cb535dbd47e212620195f938cd86d2ee927694625"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_send_batch_sql.go: 0.0% line coverage (0/208)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_sql.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e06ff4aa3e7d21568dc915afadc652d518acc8787684581835a81a6d7867be66"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/message_send_hotpath.go: 1.7% line coverage (5/300)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_hotpath.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1228ce9b91a52a9c39dbb154405e52069e2688d8d4fb93121fc312dce1072ac3"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/moderation.go: 0.0% line coverage (0/391)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4af161f071326862e31e3ef215976ba97dd1cd70cf5b76024d4d1133c40ca5a6"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/moderation_cases.go: 0.0% line coverage (0/1156)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3123b6785203f2eab9a50602e440101df5b69d55e70d933f290edb43713aff05"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/moderation_registries.go: 0.0% line coverage (0/312)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"150105b55252f995793788e9d29961c8882805409be9dce6d0c20988ee2f11a0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/passkey.go: 0.0% line coverage (0/85)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/passkey.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dea34bd662c42a834d4be29309bf44f8bb50aab3c47a07919342618999c02cd5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/peer_username.go: 0.0% line coverage (0/195)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/peer_username.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"09e752a03240d0368b7bd43ed2f3fd732a3b0f328d56729260811925eecc0e36"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/phone_change.go: 0.0% line coverage (0/57)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/phone_change.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec331ba89257e211cddff91b1907f64595049b376f615f42f10b42ac576aadde"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/phone_identity_migration.go: 0.0% line coverage (0/104)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/phone_identity_migration.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"42a14ecf66d3a00de00ae8fbffaee83187dff172fec42f190060978950ac354b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/poll.go: 0.0% line coverage (0/333)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/poll.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"db2421dba078d332f795bcad0ab3d699ba7e745bae1f3bcbce16153239faa1fd"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/postgres.go: 0.0% line coverage (0/146)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/postgres.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f856cfa07aaa848b76a0c3b1a29fc4dd429d223cb90b4aadd73d237735676673"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/postgres_connection_admission.go: 6.8% line coverage (22/323)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/postgres_connection_admission.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"34a70e4c236b8d3c14beb15af60dac38f239c407a46513e68ee7f7359ba2f699"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/premium.go: 0.0% line coverage (0/642)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/premium.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1d6fc0efd928d61cc6abd432406fdee7e586ee6421d98523750095d53e25a60"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/privacy.go: 0.0% line coverage (0/87)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/privacy.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"613a34ffb634269f35abd7c717100c855885049a2b341afd5a9c85f43bdad61c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/read_model_versions.go: 0.0% line coverage (0/73)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_versions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5be5186c96a85b85eac4ebaf04e4b9c728a218285a5a59e1d126d05aabb22ad3"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/saved_dialog.go: 0.0% line coverage (0/362)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"86243fcf57cf9e6db82d9f2c46c5455ec6821da8a15bb67988bc7a19eaf9f844"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/scheduled_message.go: 0.0% line coverage (0/626)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d19256acb5d444c762a9fee7f2225566a0974731123909cda4dc98f7823dcad1"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/secretchat.go: 0.0% line coverage (0/109)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/secretchat.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f258324a7e9f5e4d05b7af1c13519da5933285df819a5c470a2ee55f4a3b7175"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift.go: 0.0% line coverage (0/851)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"121121cf5a502fbb85995d838458aa918b0336962a81ccd3be8227407c6a78a6"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_channel_admin_log.go: 0.0% line coverage (0/40)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_channel_admin_log.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"aff4d9255e8807d9421aa26a9af586c018c7588d179a788c1190e7a21d3ebbfb"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_channel_notifications.go: 0.0% line coverage (0/163)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_channel_notifications.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b66fdbd278ada3d002d7915a526d584b01453a35c6251f8a0e191d1f1e73c4d0"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_collectibles.go: 0.0% line coverage (0/837)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3c50271bb7d7c75c4e9ab98d9daaceafff8ddff19e627ca60a5fd8b71816263"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_craft_auction.go: 0.4% line coverage (4/1054)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_auction.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"454a2d3da4aceca5eceaa921277e81d1ed9faea3a84c0a67ba16f92502c6a555"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_craft_projection.go: 0.0% line coverage (0/178)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_projection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"514e1c2c959560d0b7b6701d0fb877d55dbcc331d55dbd658ecbd6d75d7a717c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_entitlements.go: 0.0% line coverage (0/248)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_entitlements.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9982bf9675a0071c5f7c88c3ab283cbd037db43e6be32cf506bb52d86471712b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_lifecycle.go: 0.8% line coverage (13/1552)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f14ca367b982be83b58b404e4bbdebe10475bec623fd488894acaa0d2542ff11"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_lifecycle_projection.go: 0.0% line coverage (0/160)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle_projection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1e066178537e89aaf1a22d1cea82d4d960a87d1fb51471178f5908d9742cf84f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_listing_suspension.go: 0.0% line coverage (0/45)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_listing_suspension.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d5fbaafda5e7db2069ef946327e2da51e4e09a6b1d8a44999a5881ac0ef3f3f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_private_projection.go: 48.8% line coverage (60/123)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_private_projection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9e3bc52bb6bfe17bf1a4e30e5e20df386041c4828778f626a199a0115f16f7c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_purchase.go: 0.0% line coverage (0/334)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f37b748a9d42bae262e9932726e920eabc0ee1e4c581dbac182ddc8ec93fa8cb"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_upgrade.go: 1.4% line coverage (14/1021)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bc8df5637c2f69d0d34b9fa579839f87ab296d782b559687cd4086ad090011f"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/star_gift_user_message_ref.go: 0.0% line coverage (0/52)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_user_message_ref.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a6c5dfce139738b4226b1856a01269c6804d8cf2882fc59dadc9c0b833c6b41"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/stars.go: 0.0% line coverage (0/231)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/stars.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a803b00408758d86f26314d78788576bb334c1d05889f8f09e1f5d8dca1b209e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/story.go: 0.0% line coverage (0/2213)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/story.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ed955c91ac353b1f0ef813151033ad9fe0e019c7105d111c94acf1c4060ab8a"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/telegram_login.go: 0.0% line coverage (0/906)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a2570ae7a32dff8131d9126927da835b85ce64e586f97cb28a6ec27e293c25e"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/temp_auth_key.go: 0.0% line coverage (0/80)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/temp_auth_key.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"95b5674e1c06b1c66ab899637e49b95710d26bc09ba4797bdb03aa1c7890c8e4"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/themes.go: 0.0% line coverage (0/174)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/themes.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c59488536f4604779f70e65948d71d840763ed18510814ca863f729023932316"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/tmp_password.go: 0.0% line coverage (0/50)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/tmp_password.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd6104f2aa8fd7e1b86ce1e95e3a64b7a33ff00509d0b05f64df5cdd80f66e50"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/trace.go: 0.0% line coverage (0/12)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/trace.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9705c6c34366dfec3f8093a0d95c9523df2c22cf05936409861d6ac52c3ae9e1"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/update_event.go: 1.2% line coverage (11/946)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ed1fff804ec65f5adebac151c339829549366908f7d284f4a4a77f154221ee4"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/update_event_retention.go: 0.0% line coverage (0/235)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event_retention.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3ec30aa3152154f5e44fdbc68857fabc0bb70ac8a9e66505bdcf2b7245e1d76"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/updatestate.go: 36.6% line coverage (26/71)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/updatestate.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"354698b3e42dcce82a355636784ee3aab1a4140a12dc062b0aee60d8cd9c2d9d"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/user.go: 1.6% line coverage (13/791)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"536c1d38c4df3c6263f5d1c5c107be643aabdd783d748f023d16a692b5f9f428"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/user_pts.go: 10.7% line coverage (6/56)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/user_pts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"83aaff7c380e505cd7ce04dce46040a9ec1e790f0f6b3f1c7cc2a94451650205"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/verification.go: 0.5% line coverage (5/951)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b88767da6969553dbd643a1fee72fe0063207c342be4c17edcee72040cc8430b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/web_page.go: 0.0% line coverage (0/31)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/web_page.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"860a54db652dfc47903fdf90b9ed6833c09be3918c02f70c85ad618f0ee6343b"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/welcome_message.go: 0.0% line coverage (0/278)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"314d8f463027b34998a5292990df6ca129910101a79a007e31493e439905465c"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/store/postgres/welcome_message_delivery.go: 0.0% line coverage (0/246)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/welcome_message_delivery.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b79befacc7f7f034323ec85d10b1ffbca639e79ef33f5cfdd263b607be1acf2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/turnsrv/turnsrv.go: 0.0% line coverage (0/83)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/turnsrv/turnsrv.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0a540c8bbcd34c98b48800b17083baa85073e837c14ccb2c87374f7256d87a2"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/updatecdn/server.go: 45.1% line coverage (65/144)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/updatecdn/server.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"821cb5240a28a96a7fc64d2a7d45bc3691239cda87fd83ad4bfc48b4db0ceed5"}},{"ruleId":"D8","level":"warning","message":{"text":"Low coverage: internal/web/assets.go: 30.8% line coverage (4/13)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/web/assets.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"04224b0f5b9401d4c74acdd8801682a0b01d6bb21a7b9b259ba283105e757817"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/app/langpack/service.go: 2 line(s) (252-253) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/service.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"da95fc01c5aef28f1c2ab6a847c4bd6bf03172e66eaf8216b45d80120b253b5c"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/app/telegramlogin/service.go: 2 line(s) (967-968) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":967}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd22a0d7109d073531b7bebef647d34cbf02008cd2d20075125642e8aadefdce"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/hoststats/cpu_unix.go: 5 line(s) (38-41, 47) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/hoststats/cpu_unix.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"4034d5e906fc235c566827f04de00b9e1af42bdd0119f42828382a3eaf2d9b0d"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/mtprotoedge/exchange.go: 2 line(s) (122-123) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/exchange.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"504d11c560095eab9cd71d02268be3673e75aaab65e83d19e2d91cfbc9ba76f8"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/mtprotoedge/inbound_preflight.go: 14 line(s) (970-971, 974-975, 987-988, 996-997, 1015-1016, 1055-1056, 1063-1064) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_preflight.go"},"region":{"startLine":970}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4be3065fef45d1379d4fe52914f7ff2d20a3d15a44e84ae92313d62a11a40a1"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/mtprotoedge/layer_rpc_execution.go: 20 line(s) (172-178, 181, 290-295, 298-301, 303-304) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/layer_rpc_execution.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"76d0c18a6cd4bb71f38f5eb3e31fd24779d074fcd54563fc89069cde5f61aebd"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/mtprotoedge/outbound.go: 21 line(s) (1205, 1634-1636, 2111-2117, 2185-2187, 2189-2191, 2893-2894, 2971-2972) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1205}}}],"partialFingerprints":{"codehealthFindingId/v1":"16285436488687cd4ea3be89c971a1a1d28aac6a1a7578572329ec8ad70de25b"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/mtprotoedge/same_port_mux.go: 8 line(s) (187-190, 210-212, 386) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/same_port_mux.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"8f13bd8e6face09c6cfcc775476d9b06a36a61c6b2f2cc645bc06a39f268ea01"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/mtprotoedge/server.go: 2 line(s) (1145-1146) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":1145}}}],"partialFingerprints":{"codehealthFindingId/v1":"522416f975af52dec2544641bd58d03547b6e9ae1a5c8accc3f4bc6a92e90b66"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/mtprotoedge/session_manager.go: 5 line(s) (422, 1502-1504, 2043) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/session_manager.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc8c0d3ca123b6b3c52cd3097db8455b738418ce214ded9e17ad801be25c25a5"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/mtprotoedge/transport_compat.go: 2 line(s) (305-306) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/transport_compat.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6a952372ebc57b8fad595315a58a291bcceac7fd08aa7082c0966f8e3f82258"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/readmodelcache/cache.go: 2 line(s) (173-174) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/readmodelcache/cache.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"553ef3086c5301f49bc154de360f8185bcc1e26aefbccb8970c3a1faa896e1ea"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/rpc/presence_last_seen_batch.go: 2 line(s) (189, 271) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence_last_seen_batch.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"8da44bf7b2c4be31bb191ae989fd0f4bdfa715148f536ea8f28c6f08ac0f8a0d"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/store/memory/moderation.go: 1 line(s) (930) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":930}}}],"partialFingerprints":{"codehealthFindingId/v1":"08113a12d4d0f77fcd5c34102c8fc26d677b7c42e2ebfcba5fcabf020c7059ac"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/store/postgres/active_channel_ids_batch.go: 5 line(s) (263, 271-274) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"82f25b4a6a99295927f1fccc22eb7a034dc3fe85078b2664c3d67526884744d8"}},{"ruleId":"D8","level":"note","message":{"text":"Tests reach code only in some runs: internal/store/postgres/bootstrap_update_job_batch.go: 5 line(s) (289, 297-300) were executed in some of the 3 runs of the suite and not in others. A test that does not take the same path every run only tests the part it always takes, so these lines are not counted as covered. Make the tests that reach them deterministic (a fixed clock, seed or ordering, or waiting on the event instead of on time), or test the paths directly."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bootstrap_update_job_batch.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6c220aeeed887e708175355a18608b2e8a6791a04372233f581fc506083721c"}},{"ruleId":"D12","level":"warning","message":{"text":"Dependency pinned to a stale untagged commit: github.com/jackc/pgerrcode: Direct dependency \u0060github.com/jackc/pgerrcode\u0060 is required at \u0060v0.0.0-20220416144525-469b46aa5efa\u0060 in go.mod \u2014 a pseudo-version, which pins an UNTAGGED commit from 2022-04-16, 4.6 years ago. The pin itself is exact, so this is not a reproducibility defect, and it is not a claim that the module is unmaintained. What it says is that this repository tracks no RELEASE of \u0060github.com/jackc/pgerrcode\u0060 and has not moved this requirement in 4.6 years: every fix the module has published since that commit \u2014 including any security fix \u2014 is absent from this build, whether the module went quiet or moved on without you. Check whether \u0060github.com/jackc/pgerrcode\u0060 now publishes tagged releases and move the requirement to one; if it publishes none, re-pin to a current commit."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"1ca721b0924e7be900e4085f911d1356c312867dfd6f9592d2f6b9eee597f4a4"}},{"ruleId":"D13","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"2b2c5feb05b26ed248bddbf2767d853c2f0767d0703e7fb89561046ab4c8222c"},"taxa":[{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A07:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D13","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ff423a76bf64705eb0a7e894adb6208053dd2c34e776953258bc1ff02429f524"},"taxa":[{"id":"CWE-259","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-798","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A07:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: cmd/telesrv/main.go: cmd/telesrv/main.go changed 37 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 136 in main.run at line 600. 14 of those changes were fix/bug commits, and the other 23 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- cmd/telesrv/main.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":600}}}],"partialFingerprints":{"codehealthFindingId/v1":"6dd5da3e3c1835cb6144fffa54238fcbb3c88153dd0b50b5c2874fc55941ad71"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/config/config.go: internal/config/config.go changed 24 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 109 in config.Load at line 958. 10 of those changes were fix/bug commits, and the other 14 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/config/config.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":958}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc13cc9df78dffd7f9663d3d6315b5a7b6a30ad2cf7851b5452a6dd3ec33be7d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/messages_register.go: internal/rpc/messages_register.go changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 105 in Router.registerMessages at line 15. 4 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/messages_register.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_register.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"c59b8d7b11e675e0fe34f16489f5e19a46572f6a44979cf8a9dfe3562c425230"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/admin/service.go: internal/admin/service.go changed 18 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 32 in Service.Configure at line 662. 8 of those changes were fix/bug commits, and the other 10 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/admin/service.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":662}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e64823066fd2de4e5fcea5e92fe18fc18d083e194aa8b1296af7cd84756ab16"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/messages_send.go: internal/rpc/messages_send.go changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 48 in Router.sendSingleSendMessage at line 394. 2 of those changes were fix/bug commits, and the other 4 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/messages_send.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":394}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd6c75f630b15f1d09e9ffad87b947caf4b6e04717a04e4da69782751ab1bbca"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/convert_messages.go: internal/rpc/convert_messages.go changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 40 in rpc.tgMessageServiceAction at line 134. 4 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/convert_messages.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_messages.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"3e2637ea0b0a5b0cc92f878c817db133130364960df22fc897c7d22a1737e2fb"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/users.go: internal/rpc/users.go changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in Router.buildUserFullProjection at line 310. 2 of those changes were fix/bug commits, and the other 4 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/users.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":310}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce5c5c242385ad5b7308c03cbabd7cdc634dae4d7227993945697e9ee071f8e7"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/mtprotoedge/server.go: internal/mtprotoedge/server.go changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 33 in Options.setDefaults at line 383. 2 of those changes were fix/bug commits, and the other 5 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/mtprotoedge/server.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/server.go"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"0371e30e7aa83da358e6deb9bacd4f451e689dc7e2f08bac578f3518ed00560f"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/message_send.go: internal/store/postgres/message_send.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 96 in MessageStore.sendPrivateTextOnce at line 171. 1 of those changes was a fix/bug commit, and the other 1 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/message_send.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"670582f13beeaa6e155e799f13036a0673e9a238e38bcb5395d3109b7fc0308b"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/message_edit.go: internal/store/postgres/message_edit.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 74 in MessageStore.EditMessage at line 13. 1 of those changes was a fix/bug commit, and the other 1 changed it for other reasons \u2014 this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one \u2014 a file this often edited pays the complexity back every time. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/message_edit.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_edit.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a5805f03424c6c8c4f723db9051d27f815a4be597d37345e7c191f9d5267f7e"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/star_gift_upgrade.go: internal/store/postgres/star_gift_upgrade.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 70 in StarGiftUpgradeStore.UpgradeStarGift at line 344. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/star_gift_upgrade.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":344}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4e9265c1f6ec249f2a26a8e8c13dc0e90542d9791b234ef3a858f3721f3a3ae"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/mtprotoedge/encrypted.go: internal/mtprotoedge/encrypted.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 46 in Server.handleEncrypted at line 121. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/mtprotoedge/encrypted.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"a632f4ba0e8961322b7838f3ab6b7147f518e319c1318f59a092ef0c9d87776a"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/convert_channels_core.go: internal/rpc/convert_channels_core.go changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 33 in rpc.tgChannelFull at line 545. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/convert_channels_core.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e6be59548a42ddea83a68013c392ce3708a16b47d09bbf73e5cd99c725b6538"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/star_gift_lifecycle.go: internal/store/postgres/star_gift_lifecycle.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 64 in StarGiftLifecycleStore.PurchaseResaleStarGift at line 524. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/star_gift_lifecycle.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":524}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf8b948790a35f0718bbba03d5dcb5013cf7b7be7cc1b633fec656a7b84b0348"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/bots_inline.go: internal/rpc/bots_inline.go changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 30 in Router.onMessagesGetInlineBotResults at line 46. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/bots_inline.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"c31bbb9bfc4c516a2218676108a9efbc58e602b8c4537977093910770b667b6c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/messages_history.go: internal/rpc/messages_history.go changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 26 in Router.messageFilterFromSearchRequest at line 834. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/messages_history.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":834}}}],"partialFingerprints":{"codehealthFindingId/v1":"83af95ea8c2b233aad72a2a5dcf01f50960cbabe0b804dd56a795274a0e962af"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/app/files/seed.go: internal/app/files/seed.go changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 26 in Service.importDocument at line 406. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/app/files/seed.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":406}}}],"partialFingerprints":{"codehealthFindingId/v1":"82330a43f60250414c80d321193d1c9dc8bf5ea72ad7e6ef0159b214f2846f33"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/login_code_delivery.go: internal/store/postgres/login_code_delivery.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 33 in MessageStore.DeliverLoginCodeMessage at line 43. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/login_code_delivery.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/login_code_delivery.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"e04915661516b225c5f956a6f176a6b3a1f5c4dbd1a9fef12f10c3c8b7663524"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/app/files/retention.go: internal/app/files/retention.go changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in Service.DeleteBlobBytesForMediaOlderThan at line 192. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/app/files/retention.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/retention.go"},"region":{"startLine":192}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba0427f8164ad151c83f296193f6d28c5ef27584a20483aa5a6145066068388f"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/layer_dispatch.go: internal/rpc/layer_dispatch.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 26 in Router.DispatchAdmitted at line 254. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/layer_dispatch.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_dispatch.go"},"region":{"startLine":254}}}],"partialFingerprints":{"codehealthFindingId/v1":"54dc1b8ecd13a21c6789237cac107f9c6b0832adf3b9e9bee082e53995bea518"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/channel_member_admin.go: internal/store/postgres/channel_member_admin.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in ChannelStore.EditChannelAdmin at line 10. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/channel_member_admin.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5aecae63880ccec2ceeef4a935e1d559f24bde65f535c10ed990b07fbf9d28e"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/channel_invite_members.go: internal/store/postgres/channel_invite_members.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 38 in ChannelStore.InviteToChannel at line 10. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/channel_invite_members.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_members.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"37c44cd2e0c688bafbecf3af1ee240b0982340876ce5c18c54ed342d7cafd60c"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/channel_helpers.go: internal/store/postgres/channel_helpers.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 37 in ChannelStore.resolveChannelReply at line 808. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/channel_helpers.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":808}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7e5017e46c8398c98b3d26e969ee51e68e41d240c346b7f5cfffe9f69fbf2bc"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/channels_core.go: internal/rpc/channels_core.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in Router.onChannelsGetFullChannel at line 143. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/channels_core.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":143}}}],"partialFingerprints":{"codehealthFindingId/v1":"c542c4cee78e0404ec2b60ef3951c1ad7799b25c1b0dc3861baab872803ab2c5"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/star_gift_collectibles.go: internal/store/postgres/star_gift_collectibles.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in StarGiftStore.PublishCollectibleRevision at line 45. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/star_gift_collectibles.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_collectibles.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e595c7f0472bbb1b59fa4765cc7fffe21c4f079502d35bb10c7e0fa58c37fb4"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/mtprotoedge/layer_rpc_execution.go: internal/mtprotoedge/layer_rpc_execution.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in Server.handleAdmittedLayerRPC at line 237. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/mtprotoedge/layer_rpc_execution.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/layer_rpc_execution.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"eba5bdf4e334667cdf90b3400ffe89e753e4e3e5351be3c0140bb849aa94cc0f"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/channel_member_join.go: internal/store/postgres/channel_member_join.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 33 in ChannelStore.JoinChannel at line 14. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/channel_member_join.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4dc76424faae3ed81c6d8e4ab22febcae529a530baadb17724a1aeb48509798"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/update_event.go: internal/store/postgres/update_event.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in UpdateEventStore.BatchByCursor at line 530. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/update_event.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe6ac051a1f02fbb942513b2dba954cc930342a9010d39ab5c33b0c8c18a0d7a"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/premium_sweeper.go: internal/rpc/premium_sweeper.go changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in Router.NotifyUserModerationFlagsChanged at line 102. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/premium_sweeper.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/premium_sweeper.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d3f03c6e75d7cd9139e3e8401ad2fdfab3a5308e7aada09bc42fa35f46d811d"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/procctl/supervisor.go: internal/procctl/supervisor.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in Manager.Run at line 97. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/procctl/supervisor.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"bce59ae820cc3585844ca91d2b1d3f29f17f89bf5ee2682d30fc992757290bd8"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/mtprotoedge/outbound.go: internal/mtprotoedge/outbound.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in Conn.enqueueEncodedDeliveryReserved at line 1678. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/mtprotoedge/outbound.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1678}}}],"partialFingerprints":{"codehealthFindingId/v1":"054b4ce3461e0a30237186f406f5b30f27f825501c0ca23379da581261d5e544"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/account_lifecycle.go: internal/store/postgres/account_lifecycle.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in AccountLifecycleStore.ExecuteAccountDeletion at line 121. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/account_lifecycle.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/account_lifecycle.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"f47e39974a88b15a777bfeccd2f4a194c1faa5a1c5c7b0f7f4202b3ee4eef6d9"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/channel_invite_import.go: internal/store/postgres/channel_invite_import.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 27 in ChannelStore.approveInviteImporterTx at line 111. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/channel_invite_import.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":111}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f9efe3896b9237ad231efa9a8f0e111607a0183f92dd586761e0350bde57891"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/account_deletion.go: internal/rpc/account_deletion.go changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in Router.onAccountDeleteAccount at line 29. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/account_deletion.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_deletion.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"0566844f6915924ef31227b3d96631821731fdfb04e2ee64dcf004baf3121d79"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/message_history.go: internal/store/postgres/message_history.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in MessageStore.ListByUser at line 80. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/message_history.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_history.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"a59b360741038e66bf0e1b6ff784ee994704fb9aec81aa8687a5a1104eabab69"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/app/messages/service.go: internal/app/messages/service.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in Service.SendPrivateText at line 129. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/app/messages/service.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/service.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"a423db9b8622d6249a2459d4ac00845d802d695a887bec76e74c3a3349c50854"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/rpc/update_peer_refs.go: internal/rpc/update_peer_refs.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in rpc.collectChannelMessagePeerRefs at line 416. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/rpc/update_peer_refs.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":416}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9fd99ae7b0a453afd865443902b4d166015076913618811e31f62473f85e667"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/store/postgres/dialog.go: internal/store/postgres/dialog.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in DialogStore.listByUser at line 41. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/dialog.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dialog.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4fb21d00693e18dc6b47e83ef5801a9a24eba27690750acc5c1a38c26e975dd"}},{"ruleId":"D15","level":"warning","message":{"text":"Hotspot: internal/app/giftpack/import.go: internal/app/giftpack/import.go changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in giftpack.Import at line 63. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/app/giftpack/import.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/giftpack/import.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"a89fe768c879c29b1aca3d45acd8117e5545784bdb62b3600ed3dcf7fd118bff"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: internal/store/postgres/media_refs.go: internal/store/postgres/media_refs.go changed 6 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is postgres.removeMediaReferencesByKeyTx at line 66), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix for deleted file metadata\u201D; \u201Cfixes and ui improvements\u201D; \u201Cfixes for storage managament\u201D; \u201Cfix for retention logic\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/store/postgres/media_refs.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_refs.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"e90cd1ee3060be02bdb3ae0efd0c8a353cd143c0aa183766c5667d7b63272856"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: internal/domain/system.go: internal/domain/system.go changed 7 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is domain.SystemUserByID at line 440), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfixes\u201D; \u201Cfix\u201D; \u201Cmerged with fixes\u201D; \u201Cfix\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/domain/system.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/system.go"},"region":{"startLine":440}}}],"partialFingerprints":{"codehealthFindingId/v1":"5cfcc0fdc6e8a912b0aa3bc47e9955cc09e3488f809e322ae5fcd9cec440dd83"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: internal/app/donations/service.go: internal/app/donations/service.go changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 11 (its worst body is Service.validateToken at line 410), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix\u201D; \u201Cfixed crypto donations\u201D; \u201Cfix\u201D; \u201Cfixes\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/app/donations/service.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/donations/service.go"},"region":{"startLine":410}}}],"partialFingerprints":{"codehealthFindingId/v1":"17e181facc0ee05b46bbf15172bd781fbf94ae3e941148250814505aff3bb192"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: internal/app/files/gif_admin.go: internal/app/files/gif_admin.go changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 13 (its worst body is Service.AdminUploadGifMaterial at line 44), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfix\u201D; \u201Cfix\u201D; \u201Cfix for gifs auto-catigorisation\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- internal/app/files/gif_admin.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_admin.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"51f37d7b302bfe06d5a112186a1722479431d22f9bdbf981dca5cdf3698b4258"}},{"ruleId":"D15","level":"warning","message":{"text":"Repeated repair: cmd/telesrv-admin/donations.go: cmd/telesrv-admin/donations.go changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file\u0027s churn. Its max cyclomatic complexity is 9 (its worst body is server.handleDonationDepositsAPI at line 69), AT OR UNDER the 15 threshold, so this is deliberately not filed as a churn \u00D7 complexity hotspot \u2014 the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: \u201Cfixed donations disable logic\u201D; \u201Cfixed crypto donations\u201D; \u201Cfixes\u201D. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-08-07..2026-11-05, the 90 days ending at the analysed commit. Reproduce with \u0060git log --since=\u00272026-08-07 12:40:50 \u002B02:00\u0027 --until=\u00272026-11-05 12:40:50 \u002B02:00\u0027 --full-history --no-merges -- cmd/telesrv-admin/donations.go\u0060: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each \u2014 a difference of several commits on a file whose history was re-landed or reverted inside the window."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/donations.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba45d8cc5ef1723b55752bc8336f8ca7953d272c8f59915da04595b409733558"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #1: If anonymized user #1 becomes unavailable, 46 significant file(s) lose their only recent owner: internal/app/files/retention.go, internal/admin/star_gift_catalog.go, internal/store/postgres/donations.go, internal/store/postgres/media_refs.go, internal/app/donations/service.go, cmd/telesrv-admin/star_gift_catalog.go, internal/procctl/procctl.go, cmd/telesrv-admin/security.go (\u002B38 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"c32246c444e6bb621b7db44ecadcba5c6c6322785a64e85de5142c7c97ebcadf"}},{"ruleId":"D16","level":"note","message":{"text":"Off-boarding risk: anonymized user #2: If anonymized user #2 becomes unavailable, 20 significant file(s) lose their only recent owner: internal/botapi/server.go, internal/store/postgres/contact.go, internal/telegramloginhttp/handler.go, internal/botapi/projection.go, internal/botapi/inline.go, internal/store/postgres/authkey.go, internal/rpc/communities.go, internal/domain/message_markup.go (\u002B12 more). Pair on, review, or document these before any departure."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"5fb86d89f17272ddc3df455d60bf58b042146545d76c67ee0dfc138189128090"}},{"ruleId":"D16","level":"note","message":{"text":"Further sole-owners (lower concentration): 1 other contributor(s) are each the sole owner of a small amount of code below the off-boarding threshold \u2014 folded into the bus-factor score and metrics (68 single-owned of 819 analysed files in total, counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated, example/demo and scaffolding-template trees and test files identified by path convention, largest first; 819 of the 1037 production source files in this repository met that bar). They are anonymized user #3 (2 file(s)) \u2014 spread or document their files in the same way, at lower priority than the named off-boarding risks above. The files folded here: internal/rpc/account_themes.go, internal/store/postgres/channel_message_views.go."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"6eac528f2429e724e1a97ed868f79eefbcf1888dab4af9a9e673429369bb5b2f"}},{"ruleId":"D17","level":"warning","message":{"text":"TodoComment: // todo-\u003Etodo \u4E14\u6B63\u6587/entities/markup \u4E0D\u53D8\uFF0C\u907F\u514D\u666E\u901A\u6D88\u606F\u8D8A\u6743\u7F16\u8F91\u3002 \u2014 source code is not a task system: move the work to your tracker and leave a reference instead (e.g. \u0060// REF: #123\u0060), so the task is planned where tasks live and the ticket links back to the code."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message.go"},"region":{"startLine":598}}}],"partialFingerprints":{"codehealthFindingId/v1":"41303c1eda016b975c84f39e15b898bb4de743c2f5b8312ef2c36a2370f866a6"}},{"ruleId":"D20","level":"note","message":{"text":"No ADRs found: No ADRs found. No recognised ADR directory (\u0060docs/adr/\u0060, \u0060docs/decisions/\u0060, \u0060adr/\u0060, \u0060docs/rfcs/\u0060, an \u0060ADR0001/\u0060 folder, or their siblings) exists anywhere in this tree. What was searched, so you can tell an empty log from a search that missed one: every directory under the tree (build output, dependencies and VCS metadata excepted), for a document that is either any non-index page inside a recognised ADR directory, whatever its name and however deeply nested (\u0060docs/adr/use-postgres.md\u0060, \u0060docs/adr/2024/0001-x.md\u0060); or a file anywhere whose name is ADR-shaped (\u00600001-use-postgres.md\u0060, \u0060adr-012-caching.md\u0060); or, when neither turned anything up, a document carrying the decision-record signature (an \u0022Architecture Decision Record\u0022 heading, or Status / Context / Decision / Consequences as section headings). A decision log that clears none of these \u2014 unnumbered files outside any recognised directory, without those headings \u2014 is not seen by this check and this row is then wrong. If that is your case, say so rather than renaming anything; otherwise, consider recording architectural decisions in \u0060docs/adr/\u0060. ADRs are expected here because \u0060cmd/walletminiapp/main.go\u0060 makes this repository a deployable product (line 6)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":6}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf850591aa2e2a1316fa09fb4a270d7b2c03aba22723187a314f7a4f4c7a2278"}},{"ruleId":"D21","level":"note","message":{"text":"\u0060defaultBulkACKWindow\u0060 spells \u0060ACK\u0060 where 38 names in the project spell it \u0060Ack\u0060: 38 of 39 names in project telesrv spell the token \u0060Ack\u0060 (38 of 39; unit: names in project telesrv containing \u0060Ack\u0060). Peers: mtprotoedge.sendQuickAckIfRequested (internal/mtprotoedge/encrypted.go:311); mtprotoedge.clientQuickAckToken (internal/mtprotoedge/encrypted.go:338); Server.sendAck (internal/mtprotoedge/encrypted.go:1476); mtprotoedge.isUnencryptedMsgsAckFrame (internal/mtprotoedge/exchange.go:233); mtprotoedge.inboundFrameCodecQuickAckAbridged (internal/mtprotoedge/frame_budget.go:102). Rename to \u0060defaultBulkAckWindow\u0060. [rule N6]"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"eeaef58767fa0a4d977671aa21d46e1f605647b19dc36d4c4e799879c30d154c"}},{"ruleId":"D21","level":"note","message":{"text":"\u0060registerAiCompose\u0060 spells \u0060Ai\u0060 where 77 names in the project spell it \u0060AI\u0060: 77 of 78 names in project telesrv spell the token \u0060AI\u0060 (77 of 78; unit: names in project telesrv containing \u0060AI\u0060). Peers: main.newAIComposeOptions (cmd/telesrv/main.go:163); ai.ProviderKindOpenAIResponses (internal/app/ai/provider_http.go:23); ai.ProviderKindOpenAIChat (internal/app/ai/provider_http.go:24); HTTPProvider.composeOpenAIResponses (internal/app/ai/provider_http.go:149); HTTPProvider.composeOpenAIChat (internal/app/ai/provider_http.go:191). Rename to \u0060registerAICompose\u0060. [rule N6]"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/aicompose.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"659bfd26b02fc26bb21f490cb7fc2dc4b6270fc68fb10bcefebc98313794d815"}},{"ruleId":"D21","level":"note","message":{"text":"\u0060DeliveryEffectAccountPTS\u0060 spells \u0060PTS\u0060 where 70 names in the project spell it \u0060Pts\u0060: 70 of 72 names in project telesrv spell the token \u0060Pts\u0060 (70 of 72; unit: names in project telesrv containing \u0060Pts\u0060). Peers: Service.MaxChannelPts (internal/app/channels/service.go:2342); Service.MaxChannelPtsBatch (internal/app/channels/service.go:2351); Service.currentPts (internal/app/updates/service.go:816); BotAPIUpdate.SourcePts (internal/domain/botapi_update.go:152); EnqueueBotAPIUpdateRequest.SourcePts (internal/domain/botapi_update.go:165). Rename to \u0060DeliveryEffectAccountPts\u0060. [rule N6]"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/delivery_effect.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"8225228f05a9a295d774efc5adac71b4fda75a62fd913dcd6d55827714d42377"}},{"ruleId":"D21","level":"note","message":{"text":"\u0060AccountPTSDeliveryEffect\u0060 spells \u0060PTS\u0060 where 70 names in the project spell it \u0060Pts\u0060: 70 of 72 names in project telesrv spell the token \u0060Pts\u0060 (70 of 72; unit: names in project telesrv containing \u0060Pts\u0060). Peers: Service.MaxChannelPts (internal/app/channels/service.go:2342); Service.MaxChannelPtsBatch (internal/app/channels/service.go:2351); Service.currentPts (internal/app/updates/service.go:816); BotAPIUpdate.SourcePts (internal/domain/botapi_update.go:152); EnqueueBotAPIUpdateRequest.SourcePts (internal/domain/botapi_update.go:165). Rename to \u0060AccountPtsDeliveryEffect\u0060. [rule N6]"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/delivery_effect.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a6a3b38cb9fb38ca0e4a9f3499a4f28db9bfe7bcbda13396ef343e22ccf1f3a"}},{"ruleId":"D21","level":"note","message":{"text":"\u0060nextBID\u0060 spells \u0060BID\u0060 where 12 names in the project spell it \u0060Bid\u0060: 12 of 13 names in project telesrv spell the token \u0060Bid\u0060 (12 of 13; unit: names in project telesrv containing \u0060Bid\u0060). Peers: domain.MaxStarGiftAuctionBidStars (internal/domain/star_gift.go:289); StarGiftAuction.MinBidAmount (internal/domain/star_gift.go:689); telesrv/internal/domain.StarGiftAuctionBidLevel (internal/domain/star_gift.go:704); StarGiftAuctionUserState.MinBidAmount (internal/domain/star_gift.go:714); telesrv/internal/domain.StarGiftAuctionBidRequest (internal/domain/star_gift.go:727). Rename to \u0060nextBid\u0060. [rule N6]"},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/broadcast.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"95347c83048ebd7ff796b4f1c48995d35767624832237956098ac6c52edd4393"}},{"ruleId":"D26","level":"note","message":{"text":"Projects may be oversized for their cohesion: \u0060(repository root)\u0060 (345999 LoC, 2069 module-visible types across 114 directories) overshoots its size bounds. 1 of 3 build unit(s) (Go, Python) overshoot their size bounds, lowering Project Cohesion to 3.3/10. Review these for cohesion \u2014 draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"go.mod"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d39784e8a78933b908507d20b4610b78a7f819ed418525c8adae26ae57410589"}},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f244c80a1452c943fe738ee013651b886c3a7d0ef6673ad4ada558d042b4c983"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b722aa84dea2287d227b8a4dde41958c27fbd67149cefbbd7d0718533b7cc8a0"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"95ba4c04bac469ae87852dd67f75e71aeb412a4a03b9c476022d5aeb20470f8a"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"36279f886b837e8a61ff2fcf65dd81f0303b7bb0ed6abcdb7349752944648bcf"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"f5f0deab50fde0e269b440e9eaf40a9167b8b02d6adb63737f7504253351dc9a"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"dc1c0356c11d95ce9652abe0ecf9e2f01b818d009ce57c365dbb72260db792bc"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"8b66c6fbc69f91a3983a5a9b2fc5cadaab5471681cc45e9e057f0c6261236cee"},"taxa":[{"id":"CWE-89","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"189b63a723f5feac2f7927b95a7f8a9b09bba2845e612fb54180108d5bd48aee"},"taxa":[{"id":"CWE-400","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"4caf891e5ae4d1fa46a2d49c4704b2045122ca8fcf02ca0633d4547b6fdd9040"},"taxa":[{"id":"CWE-328","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1b7f44da8fc829e10d88753340d18272cca8fc3e0f9f9822fe896733faa8683d"},"taxa":[{"id":"CWE-338","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1ab03d6a12f19705020203b019c7e61672f1c45352f01c7256c91b50ade8a4da"},"taxa":[{"id":"CWE-391","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-703","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A10:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"de82016ce262e1af7b404c8200ae90b5428212f09c93bf153389e5f78f5d057d"},"taxa":[{"id":"CWE-248","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-704","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A10:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"fab0feb2b69e9687e2764a5b509c961e083e41705b36b8d8bf63487c1e8ed2d9"},"taxa":[{"id":"CWE-328","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b4d4886a6315f91dadf65b9044de8e55dc92c88927c692be7e10d16dbb30b178"},"taxa":[{"id":"CWE-391","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-703","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A10:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d193b6f09cc30cbb43e216e35f4e508699db7d36e3546aaa3a6f1c262ad065ba"},"taxa":[{"id":"CWE-391","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-703","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A10:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"df107902d87d9ba32e973811c8f603ff6ab003e81935f0ab2a081b6512010242"},"taxa":[{"id":"CWE-665","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-908","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A06:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"3e0f264074d33bb3ac2d2fe9d400eac76cc9237e691189fdd48ce8ef8c710cd7"},"taxa":[{"id":"CWE-665","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-908","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A06:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"e28642bc7240a0fa5909c5816199ae2a86ac3c94798c66b3dac79f1b18f823b8"},"taxa":[{"id":"CWE-338","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"94bfb07a1a982bf08ae25e26fb05a3903cb0999329437677a04b5f98305a6f05"},"taxa":[{"id":"CWE-79","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A05:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"080f10910491cf39373e7bd2ad8b18c8d90b0581238bf9f3070794a9bc9d101a"},"taxa":[{"id":"CWE-328","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A04:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"034ee87b9da9172d9c02060174a678fa23dfb3f36f0f969d201d3d8174051fea"},"taxa":[{"id":"CWE-614","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"4acdeb9146d2f5f08485982e9072155735aff13e40946e7f3a7e789d6f1dd153"},"taxa":[{"id":"CWE-1004","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"e4fa14e2db085755d4058790a4ff3393c730029659a22fbd88ed2ffaca11aec9"},"taxa":[{"id":"CWE-614","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A02:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"a68e5a3715f3df3685f65b0851bd3364b959b4e90685bbe532dfbae74d7e49cc"},"taxa":[{"id":"CWE-242","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"73252beb35f81d84d6dae2fdde91527488001f64f62a513d6e51ef10f686aef8"},"taxa":[{"id":"CWE-242","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"255b83bd72eed020fc79f3889453ec4f44cdc7dffd6cc2c80d60e27b7205da02"},"taxa":[{"id":"CWE-242","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ab114b8018940923b0eaba3ca490e919a06f8aeaee6cb4846e9e2f648af2610f"},"taxa":[{"id":"CWE-242","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D29","level":"note","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"e659f6b2fe6911b9be725e332b20c7692c0ae19b68424f136fc02a7b10f1d5a2"},"taxa":[{"id":"CWE-242","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}}]},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"e28dd292e6551859f577139224a860d21eee4da9c18da728a9fa32c569e8bc25"},"properties":{"dependency":{"package":"pyjwt","version":"2.10.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","PYSEC-2025-183","PYSEC-2026-120","PYSEC-2026-175","PYSEC-2026-176","PYSEC-2026-177","PYSEC-2026-178","PYSEC-2026-179","PYSEC-2026-4140","PYSEC-2026-4141","PYSEC-2026-4144","PYSEC-2026-4145","PYSEC-2026-4147","PYSEC-2026-4148","PYSEC-2026-4149","PYSEC-2026-4152","PYSEC-2026-4183"],"severity":"critical","fixedVersion":"2.14.0","relation":"direct","declaredRange":"2.10.1","reachability":{"kind":"production","file":"cmd/bots/bedolagaformat/login_demo.py","line":31}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"601de294c71477e32447105a170bc1bac75e416c0f2494daab4e0c392d76adb9"},"properties":{"dependency":{"package":"golang.org/x/image","version":"0.31.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","GO-2026-4815","GO-2026-4961","GO-2026-4962","GO-2026-5031","GO-2026-5032","GO-2026-5061","GO-2026-5062","GO-2026-5066","GO-2026-6222"],"severity":"high","fixedVersion":"0.41.0","relation":"direct","declaredRange":"0.31.0","reachability":{"kind":"production","file":"internal/app/files/photos.go","line":24}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"59ce2a5b25630954a561f485f9cf35d728a62194b71b66163b19d3eb6e86c1b5"},"properties":{"dependency":{"package":"github.com/btcsuite/btcd","version":"0.24.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","GO-2024-3189"],"severity":"high","relation":"transitive","reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"74ce77a53eaf76fe63e1f1adc007b097343cda9e23a835e6299092c393d41ffe"},"properties":{"dependency":{"package":"source-map-js","version":"1.2.1","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"severity":"high","fixedVersion":"1.2.2","relation":"transitive","reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"e865fd6c2307ff6656b1e148654d9d6c4c60933987d8ce76f6489ad0a71e6506"},"properties":{"dependency":{"package":"vite","version":"8.1.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]","[GHSA redacted]"],"severity":"high","fixedVersion":"8.1.6","relation":"direct","declaredRange":"^8.1.0","reachability":{"kind":"unknown"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d94222fa9934edd47ba3a0ef99e3a7d85a9c2a0dac93507e5359a1abb9d5d840"},"properties":{"dependency":{"package":"stdlib","version":"1.25.0","advisory":"GO-2025-3955","aliases":["BIT-golang-2025-47910","BIT-golang-2025-47912","BIT-golang-2025-58183","BIT-golang-2025-58185","BIT-golang-2025-58186","BIT-golang-2025-58187","BIT-golang-2025-58188","BIT-golang-2025-58189","BIT-golang-2025-61723","BIT-golang-2025-61724","BIT-golang-2025-61725","BIT-golang-2025-61726","BIT-golang-2025-61727","BIT-golang-2025-61728","BIT-golang-2025-61729","BIT-golang-2025-61730","BIT-golang-2025-68121","BIT-golang-2026-111943","BIT-golang-2026-25679","BIT-golang-2026-27139","BIT-golang-2026-27142","BIT-golang-2026-27145","BIT-golang-2026-32280","BIT-golang-2026-32281","BIT-golang-2026-32282","BIT-golang-2026-32283","BIT-golang-2026-32288","BIT-golang-2026-32289","BIT-golang-2026-33811","BIT-golang-2026-33814","BIT-golang-2026-33818","BIT-golang-2026-39820","BIT-golang-2026-39822","BIT-golang-2026-39823","BIT-golang-2026-39825","BIT-golang-2026-39826","BIT-golang-2026-39836","BIT-golang-2026-42499","BIT-golang-2026-42504","BIT-golang-2026-42505","BIT-golang-2026-42507","BIT-golang-2026-56853","BIT-golang-2026-56857","BIT-golang-2026-56858","BIT-golang-2026-56859","BIT-golang-2026-56860","BIT-golang-2026-56862","BIT-golang-2026-56866","BIT-golang-2026-78659","BIT-golang-2026-78660","BIT-golang-2026-78663","BIT-golang-2026-78667","BIT-golang-2026-78669","BIT-golang-2026-94439","BIT-golang-2026-94440","BIT-golang-2026-94448","BIT-golang-2026-97030","BIT-golang-2026-97031","BIT-golang-2026-97032","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","GO-2025-4006","GO-2025-4007","GO-2025-4008","GO-2025-4009","GO-2025-4010","GO-2025-4011","GO-2025-4012","GO-2025-4013","GO-2025-4014","GO-2025-4015","GO-2025-4155","GO-2025-4175","GO-2026-4337","GO-2026-4340","GO-2026-4341","GO-2026-4342","GO-2026-4601","GO-2026-4602","GO-2026-4603","GO-2026-4864","GO-2026-4865","GO-2026-4869","GO-2026-4870","GO-2026-4918","GO-2026-4946","GO-2026-4947","GO-2026-4970","GO-2026-4971","GO-2026-4976","GO-2026-4977","GO-2026-4980","GO-2026-4981","GO-2026-4982","GO-2026-4986","GO-2026-5026","GO-2026-5037","GO-2026-5038","GO-2026-5039","GO-2026-5856","GO-2026-5972","GO-2026-6088","GO-2026-6089","GO-2026-6090","GO-2026-6091","GO-2026-6218","GO-2026-6599","GO-2026-6600","GO-2026-6603","GO-2026-6604","GO-2026-6605","GO-2026-6607","GO-2026-6608","GO-2026-6609","GO-2026-6610","GO-2026-6611","GO-2026-6612","GO-2026-6613","GO-2026-6617","GO-2026-6809","GO-2026-6859","RUSTSEC-2026-0381","RUSTSEC-2026-0382","RUSTSEC-2026-0383"],"severity":"medium","fixedVersion":"1.25.1","relation":"direct","declaredRange":"1.25.0","reachability":{"kind":"production","file":"cmd/stickerseeddeploy/main.go","line":337,"symbol":"os.ReadDir"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"1c9c7154a9d80981a2f1da0fd0aa2e12a4e104a4411624a7aabc5ce2dd45d848"},"properties":{"dependency":{"package":"golang.org/x/crypto","version":"0.55.0","advisory":"GO-2026-5932","aliases":["[CVE redacted]","[CVE redacted]","GO-2026-6354","GO-2026-6355"],"severity":"medium","fixedVersion":"0.58.1-0.20261009181718-2f1f834330b2","relation":"direct","declaredRange":"0.55.0","reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d03f2a180b6c44b09157108557612e48c9e72436d9219e099dc51e18f53d4553"},"properties":{"dependency":{"package":"golang.org/x/net","version":"0.58.0","advisory":"GO-2026-6603","aliases":["BIT-golang-2026-78659","BIT-golang-2026-78660","BIT-golang-2026-78663","BIT-golang-2026-78669","BIT-golang-2026-97032","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","[CVE redacted]","GO-2026-6610","GO-2026-6611","GO-2026-6612","GO-2026-6617","GO-2026-6860","GO-2026-6866"],"severity":"medium","fixedVersion":"0.60.0","relation":"direct","declaredRange":"0.58.0","reachability":{"kind":"production","file":"internal/rpc/botapi_rich_message.go","line":54,"symbol":"html.Parse"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"b66958d36105d659606ca462f50269679a3c1d5e550039e14bf9ce51cddaaddb"},"properties":{"dependency":{"package":"github.com/andybalholm/brotli","version":"1.2.1","advisory":"GO-2026-6888","aliases":["BIT-brotli-2026-111497","BIT-dotnet-2026-111497","BIT-dotnet-sdk-2026-111497","BIT-node-2026-111497","BIT-node-min-2026-111497","BIT-powershell-2026-111497","[CVE redacted]","[GHSA redacted]","[GHSA redacted]","PYSEC-2026-4322","PYSEC-2026-4323"],"severity":"medium","fixedVersion":"1.2.7","relation":"transitive","reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"ea90d4a89ed124d75960342bec5214b8c2deeb745d761dd1ad2ac6b2ada907df"},"properties":{"dependency":{"package":"github.com/gorilla/websocket","version":"1.5.0","advisory":"[GHSA redacted]","aliases":["GO-2026-6278"],"severity":"medium","fixedVersion":"1.5.3","relation":"transitive","reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"fe34912cc1022f16defa9aa7f34d659541f4568862a4f10eaff5ff953cbf17be"},"properties":{"dependency":{"package":"github.com/klauspost/compress","version":"1.19.1","advisory":"GO-2026-6865","aliases":["[CVE redacted]","[GHSA redacted]"],"severity":"medium","fixedVersion":"1.20.2","relation":"transitive","reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7ec7853619c055f78393829d380806cfc155be3c1c5f6b20bc2d7213326a680c"},"properties":{"dependency":{"package":"go.opentelemetry.io/otel/trace","version":"1.46.0","advisory":"[GHSA redacted]","aliases":["[CVE redacted]"],"severity":"medium","fixedVersion":"1.47.0","relation":"transitive","reachability":{"kind":"not-imported"}}}},{"ruleId":"D30","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"34d92b4e8ceb16a1fd57062952c6ce862546a7f5a590d99835b621f385dc5d89"},"properties":{"dependency":{"package":"golang.org/x/mod","version":"0.39.0","advisory":"GO-2026-6179","aliases":["BIT-golang-2026-56864","BIT-golang-2026-56865","[CVE redacted]","[CVE redacted]","GO-2026-6180"],"severity":"medium","fixedVersion":"0.40.0","relation":"transitive","reachability":{"kind":"not-imported"}}}},{"ruleId":"D31","level":"error","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0599912a31e715341a49c3efafed6a1f780a79eb2c6522dad14d44f9ffeefef9"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D31","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"024998076861e6d08acf59ce485f8a90ef93e4111818a5ef01fa5ed74362ac62"},"taxa":[{"id":"CWE-1357","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"CWE-353","toolComponent":{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d"}},{"id":"A03:2025","toolComponent":{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61"}}]},{"ruleId":"D32","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"245014c67f64139b8a7c8a1a0835c408f3b2ccd791b75d2ebeca52022ebcd156"}},{"ruleId":"D32","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"79d5214c1241159add10ebdeb46d9e650673d090ba39be9c7fcb321b48f14da9"}},{"ruleId":"D32","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"309779c8221b246489fa572a35414cae954688ec98a9c24364e1effea3cac493"}},{"ruleId":"D32","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"d6a385adad6706988970f3e57213e6e77f7b74a29b327fdf0fe1f003ea2a059d"}},{"ruleId":"D32","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"7db4a71a407c2e1085af483f240b9c7b2ba6c461cfeafa5de48e07e060ad1c4f"}},{"ruleId":"D32","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0f8e2b9f9cd8359459ee17a7cf728551196a5aa6ba6dfab0d3e9fb1c24215ac4"}},{"ruleId":"D32","level":"warning","message":{"text":"A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."},"partialFingerprints":{"codehealthFindingId/v1":"0bcabdf8ef98f91a20ab0d14144a6a17e2321daeb7ee3630dbcdb5fc99b59b58"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"475d405b0ff5924cfdd92911b3487c3105d06795a871ba38bf11ecaf1f9406e7"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifybot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"257ec24a44a80932c9aaf5c663dc1e2089f96aada6734cbd3c955710679701ec"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a24c75c2039ba9d286fe33fdcb9772407ecc4818ccb4dbb27d28bd9688225932"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/telegram_login.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e1acbece957d46ea3780d2438be1d3c946f81078e0acbb43af427a087eb883ac"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f1ac639b410c1add60446526c4370edeb816d0cc709f3adfe1efd75ed5134f2"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"66753fd84cbbae7e29b07c65cb3932ed554c09403950460eb98a2a29d2325c53"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c78ccefef00eb59888a385ebdc5f4dd85f51d4f8a4ef8f0b2bb3bc64a0465fb2"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4b71949bc779aca641361d782c1d1a179743d827311f21f43c5b83b7fd87a95"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fe41657e5b91f142a6fca078ae16916dd2b81893c65066677b5c3f3470fce6f"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"500497f532aac64710768b94e92450c6d5fdf6889079dea74b9729bf8158e3d7"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_cases.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"957a95a5fb812f55480d546e54932930821346607e9596375f44ef0379056618"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a28ecd802cdd3288b7c1441d8b31a4ee260313ce92420e8f0fb2e203116342e"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"62aaf57c7d7eb61288a0b23531c910ab54045d3f49c27fc306a987349dfeedf7"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f8fd657231d9d1181a6a66ad1c4dc291399dbd50c4df6fab42f7fcb928e64e3"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8e90aa580cf2342b04fc513588ef126c0115b53f6c9de5a6f8fe27fd58125d0"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5996f8260bce439cf3419eaa38aa4bfa0c0f42e30214e800780b23194bc12f5"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0cfbfbc1c97e456eb6c70389979d730c68d37f020d94d6a09950d6ba6b6c0af"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"040c636c289013aa4125a953f50e0e489ce68547e94881da4037086bb7281a27"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2764acf359358a2d9a0d7d0c95b7d9de5d9c6c6930144d453480960155e8f381"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/collectible_username.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"14c3c881302ed344b59d09dd9471a747fb12c73177da5c604158dab576739baa"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"095e3675366831b9a00f54b00afa5785117ffd5e0827df1c9f96497aee9ea75c"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d26a7b3f8acf19a663b953128cb38946036a8899b36bc5f616212fb7ae07d90e"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/evidence.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"01180b4b56abe6cea2c7f7e006f60516e6f254ce86bf3760c72fa0a0d8765ca1"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3abd3bf3572ce0bfde909789cef65ea5ba24f3c4032544f0d5a96f8541db2ec6"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"998f82f57dc018e169ce48760fcd3710cbb344e58aa366c7fd4aeab2ea3c399b"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"32b501603514d3faada555673dac11b88a0d039f0fb7d2f2f2d5ab8814355d01"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"99843e9205bfd8fcbcc1c083ab477462c28cb60ad2021c832ab0761515f21076"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/botapi_update.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"427367e6c428ef1e020fee1654e305e15d66bfbd7011f009be0d071253271d05"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"69097492c640062e8d0a1e666a809ee10dd4f7f67cf5badfb2a840dcb58ec2dc"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/storetest/groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd2a7eea36d655a28ecc251cc9f360d57a65dc06506375978cd45d11dfcc28b9"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/collectible_username.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c965c56f2ca6eba872d3ceec5058460f0113106bd670d5186e05f9df9b3eb43"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/scheduled_message.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f00e4f35b8dfb92b453c4bbe51c5ccf43c41573779efefd78250f3d1dcf1dc16"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cc370decfec67c18a9bfe2c75ac81fc81f3280e3862c84cb3444d7a12ffdbef"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6f6d4aa43b6d3559f27787a5217f2f39d77a6185e54bb22fd43146f174c1ec3"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"092db5642e5482156579c252cb7af15c8b31e4344034900c7ca67b0e85d5dd24"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_register.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eca8600419f013abf12da8cb521768b5ba0463847bb27bd5e3c88b300ede0729"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6022c948935ace8a98eaffd3c546b46a245ca80fee05ec452f1fda95c33761fe"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"39508a609b233faf09eff0a63837527d887fa887938fef8ec0d99d968da50f62"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_webview.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee487e69b1ee771ac5cc9968ccf17818a2c7231199d1643fb11a3142f73a2123"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"605d5f4e2e79c93dfbe1686cc78d9e08e28b78b6929440a1d1c045305f4b1893"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c330e32331da70d965d966b4c1b6132cb2e436b06ac179a982eaed3f51c1615"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot_miniapp.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eada1868c87b92162f198e106d587610bec7671f2b416585332d8fe050f2436b"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/observability/metrics/registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8bb90b9b0112ed29fe7bf04bfdd5eb940c916af5516cead2621914833440ed74"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/inline_registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"efae74c00bbe6d1fec3bf028cc412d75e77b0ea6da0f34df412c9bac68232f87"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/collectible_username.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4d32ee8aebef0a115c29ba016522a9d48562393454eaaf80aef0341470be206"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d91e364b2d34e911adf5413db391a7edb81e6a6b470cff75df20fb8c1542f66"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6139eb4fcd7ed100581eee7702165ac727c6d437690272b06add251d9c10978d"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/botverification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"86eced42d5f0b80e1309180442c2b88a584d9296edbbb8526dda7b4b5aecc673"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_exported.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec282aebc35655ad2892dfd7ec9b6c78c528e9b20bc556dcc1a37ead04e74228"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/layer_inheritance.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c38868f52dbcc8f83d011a5917620bed96baa2dd41c3be48786b382733433be7"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/bedolagaformat/login_demo.py"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e391a30548967260d081fb6d0c0b31137f757602e862426685bfd61eb9c8a2bf"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd623dc7fddf9da9f27c9f2d5488c1817068e8358562fa31b1b38ac7d942095b"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"78b7afe676f4663b58c5397308d42ade6f35e01fc71c9e1debf9e92b7f25111b"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a50ee23d6a4905340a2c4a6802516bcc4a870f917ea5c455c9264170f8bb849"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/chatlists.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b01ee77dc55dda66d0676f48ffac8d1046878329bf41b282e8c4d681bd3fd8e"}},{"ruleId":"D34","level":"error","message":{"text":"Orphaned knowledge: No living knowledge remains for this large file \u2014 its last meaningful change has decayed away; if it breaks, no one currently understands it. Schedule a read-through / add characterisation tests before it bites."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b9859fb80aeaa45f8888c0a877d3241b3c2aff20a36573c80346462775d48f24"}},{"ruleId":"D34","level":"note","message":{"text":"Further orphaned files (smaller): 344 smaller file(s) also have no living knowledge \u2014 folded into the freshness score and metrics rather than raised one row each \u2014 most significant first: internal/domain/moderation.go, internal/domain/telegram_login.go, internal/domain/story.go, internal/domain/moderation_case.go, internal/domain/bot_verification.go, internal/domain/ephemeral.go, internal/rpc/ephemeral.go, internal/app/files/webpage.go (and 336 more) (400 orphaned of 819 analysed files in total, counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated, example/demo and scaffolding-template trees and test files identified by path convention, largest first; 819 of the 1037 production source files in this repository met that bar). Attach the read to the next change that touches one of them: have a second person review that change, and leave behind a short comment or test recording what the file is for, so the knowledge comes back at the cost of a change you were making anyway."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"ce861fd78f6935114d3a342cb90ad25870f984e1042954fcbbe27c0e23be3658"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c843ca5e6cd13c882dbd06f59adbcd9de2d131ef5cc76a543ab5f298ef4fab52"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/webpage.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac08bf433da8e8aa410d23ac36655324d9e0e497963601f366d569e372138c67"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"85f7fdfe684cf7765eccf31239a6853e045526c485d6c465611cc29f8192a34f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"83855bac04906198e94b09516e7342f517438c9bd183e78fc3a0f385c40f0270"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/saved_dialog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b2f463f75f2e9f66e5dce8c13cd5c1205f350e74fae2967b275b671738dc7e1"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boosts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3468fa138354401f9cbd8b5fd73be722682a7377f70723628d0c32a1bdfaa2fe"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/conn_layer_profile.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f07b471c55f8ab8aa0ab07165544ed3947c080196ac4ed1ddaf1ff73549c7742"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/usernames/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d96ebcb7bc1ed894d349410d703f932d236886de59c1823ab53ba76a9194d0e3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/premium_promo_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd62279783afcd5a57971a65c4127688d261ae99704edda215c578bb45c7d58e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/phone/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c087a8f6ea54ff5a36a4b36ee805b24eac34a3379d4a133f985b3c232a551aed"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3e0c3b0a6546958fb1eed7a3e661af13b66256c966141edbab8a99494f43267"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"558ed126da120bdf8b5403afa66c7997902db1d4fc9cf51977c8e85294417981"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5e40d560ed43278516a725e8d0facde8ffc707f1230a7acecdf0f8ce50d3e0e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"521f231d6f804ea90e727e43d60c54e92b4b6cf4c5dbb77eed547fe0e0ab0006"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c56dadf2491350a3de9e0d8ab30c79261c8e067e18599928f008df362225afd1"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/telegram_login.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c78146c713829f44287ad1f87fd904b007f833f65925cd783cceac5bad4f819"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/actions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"94f75f7f59a5144e54b31a33f13c23e1306fe222e074f6cdffba7ac5725e8357"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/read_model_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"33d8a1c1c9791bd52a30d8d5fd01dc5a99e544d095c0562f947fd5048a84ed20"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e30e3096f693be947129cb1113af245818e9134ddef6d3583fba5fd5031b5fae"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"10f4ac7610d76c0b8ebbbddfa124da8c688261b21f108f00509ee42ea8c70ffe"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/langpack.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6e02c16f6c19a81e1f23b946be1ca6d0173a38e23a2c85c248fb0caed1ccd610"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/story.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"350487349f7235a6feb4307fea89d9846a260a4d250c88c676a1487819562ee4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation_case.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b256c0beba0530bb14dd06a15187fcc1b77664b5fc81e3958de83f8089afc5f1"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_send.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b99751caa9ed4570f5527c99b95c03a6480361f70d9208d6f83d816897bb4a4b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b81797abae4c2b2163bb968e2e8df67188089ae5ee57d7f501183af25a27408e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/telegram_login.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d112bdb04e787c33b13aa4f9a31524c9f4ec8820c6fd083a9779fed4be048402"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"838f9e9ae6815d1a12c90b6464ce243385d8deefa7dc31f05e7c61c89a56da15"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_conference.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab2c82c9154f9429b6188af61c146bcb87184dc45d1b8c0559d970b8b2d24160"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_send.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"71d16bcdcb55a4494710865040d9368e56d1f0571661b29bccad94cd232203e0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_monoforum.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f142e59ed3044117dea7754987beb81e69026346370dc6082f652088c36b2171"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_longtail.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a98e42ea99d02e13196708166109cd04a7d5527bf9cd2d33a3bdc7be43f2c47"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_reactions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf7f57b5b5fc6eae6d5df2fb90a9589a29f933c11702631370535cf18513d617"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botdemo/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"441351913ddf1b6bb382cac4edc0cee447ee4d16cd89c3e4bcbab5e5d2e89988"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_phone_group.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6b28dcd3dae7265a8d1fe6b647378396ce9cc700c9263fe12971e743b5dcce2"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c214ed5e0752a16ae57f5f90e132c9a0e13c3cce0ea535c9ded15c525eb0b64"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_ledger.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"97693777c54fb4c7ee626f811d863aa2c41215b3fce95affaa71d8b078f49788"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ee45a416709004ddadd71ce61f252b32233b6b8876fb968d47956f2848faea1"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_unread.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e0b87793e45d2fb81e023a69d96490a397870bb78986eb6d2e5e3e8e7286e70"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d43765065836fb80682e2d4b4da23cd041fc9b8cf6f99533c0fbefeaeae46e08"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_suggested_post.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ca1800432cb5bd26f5ae5a739c004093fd65c78fafa218f184570f1f345a4e3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_projection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"99fe54c07a6ab1ff6aa31ebc70e7523ec75a0bbbb8e2af0f1156539bb16ce990"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerfetch/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffbf3b6a9e1ce9f7ffd5c4355a7d8afb73d41934a9e13da67b6add3e8eea08df"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/bot_verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"42a11d1d85be29fc408f8c8fd626fe85dbb76fb6f7afdb610e976b94a769b636"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d442dfe0b9fb629289ae54a432197871423181c534e1edfe70ec425f8a47a61"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/poll.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0083201f4d291334c2b136a8154be37aeb867cc8a33429c90b8cbb75412c5110"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"12c2077939df9a85273f41b3a4ee303733e40820138c148791740b82bc19465f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/moderation_registries.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f9f3aaa8ad748b35c534091f79beac2c8ac2325dbff23ce2aa6e92250a7eb61"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/ephemeral.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"098a989a71d93ebd1311444c2622a8adcf4de5787ccf0a8b7f8cbf90e89ceffa"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/secretchat/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e29de3b3b7a6a47120e58d4264c7286b8f9cd6990c051fd4d95a1b5c53d864c0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6b98be434baf0e34856740706cd588453abf71e227c0cfb4c6adf8a8720268c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ephemeral.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"89a6fe19344687edbd6e24a6d898092721672381970a8b8780b40037a263248f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/ephemeral.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c48289b7d4ff5327819083e7327860ea7796fa314769f13375a59f21d6d4e4bd"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers_creator.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b641b2cb2fb563d02d2da151cb07330dd33c97b00ab1392515e8ed662bbe1ccf"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/webauthn/webauthn.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c23e0733f5a6616c88287484972bb330a482f0e83ea966aef34153b045ee936a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/jose.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b9146cfc33db33b56ddde1eb53edb0ace91cfef097768ad0cf798075d36cc82"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_quick_replies.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f817d8bd194cffcfd8114648a0b09d99e1f84d59d5400f15c76490d8b9bac9e9"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/maptile_proxy.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"de2f83ac03cba0fbfd6032bc793348da3a86a712db343e5e89bb6cb9b59e0e9d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6350130ced472232730110170ca506fce703d93e444e2ca541cc92bc5b6cb128"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"27882cbe109d8500f5354e73c465fcff44a89ef974dca9cbe714fea6c4d9723a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/miniapp.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"54e2ba1ac4e4f75cffc6e3bcfd5f13096c0c28d8f6243a9ed0cc4af91ce2c09e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f57aa15cc2842861a4aabfad5393cfcf36d360b3c71587d8abcfc0d115e1333e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_edit.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"db00519a1651490830c2c40a427733f0c023d5f8d3b4aad6b30d8ba1cdb0054c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telegramloginkeygen/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d218e0f27534ec0548aa34502a7e4037de9c333c53b08349dbc3e4c029022b6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/login_code_delivery.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fcb5fce39469c9ad2992a7553c17835eb3a82d48ec6ec709835502a63d44f87"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_dialogs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffb75cfcffd265052162b09a49fc680e77e792602cca4bc748db2038e0e0f077"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/private_send_idempotency.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4500dbd22dce97e9ffc0726124209e0c565e4c3bf6576d8350f9c0991d110b5"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_lists.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2371ef5c505a9ee167e427f86a197889a674a169396ebfd2b0f1f27d630c987"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/poll.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd20ca9c57bea63ad3324fb8ee01735d3652654a592849e1c97314442eb5429b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_todos.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0234f6ad778c0032711425b7c48f9e7f3beacc636fb66c7702fdeb5edd0fe60"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_stories.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbe380d5e4bf7ec0216aa85ce6ec42c85a2d557a7eebae17ad2146c37a18586b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/appearancefetch/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6fc6f7e5345498422d7987c77fc5eb3a5c8b056e2f836fa8b20c245327fb085a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b1cc7caa57e11f49d2f9b6655b439f81f0bf19a0f6c424f2840a30038fa671d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a01479cc71846de3f32ba3de04accb721299d2da791f446bc1efb6552bfd570"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/aicompose.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2043b421316d32bb6ace655dab6c4efa902735688bf97a4b399cd2efff31f7eb"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/bot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"21ea8ed9980d2faa7a7213e6331f0c65e9e74a8f59833f55559ffcdffa981806"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/premium.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f782aefd49ec7c82aea98570c456c239ae027a957e52829074e35ba78dfe9e34"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/blobfs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9e079dda06b4a8f6d1fef22e9e19972468117df72378cfe5fedab2b74dab364b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_update_retention.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad32287485dde5312f9b41b7bde589a35235be969b792a9d2e406e6c6b328c38"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"96a5a72a5bc926e296cdf07c4a89454e7dc65c1b2f34ce1327420445d904320f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_chats.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"645e37462296e696e5a2c78916472a7faf5c6d12987e5b2014296dc404355f38"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/update_event_retention.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2ee3c176ac145c47c6fbb9bd2eac5137e8c41915c2832666e1bce114f2e351b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_bot_no_state.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3de96cb7db9d66dd4891fe914d931a5d1557a622152fcf1e3faaac11b1ebb0b6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/dispatch_outbox.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c7402e551c74b4da174a5294f770824c90ea00a872d28a08a7582eacd106d3e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/durable_layer_evidence.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"66c34e2899d785a2d0465b7d356772b222726632f1009e655e0c66af21894cbf"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/layer_rpc_execution.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4b8bb6d8bac8e9c880387085700090f829d02a7655dfc98b8626c3bc3483d26"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topic_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f85ca83a5c957ed99d290f9339fcd4d28dcc2df741466fe6285f0e54242c8ca"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/otpwebhook-example/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"27cd94737ac2ddfd489c9e9259a450d15fd634b33c131cd1fbe312d19eca25d0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6e630e78f74506b7ce764b616ac3d193bd7529fca8b370349ef03ede0a84bd6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_pin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cb9684f40940b9bada6f514b614dfb658457e39cbebb5cd3f2c4658c7791ca5"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/rpc_projection_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf163e1a0e6c5cd52ef60bed58ff5685a3894f087b75232a6179ff2c1d5e21df"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcaa9f33cf97723cda949e48a4138f449edd86e8762648fea10c4f9e62ddbac1"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3354e5af89c9d024224544bdd795c110f24456db589679044519ab6555a78c04"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/chatlist.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"afd194adf1bf1ce046f6d75aafba160232fe109123d6e86831badbaf944724c7"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls_updates.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f783586a6a4860829215f1811c663c5a7974e5e06dac138ddeaa9f385cf4d2f8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/encrypted_queue.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"196c6cf209e482d3e23946921b399d8507f12780bfc669c64cd8208c00c74525"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_saved_reactions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a97275c8547c9969c64c9a5e08499a320f3d30bc79960027ca321a84f2569086"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"55dc5f9692eba15fd0a1ce732d927c298e7a1c08ac6af3e69c22e954dca0ca11"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/stickerseeddeploy/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1581ab7052ba12dcac5fea7f9440ea01af9f195dfa3149cad9240afbc0caa40"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_settings.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd50baabc75f1dea10271324f02f18a170eb96c2836f983a0c007dac2c3c2f20"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_projection_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1d9f3d68dfd453342f9b11379f5e22f88870229840ac186862939a0f891eacb"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_rich_message.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc1629c09fd26f2e28996f2e73d113a152527d15a0fd96e01c28d52d076f6a55"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5681663fff994ce79297b2b6f311cbbdb9c99c562379a76ed50f3570ab21f31c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"07d38c6ecafac00617d465c2ab21630c151e2ae6e79af106c72006f80b0e81a6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d10a8cbef2529c893ac6c45b5a4f99bafd190113bc67ba56deb88e295499e7c3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9d9ab643c362aa51a37c5b7451ad2247ec25cc309f056dad0674e5012cf591e3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send_as.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"45f6012ef0078aac63c3ed46d6a91e48d539137222c9ea614719d3b8d2cf11c7"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_register.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cb6b1c12557f44f988db8b2260c68520105e13811034862b3be768bd5d70190"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/mp4faststart.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c29d6c6df2a757892dd7a3303500a16c30d18952c1c01144c322b217b69a9e4e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/langpackfetch/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9b517528a4916f5bae47dbf6de1041258d5b762c0a46efbf907be80abbc3a3e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/livestream/segmenter.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9451a0c8c16f38f4b8ca5f6672406498405bb9399af0398c4390ccdbd6795b1a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/passkey/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2fe80afb14264e0b5ab2c38196bf047a1d69c60a7021beee934d7fc79511884d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_attach_menu.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9b5ef77a3b2684713d88fb7498da94a458913d2f3f4ad597e4c65fd5da5654e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"247cb1a6f8f36e7d081d99a4a84b32ea1bad16961a9428de3bdfab8332acb15d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_no_forwards.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dbbf73a079b9a41bdc9b67fa1729bc283c707a2b071cf8e6c6f467b2c805074"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/boost.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a88fb0dd37ef8bcde5687bda7e00e8e3046777fd9674b6a07f63d5049705bb4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/communities/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d808502db435a78a44e53a06dbf20aac9e2d5804f8b590b3eccf26ab28781db0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2284094ede8d9c12aa8405af037f5db7f7b2bb97724cf48f5960399f10bb4574"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/upload_webfile.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b55c3bc2ca58fc1fea56d064632454024536adc05ee410ace5aae26415997790"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/poll.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e34ecc465ac4efc0c1b9552faf38f9484bacf56c07b432257fe4dcb24dfe02e6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/rbac.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a25ea15db85391e55224a303dd89bc15826ad4581931c1f0734e258822474f33"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/provision.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"707621b1f443e5da92f2f3511539a14db41770b36766033c2ce7297b0f564cf3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d119e23ca059909bc923fbb705518c173736f9c986015e6d6c7745fe762e7389"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/frame_budget.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"137762b48a4d10b855eec51c7ab8695ebe90773a40928819e0d96e612153b8b2"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/secretchat.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7169d5c81c8014d638fb1dc5b7b53e9fbdc50dc8fcbf5c3c027e1d4525f01b6d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_sticker_sets.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8066a5b5190e80ae706c478e0fd6975d06bf7ccd41ba59dfd06eb8cb37bf8526"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/chatbot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"eecec819bee910860d613749033d09e1374a563c924ca59de73c4eca77f2e1b6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/saved_dialog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cd1057b1fd73b4e02d14b6282aac3a01db551c4f9668b65cd27ecb9f7250aa1"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ecd4a35315943884a6d743921f9c25f03923279d4d42c61dbb81e317ee6c305"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/secretchat.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2970d1f061d59fd76eb93a18e97ce7e30090ec428614deb6b5983c29b7ec6fed"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"de3d41ded8f15ce5681fa8281a142e47dfc6fd583732fcb31e7c12bf5ff674b9"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2e158be934cd7ea709a5a0574775dda5285cba315845b9a8122f4e167642344"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ai.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"de61f2174fd55362e5c90852d6449d87033b1ac3ef07e9c04c44dbaabfaa0557"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/callback_registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e1ae6aff259138a04a016a2c783b405a520395aa6b39a90bed31305169dc697"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fea5ffaa29f7572869c6a3391a991c9638a4bdcca7e39e14849143a35a29cc30"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_rtmp.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"864cf17be2994a4135559940240f8fdfdb8add1f127cbf4afaa7d835de9886ed"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/webhook.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2eecd0f6e22b26b192160ad26603ff3f5d475881563a56caf574f78b69318bf"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/appearance_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed5e9a4f7946b040426153af5ad720eafa6ba9afd14818cec02eb89ef3e3df73"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topic_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e978c5bd24d9c18ba6f04314f65d245f9f3fb49c8638022edf1d46a6ff5a4e2"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/business.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"39ae127cbc6d1199d1364d096d41051c25986a2b47c10432be2e4c5e1065383a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/layer_updates.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2aaf7f33a4f9fd3b93636db044a783e17acd5974b4a86632b4d79779e5f06e0d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_identity_lock.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"217276af5f207fe515138ff0a3ad6e2dca4a8e5ca638dd47c91e81f39756a17e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/privacy/facts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9ac00005bd45faf9350d7828dbd7fa3358ebe769e5ad80d94e68d89fdf6d53ac"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f33350840c04d99fb2f917cf27b55c44a2ceb32e1e32139d6e9bec79938652a2"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_phone.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8a9d039c21c11eb831f7a02f97f590ef37c88228f3bd948a270c54ad63426ca"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/themes.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c45104380b38b9340a70777ccd2e93578ffa59d0d267669529093c4a0e6b569b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_requests.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb829e0cc253a2ea7533e0e1bb76943cc0f886b23e37ecd21f940892a6a78651"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/themes.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"24832e5ed954411ddb2bfdb6837c47d67e539356752417c71f6f0803b478016f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/postgres.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3d55beedc40f7d73930031fdf0941b0ae1b9af2fb763ee701d57e57cda2ea72"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/themes/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"401420c95c7e9c6562ed19722321dcdbc27c78623c700d818799bf95f5446137"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/transport_detection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c33e0f9e2c2fe5773d2befd0a72324bf8913b488f5d9a7f38fd69f0caaac0f0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b66224ab55e13d3b6e2c3e8de3bcd5c2f62eb1267e9af98bdbd9e79d1b200505"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/bot_verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"243fb98793d14b772900b2bb4f06f761ad54113a15df7875d82988c83e36001a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_settings.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"12c369c0be9d86d5825ad8d518afa88202b68ead5fab6ffde2fa1bc485a5bad0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"29b9780eb6d85d7ee72d2d4458d936328f98c974ccb1c5069dcdff271d6bbb18"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_store.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5880b1cd7d2c18dba0e4a16cf80da93180f620784583de63fa563ead201929df"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd344d7d0721115c9eed342e8cd9047741f5bce3bb1e3dca6bb8c5860cd942a6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/chatlists.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"02547a41175859e7c49633286b850410b80eb548673d509238391497f7c5c96b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/cases.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"253b97c852a937ebb019ff2dc3b835a5b2705f2cba1d64bd2bc4a465b05334ad"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join_requests.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3f45185126f7cb1946a795ea1c4dd5d0ce2d35c849bb7a804b7bc7fa00d09d80"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_misc.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"144195c4d3d618db8ab873f20d662a2de0b8acc3653a135abc1d78445b4044a0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/keyfiles.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"47b95ea05d25f6cc151bd0958d785d73f5e89773e91bb48f331b61782e3eae5a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_presentation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e37370056c5e6fa95d9dec719961d7791d35aa31efb682d00dea0049d43acc2d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline_message_id.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e598300da492cc48656cfd67fccf8838301d9895cfc9525040a26a156d5aee22"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_no_forwards.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2e2f88adc38743e72085cb6a40d482c50b44f2db3c4d30824672b55f4afdc89"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/photo_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a21dc6024ba439ea613eafdc883cdc3403288d733275a169ffa6a9c3beaeb37"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_execution_budget.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef2d6d64c8c0740b0869dc50514b3dd6550b1b35897e71ad1901ef2d5445e61e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/catalogfetch/main.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"de40b31c2462705d66f3a40395c23d5167cf0b9d4a59467dafeaca7a789da795"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/otpdelivery/webhook/sender.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"68edcee1f3890e96833736976cb1b06cf77c66d60494843e0fa362980c5db4a4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/wallpaper.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a278ea059fc8b3c8c3e6bfa3142599e0fd8106c9e56881a39b0ce746db618f6b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_forward.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"02c0e38e42e09bc4e67e35f2a5ed6ea10bf3f866145e65e10a628c0e3102fa17"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/maptile.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"31e6cc7da276be085c164847df53df75faee568049ad676ed21cee9355d1df13"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/verification.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"277fe9a1697f27490b19b6bf1282334cdb23ec86ab820dbbc896348c828048e8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/secretchat.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9655ea64fe3d35f0c91ee6742276a2f856a96349f9bf9d29187548f63659edfb"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/logical_session.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"54909588a5f0d1f8c5d4cddf646ef2c46659a0bd2b3d9d6c96903f946cbfa342"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_admin_log.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f31784c9d8ff4e2698d4dc5197835900973d3b7ec89cc90672b5c1258e58814b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/participants_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"761b414c3878503b021d028b7b5e50a1bdd86acdb6c0cd3fb283b180e3e82e31"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_members.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b65efe06289ad1d01d0898d682d85adc5bb9340975c3ede52f94b7477f919740"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_hooks.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbf1bd4df0d5825e98dc802455aba787faa0d2141d2f8c1b507f83a0ea674aa8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bootstrap_updates.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0becf3f577eaf2024ca6cc948dbb3d3ac85787c5b50d1ccf3417aa548290730"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_pin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bac2c442917f6d3c527c1feac2d7cf51d30e8beb1b7b3bd418de3885bd42694"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/album_group.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d02d5d3c945deeb861e5bb13861a6b12e4bdcbaa88513320c8b6205dd376a07d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation_registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f36efd7c8b69f7a5c47d26d3fdcca29e60c16ed1144fc0b6d6fe6818648f9b5c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_reactions_helpers.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9369c6d4731a102aa0174909b41bf151f2d08596b40acfee5c35920def500223"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/login_token.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd42367233e089323ee176d59eca97fad1ed5558df263393f1c70dfe7cacbdad"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_delivery_report.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"38714a771fa4b329cf54721dfbb18821de8efc839d21ed71d65e9db8ab31c1e4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/community.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"47c55ccb868ac107b0fe453c08daf3e11217d5b202d1e613018729780fb4f9ec"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/sfu.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d83c24d5db20c11a5c4530b200a56aee6926eee1f10861a54df42ba64467b8b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/phone.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d39ac44de6c6854eb2f498e10479d67d6a8be48b2e58608eef0d0384922f9668"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/bootstrap_update_job.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f85aa925e791ad070bb91bac6f973ee1185c3c901304107006b096044d9ff82f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/livestream/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c48097157144933f9f4a8f6e4c9a9b4b5e710825bd500d09e49eef96f023ff9"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6473a9a03cbd1b4c43db6e86260f62e93fe1d239b1df37c20deb7082161f513"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/tdesktop/dialogs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"67e5a73f6dfbdd83e44f7eba3ee60194eef788881ef906a0e4d57b275933673c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/client_telemetry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f94b41409483f71245269d41cd3dc47bc6a4cdea2c1dba72780e88a75c1d238a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_interest.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"61f0044cad64589319148b8af0d7eab62a01eb4485f7bf011cda0aea1964b7c5"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/srp.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4d4185b4e408fa65bb843ad588a1df585b3d49b9d6df37d3cbc0e5dc9f0db285"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f2bee2e350d3b18d2f9e61a4514200999b75a9c9fc3bcc4cb7b208fb5da0e53"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_pinned_stories_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"217480251b72cd92dd1824d9ee0af70b5150870f08e52b7ab694b7997075b5dc"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c83b8629cbf09f77ae9411bd2d91f5177db6c361e059bcddfcda533b58553680"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d748acaf734e9f213e2230bae997e502f7d6512a46cb9a7c21b6aa4c97f0a76a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/verification_notify.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a72682eb277d7d651c55d24887a5b6e23292fe42fc1dee42c7092f8170adcc13"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/default_statuses.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b3bdb8de782284a55d080e7e6e4dc21e7e0582338f5c2635e4cb3d2ffc80ec6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ai.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"da802a9a29f3500352773cb5716d4a64224b8f789896dd3d29359b167e8e8371"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/gif_transcoder.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8a81f05ae84709d59040adeb131e8ee01629c2d0ed91d78624c12fc3e0159ba"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_full_bot_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7c6204e9fa403119184f3bb29ae1c9e489acd8fccc0af1b17f0f5a6138a8af4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/client.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5c61235d78bee583dc5adbc0863149385fb28ab48524cd8ce064e6ee1f23f38"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/seed/catalog/catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4640817190ad15f559705605684b806c41ef0f87ed65a950a1efb08b77244538"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/authkey_session_layer.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5dde995b94ef8da45f731b4dbe42727fba112464438f49e984886c25651323bb"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/login_code_delivery.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"30d8e4db03a8bec2b9ef910e389a0422260927c47e841baa8e86f2e826993265"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/effects_seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"211e377a5d8c1171e9e0a53f826b83d730e7fdf7bee6845d9e8bbae945916ac2"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_notify.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4122eff27cbf0952297397363c4ac2aed64a7bfbbcc3d110db7df1a28fd7f5e3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9657867096f1d39181ba250e999f59bb3a1fc22b7acd7c1d10dd62b8df86980"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0f56cf87dd5f0eb68dfdbcbf81d9b18be710491bc22829d202f492d1616b330"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/themes.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb563b9425276f0a4d4ae8efa0e0ccdaaf8eff6cb47458ae9a3edee146dd729a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/reactions_android_compat.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc256677b906a8baf513bd5e0f45411d3af7fd2faae4bd7181db341f0df68880"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boost_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9ac3671701a391a69216f013a3f91b88bc5edcd104bfcb124ad6bff9f303169"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/webview_registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a66ce378807f93e3a546c944b3cda86a990c120153f12ce721328be77f08bcba"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/types.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c8be31e2692496a0ffdcd00d93c2d30211eb701386c3083bf72d2d29faa544b9"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/bot.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d4141ee627add33cc643c2bd6db1b2b4cd7cbef983511c3dea029f3f770805f4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/webauthn/webauthntest/authenticator.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"df8b3e586651a5e61802af5ff8ea344cf488eb023bcbf9786438de01bd09a465"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_translation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5c9a7267f09e830d8c45a785878a36f1f1698de5b595cd296eaae985fe9b137"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/seed/appearance/seed.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7d8e4b7809819ff57e02a6b967347c49c77bcaf597252aca6fe368deb9cc22c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/history_ttl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc9da1592f4215b7e800c5e90772ce165a2cc263987b7a5e63e0074079ec9157"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service_bot_entities.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"659cd0fa6a9d768beab2faa2ee6653c4f0b93eaa14d2b1a08ec854527ca9ab74"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_result_subscriber_budget.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"86184ea8f1defbf4b5b8ccd9e4b4160a434619049760fb9c3a98794e0e68eca8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/secretchat.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c9f26d5fed320e8ca96df0893a41839794d15aff8399f91997f38679a799f158"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/ephemeral_report.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d43ef1caf7f6cac8f2da03544eb81bc60ab402175c15af54ddda69569104beb4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/temp_key_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"576e9027b9d6288ec538868044e97beef7f8429bae8f37224c9b93387deb8076"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/authkey_session_layer.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8c37db1737551429d5f4c1a5e7d804d12030001770c1c84f4ada4aa1ca5a6bb"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/storage.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dae07739d8fc0c0a171b8d3cad1ef98405be82be444f707822e7f72b7772b02a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_scheduled.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d239be2fa2a8b3e63f84d8f032c48793f9b1fd097fab73729a15194e29dbd49c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_no_forwards.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"30dee165d4499a79b4ece6f14612fcde9bad0ee07afd57c23363c46f804ca3e2"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/rate_limit.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac00cf284a78688eb0311493f06f717c13bd9efb63ff93898dcc8a4fd06b4772"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forum_read.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c649b8ce7bd57ba365eb2a2660622fd5a5dd112c262e58d46d49f14c8259f8fb"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_files.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd95c8f93d560e0042474795c7d9c863a5ff8e0d04e6a8c083476a7320015657"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/moderation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"153ec34f15e8f83caf4cb58c6a8530a642fc21f348f96a34192c331ac129109b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_saved_reactions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6c66dce06a7a415b35b9c52b38e3e9bc8ac55e903083ff518d8334b534a724e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/private_media_count_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5159badaa0df5822a3af5270fe7d0f9ed822d2aba96eae996490eacbbed42fbe"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/media_codec.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"03ccb38455ad36a6eb09fe6ad7c10b893111a9cc3a84b96a237ddd7f66804b87"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/peerview/cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"41a023eab5ae915a619d38c7b85a9251d5308b0cf1bd5127e9664ad2fa54b904"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/metrics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4425809565aea6d0b79a3e4878ed400112b2ae2633464d740fae58c6458ab08f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_replay.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"751ef3640e684aa9e0183e0c435f55e51fa7a89d01154c382d2dbafcfc0cb427"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_read_typing.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"acbe71355a3a5136215b7c03eeaa65a25c70aa0ef0cee54283a160e2d12f692d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/help.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8b9194eda6a91eed7e2824925025df8a973ff69c9c34da5c47c2428d9acd04b0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/privacy_paid_messages.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"006b8327f93cef6473c1007bfe53e9be43582ddbf4e90ac0d08eba8668dbce47"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_edit.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"32fd7403fc0b38a5d108c6d253e5fa6db6c6a257d9330cdc4b17a245c747bfd0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/telegram_login.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"62a6982dbe094af3a5f83c14263cd0d9fb05299c032d3357d5b77ac1a3463a74"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_topics.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cac7d04117f4c81d76d6f5cd7cf04a26ac47dd24bb7173a0394464e2a9ed4195"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/warm.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba95e518d9768bbe05b35d3463c2de8ffd9402d520b5043fa90396e43078574e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_delete.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a6ef82e169e4c33a62e85ed2854c843ad389111377d9f4e7b007d1ae56baf206"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_row_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1f6418bd41ae78907b71616f901173eef1577f2ac7696f9d661fef5871b013d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/parser.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f90f86e729e3914dfbafb94d4ae3859ced60ffeb1b90729955b1716e8ab7caf6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_reaction_catalog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7a9043a67bc7e20ef3b823e695ce841b07fc5636a9ff5cd6645e13e0f06bbb7"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bootstrap_update_job.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcec57cd99012de9b9ce264d3a1d354999f882d8be8e0f1ff8426468c3c929c7"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/collectible_username.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8aadfbf9f744f0ce537179f9f700ce08c2ac8f4865d0cb5ac6da3438e3040a12"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/passkey.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c11064299b4ac144d4ffb60612e330e8723bd073c58a82d7606711e7aeec30f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/media_count.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"52099b68a1f27289ec4c0243b486ae78e26033a8d4fcca2020cfd72486dced38"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/crypto.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"19e888af71c593bda7ecf96323ce02be94ae03d52a5a92d566ebbd61b53957e5"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/client_telemetry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb2a8e481d85b4363bab33f95f402ec3dd4972d89a5f81e39f74dbf3d1eac9ea"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/media_count_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"99728012266cd267bfbfa546ffd0fb16ed85754ac6bcb67034b42e6a7f354876"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_ttl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c4d2580145243006464d1575ef2c776fe00234f0c2693ce52c42279f734aa70"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/contacts/read_model_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"459475c04977dd3b63c6051bd047d86ebde67043d2e91db5a28322f8c8cec5ea"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/phone/registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2b354667736947756b32f01461591c12842e9b70a8b01b25c1f27888ba7adae"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_errors.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5f82d2483e8638a8097d612ff8099934f6e8cf2fda008a8efd91a200bd4b94b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_register.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"421bbd10183aaec74269c58d6d8c7a82dc692b8a5b2aabc46d2e6210241255a3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_encrypted.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a482aff74445daca83b6a5e8bb5ad316789bdef6ea110b969414708ac74dc700"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/profile_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"a51427c6f118664bacf27b373ff9b4e97070a3d5d7eec1633a9d8ab9c8cafc9d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/dialog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b108db24115b42e6a48d93bf6e8766488db0c2c82ced8f3883d9578666a8243b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/read_model_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3111206746216b1e5af09bab5f39e2dd097e8bbb1f7503fcf66539f9f8ccb989"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/updatestate.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b83dd0267f93dbdf79ba550a92593f52c6c6894c097c06133c99a30f5cb51615"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_settings_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b8fdd5e213f1dc70e96062bfd31cce066222f2b18a579e2244438f07e97e4cb"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/channel_banned_rights.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b7c69bc4f395087313c56d3c8766b44aa2e46b157b6501299c6e182c7c87bede"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/upload_receipt.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b032c4b4751fc56cf59f0c837e19b336a0a40bfbb9a30d370019835ac7f8453d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/dispatch_context.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"096965ad0ddb081abd7db0f23282061d7dd8d45f51a6b8240efefb64ff8aeae8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/legacy.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1da5850c4ae964acf0cf42bdd4376dcf3d5650583b419fa30921675e88272d29"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/admission.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf249234cb36a2c193cea7969ea29f1b074ed919d9a8551502f9c8f23130a5fd"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral_push.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5736bbc95aa996c3964ff12bc22ccbcd0ac31d87fe75f547d97bd1fb15996eb8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/file_fixture.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"178d57a67f2bbd950e4e4b137af1a5d42f415819d0a9eae80018d5b144c8c294"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_contracts.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3146d2944e9a0e829281b516c128991cc67d595a4ca2d8b079ef59190cc86e63"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/decrypt.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7b98abea502c25f9e4ffa1a5995dc53abb267e9abe33279422046db39b76fc4b"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_hash_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"afff3dab450562df043f006c189b6df37da660b2a8302613e2dad126fc28d8ca"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound_scratch.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6de2c90d770a090595ae0a66f0c633d224275e2c4e033b4a2f14964adabcc297"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/login_code_delivery.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec80b047678440502965d8136a724db80d1262e73e22f65fe55e10d899306ecd"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/registry_reports.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"893a83da0f1795f9ab8ca9c6dee9af9f68ce26ae4bc8c4a314ff271f82389f06"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/ai.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a883b5d44f7c548ad8552bcdb9103c7ddf0bb007d3c5855c3a429b6c8e7f870"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_communities.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dfcf934986f8411d2233a8f2cf36bfb1388436a27c44d986e566d4016633fa3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_freeze_worker.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4e7eaaf5f2262aa389509120c9aa4827974b543f3d1ed21a2a42abc9cd06e98"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_reports.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"81a764aa1d030e0e8d495c3c32da072267972d59208c701560948d2799a79c80"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/privacy.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaa12316c5b50eb71abe16821779594bf174e2e88d90604878e62d061f0a5616"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/inline_registry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"8692e4a74b4ae638bf3d2322661365fe4867d6278f2b27ae763f494dbfca8d2c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/message.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"90803da3b49f87bb409eeb3129b451ee66850a0ca56cbd436fd5cc855e899f0f"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/story.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bc752287d7033e92879078474779e412cdc29b606bde10052265069e2480382"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/video_thumbnail.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c844c36e45f9a10c2bb4a89eab949590440bfd2832d64ee478bc203010bdac1c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/privacy.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fcd8701a3237a08fd833227c28ee239f4a6ad04d2c61b49ea301770a533997a9"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/saved_dialog.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2250456981dfbb1f2e900c4faefc01829a41776f27edc3e01c1151f69060b782"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/channel_errors.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"00e3634591c49f79519c48997fe67631ebd1e9d19240ed8633ddcf902b173ad8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/url.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"33fc0d29db3b9b108bc09f27dd980b0249a184c5c1b5fbdf7fa47ccb3a7c0eae"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/passkey.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6edf6ab3dc3e6f75a7aaa586100149ad1a29b592e9283ce3ae31e58a838acd15"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"01bde67cfc0414d496031edddfbc83dedb207e737c456c13c01ad8560ab42b7e"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/auth_delivery_report.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5089278498d145c69219fc0c36905e432224d52276d4cbf4d2929ff490d6465"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/inline_push.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d75dc16849cdd2ccf7d8f8e43fd9bd8e94fde5711d6fc61726e3ce31b4b4739d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_forward.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"37343bb3afe19cd276437883f907a92470d0019663909d44e54562b2856749d0"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/rich_message.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"737767b08ea8a608360cc100102f94f5304b00a63994637173bb9f1b4eb188a2"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_state_mutation.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a6f9d2eda7e40cea7d0f10bad305b20003e503fafcbe33b01684c7d35c6ef1a"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_polls.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3276006e008ecd3aae378cdebf14167306bb02e108074aa075645ffa3f0e4920"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_listener.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f28575290ff7f4c7ef5dbb0b3c8fd23054d0d4e1a2a54ba4bd9d7f4f5105dc6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/aicompose_webpage.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"750111c463a5f0bbc5d6b4ba988a9cf19c18bd799025c0598f8980d57d1bf2ca"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/translation/ai_provider.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2f11893642a6082a2d6c9c8ed2a187ff61376d395ea1a8e27a8bd731e40807a8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/message_idempotency.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0a713eed77fb03cc4ef1c0f21d5808125b03a9ff97fea40931e1513dd99064d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_ai_provider.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b5c2bd9e4dcd3ab79f2f0607ed771bddf77f8e99a07d7aede1c493490e47cef1"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/community.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"6bd3d1f2ce64b01aa393e03a9abc1aff155d9669d6fa6ef6d61a36c8590bb2d6"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_views.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"41415e2a95500181fb4ea43aa1721e0dda546a7dace40c8672b85bdde102360c"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/groupcall_sweep_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"cac9012d90ccef540ccee0ae0665431853761aedff7d54083f8f2edb570e6303"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/demux.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffe0ddc1e20a406fdf058209b3856e1331ee07b7faaa8cc87995910acd8a171d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/bot_commands.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2e548e313eb0b19d2072a7afcfcc1afbcb131f72b534ba2266af3ceef6cc612"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/destroy_auth_key.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0557e15c2909a6d4bde386c5bab9f14d79cbd50ac5791af2fd31571bec76bac4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/sticker_collection.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"b428551fcffd8e5975657a40e38c3e138f9be4565f4f634b93a301b4930efc56"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/native.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ea7a697a91a71dfe99fcdefb4b8a833d3cdfcf403dfe6315e1b5873034b9eee"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/appeal_links.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"18df1780d98421e9ea9fe5b42a2ef65de98c5c5e0a3f9c498c2a1462655a976d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/phone_change.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0aeed3a5496395228403e2acea95a80f8b4a3826b013ca1056c8bc9873180d61"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/expiry_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5b7e39ebc3543f78e2317a69209d4609bea8f0c29451196651fe62340c7f439"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/resolve_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c925cc185c25d3078a344784f61f802f572d26ae303a779474213b014aa2c907"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/defaults.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c70ce33a7f44e8a8837cc8baca1ebde3baad98e2287f8d7b3eac1f87e3cdde83"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/account_deletion.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"c40b14ec24822e296e89ca8a94b9ddd84a9c7b2a15488beb77fbb4f1ec769c73"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/read_model_versions.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d48758b56f31299d6828a44aaddbdd48f27d710704b456aa275bd91f6afb4a4"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/client_telemetry.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"aea5a5876a64f5a0d9d0ec4096056a9356b88004961d0fbc83928cdf4a4139dd"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/contact.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0aa945d50815330e77ae54e7e282495440137011dc809eed612f0c9a35683b40"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_replay_restore.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"66f06a7fec34a623aca9c5c08ed87659f9f134c036f87b2f06b160377f3c8e95"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_groupcall.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c38a7c99dd538a4fb25a8830cdbb181d777fa274996cebca781553e5ea4ff4d"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_dialogs.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b50c833b507297ca552fe2481ba16c539a802cdd7ce320ff50bfc0207a97dd8"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_member_ids_cache.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d21a7c1dbd3ba86db4c07705dfe8ed193f836efa0e349ada16fad87d9a41dab"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_games.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f75c81dc43af2dbaccf9581f20f2769e0140ccc051ae78100f3e15d2dba0b60"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/push.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5833397d3b0aabef1acb997d81658743516c0e67f21992ddc5320e73da806b18"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/communities_register.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd1a413617f81e778db678605a68ee01b1f90b86854a8d3f7bc5a2f7bcbcea37"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_history.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"460d45e86d3b72e548a19bd47773b7dc252b270e2edba57c9657e37cd7820b75"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/moderation/service.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"5220b1be405dcc7a0cde2e22ef2c55948f2ae52665646aab0e3155f010def3e9"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/ephemeral.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"31cfbf6557b54ba43874707cf63e8d0b080721d53d428b01b06c9a962ef0fe09"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/message_errors.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e5ecd0b0e8fa6a59d32638b9bfd374bba86355e09754d6c58e717f7e839a022"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_enqueue_dispatcher.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"fbfd52af54cf2828e4b6c0dea6e37e2f73ce9b215dbba3cc940809bfd2d9bf15"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/observability/dbtrace/dbtrace.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"913aa837ce1e7ce0a7c9517cb40000291458a906fe98e7c19fd8aa210e7ccc79"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/rpc_admission_tracker.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a560787a93da8ebf46b478d435350db6a2ca62a957a294e702c5d808288dfae"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/chatlist.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"d48b194d672cc40518d64b986dc21fb19eccd5c5c317b6347dc75f2862225aef"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/webpage.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bef2ec649f7d38f64a62b0f691caa845fda4eb55bad5e356ec891a93cef48c3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_history_ttl.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a7ad410af3416aa1b6906d2aa69fec13bb8c7492c08b26451e7572a94f8f0c3"}},{"ruleId":"D34","level":"note","message":{"text":"Orphaned file: No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/livestream/part.go"},"region":{"startLine":1}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d2c19f29384c3344f65f58b322b178057e2e0cec3ca6e15da2cac85c3567b4a"}},{"ruleId":"AC1","level":"warning","message":{"text":"\u003Cvideo\u003E without a captions track: Video with no captions \u003Ctrack\u003E offers no captions. This player\u0027s source is set at runtime, so there is no caption file to author here: give the player a way to carry captions \u2014 accept a track/captions URL alongside the media and render a \u003Ctrack kind=\u0022captions\u0022\u003E when one is supplied \u2014 and capture that asset wherever the media enters the product (upload, import or generation)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/chat/ChatMedia.tsx"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f26fec363ca6ca496139c340fa1d2deb308234150edbddb85ea760f01f907ec"}},{"ruleId":"AC1","level":"warning","message":{"text":"\u003Cvideo\u003E without a captions track: Video with no captions \u003Ctrack\u003E offers no captions. This player\u0027s source is set at runtime, so there is no caption file to author here: give the player a way to carry captions \u2014 accept a track/captions URL alongside the media and render a \u003Ctrack kind=\u0022captions\u0022\u003E when one is supplied \u2014 and capture that asset wherever the media enters the product (upload, import or generation)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/chat/ChatMedia.tsx"},"region":{"startLine":191}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c34f464f5005cbaf9db5fbabdee6d10566813409ef9fa9c3684f7b8d5e02302"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/EmojiPicker.tsx"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"33c69905d8d0dbd5d247ea2dc54a1ff720799603a92a82bf2348d885fa9f3c1e"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/EntityPicker.tsx"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e04cd3ee3d84966a1996b8d32d9c8e13f6bef3fb8d624ca6b3e8c0a08637600"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/EntityPicker.tsx"},"region":{"startLine":175}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c7db916cb2b8328a92229c0d8f412732f0ba35a9460872f78808d988a8381c8"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/EntityPicker.tsx"},"region":{"startLine":274}}}],"partialFingerprints":{"codehealthFindingId/v1":"45ef244119ab085ce90eb06c61fd5894507c13633a30a69b57d0c979f610c619"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/EntityPicker.tsx"},"region":{"startLine":367}}}],"partialFingerprints":{"codehealthFindingId/v1":"fd77ed9044580488d92f47d55b9e4079271594db5dd00ef33fc010408aa75e04"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/chat/AccountChats.tsx"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"66bba75b388245aec6e82bd255e223da9bf02e6635b9a61f0799bf5f97ccfaa7"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/chat/AccountChats.tsx"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"41e77b70299233e317993d31ee292b6e3a26c8932b636fc155bd5e4dd3b99569"}},{"ruleId":"AC2","level":"error","message":{"text":"Custom control with no accessible name on \u003Cimg\u003E: This \u003Cimg\u003E carries a click handler, which makes it a control, but it has no text, aria-label or labelled child (the icon-only case), so assistive tech has no name to announce for it. Note that switching it to \u003Cbutton type=\u0022button\u0022\u003E \u2014 the right fix for its keyboard operability \u2014 does not give it a name either: an icon-only button still needs one. Add visible text or an aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/chat/ChatMedia.tsx"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"e7fb3b859324d2fde1f6d032b75dbed9157880fcc29c34c4eceaf00421675abc"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cselect\u003E without a programmatic label: This control has no associated label. Add a \u003Clabel htmlFor\u003E / wrapping \u003Clabel\u003E / aria-label / aria-labelledby so assistive tech can name it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/BotVerificationPage.tsx"},"region":{"startLine":921}}}],"partialFingerprints":{"codehealthFindingId/v1":"f25717f9d258aa9c3740d912d3ab0e82a53817c50ee18ae695fa361923243622"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/DonationsPage.tsx"},"region":{"startLine":723}}}],"partialFingerprints":{"codehealthFindingId/v1":"68384eed9bd456bd6f84ee67b1d020d01e8089ec7d9b3ba6ef173c34fd1149e7"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has no associated label. Add a \u003Clabel htmlFor\u003E / wrapping \u003Clabel\u003E / aria-label / aria-labelledby so assistive tech can name it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/DonationsPage.tsx"},"region":{"startLine":729}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7713bc628034b146ca179aaf0becde52646be678428506206215da9b28692bb"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cselect\u003E without a programmatic label: This control has no associated label. Add a \u003Clabel htmlFor\u003E / wrapping \u003Clabel\u003E / aria-label / aria-labelledby so assistive tech can name it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/GifCatalogPage.tsx"},"region":{"startLine":174}}}],"partialFingerprints":{"codehealthFindingId/v1":"60e2ac3a57982f7fb8959d317a6c15e5d7ba91f13ad610cb32ab9460510fd358"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has no associated label. Add a \u003Clabel htmlFor\u003E / wrapping \u003Clabel\u003E / aria-label / aria-labelledby so assistive tech can name it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/GifCatalogPage.tsx"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac54807ed11e5e62d29b62e2d5d96bda97984edf6338c4e67c673d61360fb714"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/StickerSetPreviewModal.tsx"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"530bcc74bca0e7af7c9f0db5cdc397e0375db3c2dcf4e49ca5cce3b00234501d"}},{"ruleId":"AC2","level":"error","message":{"text":"\u003Cinput\u003E without a programmatic label: This control has only a placeholder \u2014 a placeholder is not a label (it vanishes on input and many AT ignore it). Add a \u003Clabel htmlFor\u003E, a wrapping \u003Clabel\u003E, or aria-label."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/StickerSetPreviewModal.tsx"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bf6244aa8dc6c776e3b08cf63d56f97f792e4a63ada03b3888c1f9af37a0aed"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/ActionButton.tsx"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"c53d62d2b0946dfc8eb4530769f124da6374c6cbb85d186e1dd1302314b43d9b"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/AddServerLinkModal.tsx"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"42387ac08abd53bcff45f4c4a9d85f7494da3e98e6d4235cd9d924987e05a74d"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/AvatarModal.tsx"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"ac0ff28076f6748201ecf379eb8bbe3db14a661c30bd259636e2bd01faa7949b"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/CopyBotTokenModal.tsx"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"6916a7e77ae22e35e125b1c5d125abe31eb21f1f5d93f14701215d8fe570aaaa"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/CreateBotModal.tsx"},"region":{"startLine":17}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee12d169ea9c3594e7785291633fc79df54828ed47608ec41e56b460f27e9a4c"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/CreateBroadcastModal.tsx"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a7d073e802cbd0adf826ae6e6fd34714354e7dfd06d83417224d0c5f1a819ec"}},{"ruleId":"AC4","level":"error","message":{"text":"Click handler on a non-interactive \u003Ctr\u003E: A click handler on a plain element isn\u0027t keyboard-operable. Use a \u003Cbutton\u003E, or add role \u002B tabIndex={0} \u002B a key handler."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/DataTable.tsx"},"region":{"startLine":113}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2758d319b8b0c2573c9c73eb826a10e5d77180315d6c37bbad416418e97fa79"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/MintCollectibleUsernameModal.tsx"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"c43407bfe69f9927ad22f3df980461267de09a9cf85543861f428c53f7840171"}},{"ruleId":"AC4","level":"error","message":{"text":"Hover-only interaction on \u003Cdiv\u003E: This \u003Cdiv\u003E binds mouse-enter and mouse-leave and nothing else \u2014 no click, no key handler, no focus handler, and no tabIndex={0}, so it cannot even take focus. A keyboard user cannot hover, so whatever the pair reveals or highlights is reachable with a mouse only. Bind the same state to focus/blur as well, and add tabIndex={0}=\u00220\u0022 so the element can receive that focus."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/StaticLottie.tsx"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a8fb93adf861c06dfadb96fef70a89c6c8cd82aea9393ff5d025b0c2020a0b5"}},{"ruleId":"AC4","level":"error","message":{"text":"Click handler on a non-interactive \u003Cimg\u003E: A click handler on a plain element isn\u0027t keyboard-operable. Use a \u003Cbutton\u003E, or add role \u002B tabIndex={0} \u002B a key handler."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/chat/ChatMedia.tsx"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a39237eacdf6cfc29b89b4bb8971c3813922639ab48557fb56719192ded6092"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Cdiv role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/chat/ChatMedia.tsx"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7383aa8eddfe21948d1887405f93c272d1d5bb81beb251d548779d03e2d009b"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but focus is moved into it, but nothing keeps it there: Tab walks out to the page behind, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/AdminUsersPage.tsx"},"region":{"startLine":278}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cac0eaa81ffd2ce9ced0739136ff85ab65fd3b99ea5f561798dfd10353a2305"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but focus is moved into it, but nothing keeps it there: Tab walks out to the page behind, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/AdminUsersPage.tsx"},"region":{"startLine":383}}}],"partialFingerprints":{"codehealthFindingId/v1":"db380244fbf498094f9c63e4458364a0597d48258f5023e58d926a34c207b209"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/CreateStickerSetModal.tsx"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"b498a0d0ededa8865d51bda37e80ceb30280fc004bb1d9f0bcb78904997504e9"}},{"ruleId":"AC4","level":"error","message":{"text":"Click handler on a non-interactive \u003Csection\u003E: A click handler on a plain element isn\u0027t keyboard-operable. Use a \u003Cbutton\u003E, or add role \u002B tabIndex={0} \u002B a key handler."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/Dashboard.tsx"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"e78071f089a972688d792674b768997222d094e3c96c14c3319b6c0276dd20a5"}},{"ruleId":"AC4","level":"error","message":{"text":"Click handler on a non-interactive \u003Csection\u003E: A click handler on a plain element isn\u0027t keyboard-operable. Use a \u003Cbutton\u003E, or add role \u002B tabIndex={0} \u002B a key handler."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/Dashboard.tsx"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe2d3d1d49c925c5746b83a9dd57cb6f80db4ad66dd0feed4dc1dd24df071ea8"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/DonationsPage.tsx"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bda60166862aa8e2eda41479fa355bad58f032fb5c6d48f71c026eaf5409ecd"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/DonationsPage.tsx"},"region":{"startLine":700}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dea7304f8fef5528132e161772e93df102dc2fcee308ac66da89501b9a05e69"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/DonationsPage.tsx"},"region":{"startLine":814}}}],"partialFingerprints":{"codehealthFindingId/v1":"d76d2be018c43464f2e256b8c6c283bc52165e42c58557bdbb33da6583edafe7"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/DonationsPage.tsx"},"region":{"startLine":908}}}],"partialFingerprints":{"codehealthFindingId/v1":"535f7b9a96458d60dadfbb7828a5abee2f1ac481dd4150c1effd77d632431de2"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/GifCatalogPage.tsx"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2aeb09b54ba45b01ed9621d7ba6a8e88905a6ac2d9680dbfe13f47f87001afd"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/GiftCollectiblesModal.tsx"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"40c1ba172295c3dd7908849e68ad6620fb0d9e7a79fce760f3b9e1c516182908"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/GiftPacks.tsx"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"d466199f4549d7a2316242331431d9382144edfd157da8af0a4e09a20e71bdf3"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/ServerSettingsPage.tsx"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"b8998b9eddf2773e4fc1527a95d9b3b724cf31e68ffc4f9ab3038b9c250e8df3"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/ServerSettingsPage.tsx"},"region":{"startLine":784}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e957d1a57a64cdfd4a187b5591315387256338a358f18c00b7258bb284b68e0"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/StarGiftCatalogPage.tsx"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"13665aa843f30777a33ab77be98f4b69ca00a79bfc1dac82b0d0af4835a98b4a"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/StickerSetPreviewModal.tsx"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"3dab3de267c0f870a7af7c140a553aea09c2d3360f501319224578e92fa1ede1"}},{"ruleId":"AC4","level":"warning","message":{"text":"Modal dialog does not manage focus: This \u003Csection role=\u0022dialog\u0022\u003E is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native \u003Cdialog\u003E opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/StoragePage.tsx"},"region":{"startLine":322}}}],"partialFingerprints":{"codehealthFindingId/v1":"f680c82a22bf3e821544120cfc39e1a288ea9aeb521d62a981622033d4da5fda"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.nav-section-chevron\u0060 moves (\u0060transition: transform 140ms ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/01-foundation.css"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"957cd04ea9351468f6aacca324a9c74b1b848b04d6c759931dc53050b62987f5"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060a.stat-tile.clickable\u0060 moves (\u0060transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/02-pages-and-forms.css"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"87a4e002dbb0ac08e5e9c78b61bbf834d43580fea52980801070dac46f9c02fd"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.launcher\u0060 moves (\u0060transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/02-pages-and-forms.css"},"region":{"startLine":299}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0cc736a4e93cde95c78323e13b95ed60895fa28bcb31e5cf51a95f813a19cfb"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.give-gift-option\u0060 moves (\u0060transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":445}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ddc2cf4a7dd730fc5d3c132918554095029dfe6fb589dd940a5b6a0fba03103"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.gift-bulk-import-progress-bar \u003E div\u0060 moves (\u0060transition: width .2s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":472}}}],"partialFingerprints":{"codehealthFindingId/v1":"53fd829f704a23bf6c8daeb6cf46a0a5f5acd94764189d901a427fefea65f804"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.official-gift-option\u0060 moves (\u0060transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":500}}}],"partialFingerprints":{"codehealthFindingId/v1":"6514a33c66f83b8b8dcbbc9c30d6e40e558504de96e3838581d8729cada76c1b"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.gift-switch-track span\u0060 moves (\u0060transition: transform .16s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":593}}}],"partialFingerprints":{"codehealthFindingId/v1":"527669785fe1f8218d1dba2be76f9589045804cacbd76698f9311ee4300ad43f"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.chain-toggle span\u0060 moves (\u0060transition: transform .16s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"dfba8770d971183920063d6481f94d2e163fa23026b590778db0f83a6c088273"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.chain-preset-card\u0060 moves (\u0060transition: border-color .12s ease, transform .12s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":611}}}],"partialFingerprints":{"codehealthFindingId/v1":"460a43d9c9e8c8686800b140f4a3a0b982cdf508a289fdcb242a6bc7f9d304f2"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.gift-pack-cover .gift-pack-anim\u0060 moves (\u0060transition: transform .2s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":843}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3de44e1c28c7e7abfca15e8dacd4cb613c04aa46cb591f356f35078f1852d8b"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.gift-pack-tile\u0060 moves (\u0060transition: border-color .15s ease, transform .15s ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":867}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4b8cb83ef5c6fe0e30434555217a60df43ab9cc0122756b5f5f03727fe96a3c"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.env-group-chevron\u0060 moves (\u0060transition: transform 140ms ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":1208}}}],"partialFingerprints":{"codehealthFindingId/v1":"df70e3410ac44d5657111f6c94aec107dd234e850f865e03a5b41e4370d8ec81"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.restart-overlay-spin\u0060 moves (\u0060animation: spin 1.4s linear infinite\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/03-entities-and-actions.css"},"region":{"startLine":1279}}}],"partialFingerprints":{"codehealthFindingId/v1":"5112a2d9f3d25eb55c50d050c345211026b72791ff832afd23ee5a9aaee8931e"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.bg-orb--1\u0060 moves (\u0060animation: loginOrbFloat1 20s ease-in-out infinite\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/04-modal-and-login.css"},"region":{"startLine":299}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cafad49469f468347034281ad8a24e4cd774d11cc7efd275d196499a39dcfa3"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.bg-orb--2\u0060 moves (\u0060animation: loginOrbFloat2 24s ease-in-out infinite\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/04-modal-and-login.css"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"dff23e54dd5bbcc358463f8999e91ffff3ad52dc99004d7e21b55e2e3a9fe812"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.bg-orb--3\u0060 moves (\u0060animation: loginOrbFloat3 28s ease-in-out infinite\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/04-modal-and-login.css"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"890072603cd327cc7f52a3893738e1119da87e7faf38cfe22ba99b2e4d8b31be"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.loader-bar::before\u0060 moves (\u0060animation: load 1s infinite ease-in-out\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/04-modal-and-login.css"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1aa82397bc31005e767a20f0fd1c23ad32bc81ae2e8eedaa837bbd3ff172714"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.spin\u0060 moves (\u0060animation: spin 0.8s linear infinite\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/04-modal-and-login.css"},"region":{"startLine":572}}}],"partialFingerprints":{"codehealthFindingId/v1":"2362ff097a8be64e067dad8867fc01047c207d9a9ed1be116feedac60182f9b1"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.switch-track::after\u0060 moves (\u0060transition: transform 140ms ease\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/06-refresh.css"},"region":{"startLine":1332}}}],"partialFingerprints":{"codehealthFindingId/v1":"795651f91c15ff927b9054296ecd62fae7d8e3220816feca3b0f7ab120af976e"}},{"ruleId":"AC6","level":"warning","message":{"text":"Animation without a prefers-reduced-motion guard: \u0060.give-tile\u0060 moves (\u0060transition: border-color 0.12s, background 0.12s, transform 0.12s\u0060) and nothing reads prefers-reduced-motion for it \u2014 no @media (prefers-reduced-motion) rule for this element, no reset this project loads \u2014 so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/styles/08-economy.css"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"c1c009000663456883c1866d9041ce2af885886e6060b342e22f0ab46972d531"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: BotVerificationService (16 methods): \u0060BotVerificationService\u0060 declares 16 methods: \u0060Icons\u0060, \u0060UpsertIcon\u0060, \u0060SetIconActive\u0060, \u0060Verifiers\u0060, \u0060VerifierSettings\u0060, \u0060GrantVerifier\u0060, \u0060SetVerifierEnabled\u0060, \u0060RevokeVerifier\u0060, \u0060Marks\u0060, \u0060RevokeMark\u0060, \u0060Requests\u0060, \u0060Request\u0060, \u0060RequestCounts\u0060, \u0060Approve\u0060, \u0060Reject\u0060, \u0060RevokeRequest\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"5d9a126b72f12636a53a4585eb938744a9671c6196ec12a45bfe819c7688a392"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: Service (119 methods): \u0060Service\u0060 declares 119 methods: \u0060AccountAvatar\u0060, \u0060SetAccountFrozen\u0060, \u0060GrantPremium\u0060, \u0060GrantStars\u0060, \u0060UpsertPremiumPlan\u0060, \u0060RefundPremium\u0060, \u0060UpdateDonationChain\u0060, \u0060CreateDonationChain\u0060, \u0060DeleteDonationChain\u0060, \u0060SweepDonationChain\u0060, \u0060UpsertDonationToken\u0060, \u0060DeleteDonationToken\u0060, \u0060DonationChainBalance\u0060, \u0060DonationPricePreview\u0060, \u0060DonationStarPriceMicros\u0060, \u0060SetVerified\u0060, \u0060SetUserFlags\u0060, \u0060SetChannelVerified\u0060, \u0060SetChannelFlags\u0060, \u0060CreateBot\u0060, \u0060CreateBroadcast\u0060, \u0060DeleteBot\u0060, \u0060ExportBotToken\u0060, \u0060SetSupport\u0060, \u0060SetUsername\u0060, \u0060SetProfile\u0060, \u0060SetPhone\u0060, \u0060SetLoginEmail\u0060, \u0060SetAccountAvatar\u0060, \u0060SetAccountAvatarVideo\u0060, \u0060ChannelAvatar\u0060, \u0060SetChannelAvatar\u0060, \u0060SetUserColor\u0060, \u0060SetUserEmojiStatus\u0060, \u0060SetChannelSettings\u0060, \u0060SetChannelUsername\u0060, \u0060SetChannelColor\u0060, \u0060SetChannelEmojiStatus\u0060, \u0060RevokeSessions\u0060, \u0060DeletePrivateMessages\u0060, and 79 more. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"810bef7d0f9c687b679c972f2d225709e36162cd17c15b6e884e32cab8b51808"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: AuthService (22 methods): \u0060AuthService\u0060 declares 22 methods: \u0060BindTempAuthKey\u0060, \u0060ResolveAuthKey\u0060, \u0060UserID\u0060, \u0060PendingPasswordUserID\u0060, \u0060CompletePasswordSignIn\u0060, \u0060SendCode\u0060, \u0060CodeDelivery\u0060, \u0060ResendCode\u0060, \u0060CancelCode\u0060, \u0060SignIn\u0060, \u0060SignInWithEmail\u0060, \u0060SignUp\u0060, \u0060AcceptLoginToken\u0060, \u0060BindVerifiedLogin\u0060, \u0060SignInBot\u0060, \u0060LogOut\u0060, \u0060Authorization\u0060, \u0060AuthKeyClientInfo\u0060, \u0060UpdateAuthKeyClientInfo\u0060, \u0060ListAuthorizations\u0060, \u0060ResetAuthorization\u0060, \u0060ResetAuthorizations\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1256223e4b50e8447f02318542fb6c1d3563fff8c2f4094d0e997bb333e51f2"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: BotsService (37 methods): \u0060BotsService\u0060 declares 37 methods: \u0060BotInfo\u0060, \u0060OwnsBot\u0060, \u0060CheckUsername\u0060, \u0060CreateBot\u0060, \u0060ListOwnedBots\u0060, \u0060ExportBotToken\u0060, \u0060SetBotCommands\u0060, \u0060GetBotCommands\u0060, \u0060SetBotInfo\u0060, \u0060GetBotInfo\u0060, \u0060SetBotMenuButton\u0060, \u0060GetBotMenuButton\u0060, \u0060SetInlinePlaceholder\u0060, \u0060CanSendMessage\u0060, \u0060AllowSendMessage\u0060, \u0060UpsertBotApp\u0060, \u0060GetBotAppByID\u0060, \u0060GetBotAppByShortName\u0060, \u0060GetMainBotApp\u0060, \u0060ListBotApps\u0060, \u0060GetBotAppSettings\u0060, \u0060UpsertBotAppSettings\u0060, \u0060ListBotAppPreviewMedia\u0060, \u0060UpsertBotAppPreviewMedia\u0060, \u0060DeleteBotAppPreviewMedia\u0060, \u0060ReorderBotAppPreviewMedia\u0060, \u0060UpsertAttachMenuBot\u0060, \u0060GetAttachMenuBot\u0060, \u0060ListAttachMenuBots\u0060, \u0060GetAttachMenuState\u0060, \u0060SetAttachMenuState\u0060, \u0060SaveRequestedWebViewButton\u0060, \u0060GetRequestedWebViewButton\u0060, \u0060DeleteRequestedWebViewButton\u0060, \u0060SetBotEmojiStatusPermission\u0060, \u0060BotEmojiStatusPermission\u0060, \u0060PutWebViewCustomMethodQuery\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":346}}}],"partialFingerprints":{"codehealthFindingId/v1":"dbea971d621e97d555fe1340ad5f599362705a68ca63d3662bd64f1668bc4f63"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: AccountService (27 methods): \u0060AccountService\u0060 declares 27 methods: \u0060SendChangePhoneCode\u0060, \u0060ChangePhone\u0060, \u0060GetPassword\u0060, \u0060GetPasswordSettings\u0060, \u0060UpdatePasswordSettings\u0060, \u0060CheckPassword\u0060, \u0060IssueTmpPassword\u0060, \u0060CheckTmpPassword\u0060, \u0060RevenueWithdrawalPasswordState\u0060, \u0060RequestPasswordRecovery\u0060, \u0060CheckRecoveryPassword\u0060, \u0060RecoverPassword\u0060, \u0060ConfirmPasswordEmail\u0060, \u0060ResendPasswordEmail\u0060, \u0060CancelPasswordEmail\u0060, \u0060SendLoginEmailCode\u0060, \u0060VerifyLoginEmail\u0060, \u0060SetLoginEmail\u0060, \u0060LoginEmail\u0060, \u0060LoginEmailByPhone\u0060, \u0060ClearLoginEmail\u0060, \u0060ResetPassword\u0060, \u0060DeclinePasswordReset\u0060, \u0060SaveMusic\u0060, \u0060ListSavedMusicIDs\u0060, \u0060ListSavedMusic\u0060, \u0060GetSavedMusicByIDs\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":469}}}],"partialFingerprints":{"codehealthFindingId/v1":"5def930eeff3a11b90e77e09163fd0ad6a2d1df1beacbcd5da36c2085cb3d08c"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: AccountBusinessAutomationService (25 methods): \u0060AccountBusinessAutomationService\u0060 declares 25 methods: \u0060GetBusinessProfile\u0060, \u0060UpdateBusinessWorkHours\u0060, \u0060UpdateBusinessLocation\u0060, \u0060UpdateBusinessIntro\u0060, \u0060UpdateBusinessGreetingMessage\u0060, \u0060UpdateBusinessAwayMessage\u0060, \u0060ListBusinessChatLinks\u0060, \u0060CreateBusinessChatLink\u0060, \u0060EditBusinessChatLink\u0060, \u0060DeleteBusinessChatLink\u0060, \u0060ResolveBusinessChatLink\u0060, \u0060ListQuickReplies\u0060, \u0060CheckQuickReplyShortcut\u0060, \u0060SaveQuickReplyText\u0060, \u0060GetQuickReplyMessages\u0060, \u0060RenameQuickReplyShortcut\u0060, \u0060ReorderQuickReplies\u0060, \u0060DeleteQuickReplyShortcut\u0060, \u0060DeleteQuickReplyMessages\u0060, \u0060GetConnectedBusinessBot\u0060, \u0060SaveConnectedBusinessBot\u0060, \u0060DeleteConnectedBusinessBot\u0060, \u0060SetConnectedBusinessBotPaused\u0060, \u0060DisableConnectedBusinessBotForPeer\u0060, \u0060GetConnectedBusinessBotPeerState\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":502}}}],"partialFingerprints":{"codehealthFindingId/v1":"07faa2389385a3788243f8f0421c9e7f053255fa3e7ea83122972e90534cd7a2"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: UpdatesService (33 methods): \u0060UpdatesService\u0060 declares 33 methods: \u0060GetState\u0060, \u0060CurrentState\u0060, \u0060ConfirmedState\u0060, \u0060ObserveDifferenceRequest\u0060, \u0060GetDifference\u0060, \u0060CommitDeliveredState\u0060, \u0060ClearAuthKey\u0060, \u0060RecordNewMessage\u0060, \u0060PublishNewMessage\u0060, \u0060RecordStory\u0060, \u0060RecordStoryFanout\u0060, \u0060RecordReadStories\u0060, \u0060RecordSentStoryReaction\u0060, \u0060RecordNewStoryReaction\u0060, \u0060RecordQuickReplyMutation\u0060, \u0060RecordReadHistory\u0060, \u0060RecordContactsReset\u0060, \u0060RecordChannelState\u0060, \u0060RecordDialogPinned\u0060, \u0060RecordPinnedDialogs\u0060, \u0060RecordSavedDialogPinned\u0060, \u0060RecordPinnedSavedDialogs\u0060, \u0060RecordDialogUnreadMark\u0060, \u0060RecordPeerSettings\u0060, \u0060RecordNotifySettings\u0060, \u0060RecordPeerStoryBlocked\u0060, \u0060RecordDialogFilter\u0060, \u0060RecordDialogFilterOrder\u0060, \u0060RecordDialogFiltersReload\u0060, \u0060RecordFolderPeers\u0060, \u0060RecordChannelViewForumAsMessages\u0060, \u0060RecordChannelDiscussionInbox\u0060, \u0060RecordDraftMessage\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":573}}}],"partialFingerprints":{"codehealthFindingId/v1":"f88d8b752d74a5916b54f83c40ea8f6a7a88215ef9814edf9d74588e233ac579"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: ContactsService (17 methods): \u0060ContactsService\u0060 declares 17 methods: \u0060GetContacts\u0060, \u0060ContactIDs\u0060, \u0060AddContact\u0060, \u0060AcceptContact\u0060, \u0060ImportContacts\u0060, \u0060Search\u0060, \u0060DeleteContacts\u0060, \u0060EditCloseFriends\u0060, \u0060UpdateContactNote\u0060, \u0060SetPersonalPhoto\u0060, \u0060ClearPersonalPhoto\u0060, \u0060PersonalPhotos\u0060, \u0060GetPeerSettings\u0060, \u0060BlockContact\u0060, \u0060UnblockContact\u0060, \u0060IsBlocked\u0060, \u0060GetBlocked\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":617}}}],"partialFingerprints":{"codehealthFindingId/v1":"a44b6b24c5dd4a02f4d4bb16e67b1268611ec65f9d788d5eef7e8ce897482409"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: DialogsService (21 methods): \u0060DialogsService\u0060 declares 21 methods: \u0060GetDialogsHash\u0060, \u0060GetDialogs\u0060, \u0060GetPeerDialogs\u0060, \u0060SaveDraft\u0060, \u0060GetDraft\u0060, \u0060DeleteDraft\u0060, \u0060ListDrafts\u0060, \u0060ClearDrafts\u0060, \u0060TogglePinned\u0060, \u0060ToggleArchivePinned\u0060, \u0060ReorderPinned\u0060, \u0060MarkUnread\u0060, \u0060UnreadMarks\u0060, \u0060HidePeerSettingsBar\u0060, \u0060PeerSettingsBarHidden\u0060, \u0060GetDialogFolders\u0060, \u0060SaveDialogFolder\u0060, \u0060DeleteDialogFolder\u0060, \u0060ReorderDialogFolders\u0060, \u0060ToggleDialogFolderTags\u0060, \u0060EditPeerFolders\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":638}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9d662fe0821417e7c011e960372a6e6a309384ec0bb5031c18014ba9dd43267"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: MessagesService (30 methods): \u0060MessagesService\u0060 declares 30 methods: \u0060SendPrivateText\u0060, \u0060SetChatTheme\u0060, \u0060ForwardPrivateMessages\u0060, \u0060GetMessages\u0060, \u0060GetHistory\u0060, \u0060Search\u0060, \u0060SearchPrivateMedia\u0060, \u0060CountPrivateMediaCategories\u0060, \u0060ReadHistory\u0060, \u0060ReadMessageContents\u0060, \u0060GetOutboxReadDate\u0060, \u0060SetMessageReactions\u0060, \u0060GetMessageReactions\u0060, \u0060SavedReactionTags\u0060, \u0060UpdateSavedReactionTag\u0060, \u0060VoteMessagePoll\u0060, \u0060CloseMessagePoll\u0060, \u0060ListUnreadReactionMessages\u0060, \u0060ReadPeerReactions\u0060, \u0060EditMessage\u0060, \u0060PinPrivateMessage\u0060, \u0060UnpinAllPrivateMessages\u0060, \u0060DeleteMessages\u0060, \u0060DeleteHistory\u0060, \u0060GetSavedDialogs\u0060, \u0060GetPinnedSavedDialogs\u0060, \u0060GetSavedDialogsByPeers\u0060, \u0060ToggleSavedDialogPin\u0060, \u0060ReorderPinnedSavedDialogs\u0060, \u0060DeleteSavedHistory\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":678}}}],"partialFingerprints":{"codehealthFindingId/v1":"baee4a9191538fde57554bff6ea1b2ca34b81ef867965d0feb3d45a65d5084da"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: StoriesService (28 methods): \u0060StoriesService\u0060 declares 28 methods: \u0060CreateStory\u0060, \u0060GetAllStories\u0060, \u0060GetAllStoriesPage\u0060, \u0060GetAllStoriesDigest\u0060, \u0060ListOwnerActiveStories\u0060, \u0060GetPeerStories\u0060, \u0060GetStoriesByID\u0060, \u0060GetStoriesArchive\u0060, \u0060GetPinnedStories\u0060, \u0060HasPinnedStories\u0060, \u0060ListReadStates\u0060, \u0060GetPeerMaxIDs\u0060, \u0060GetPeerHiddenStates\u0060, \u0060GetPeerStoryProjections\u0060, \u0060ReadStories\u0060, \u0060IncrementViews\u0060, \u0060SendReaction\u0060, \u0060GetStoryViewsList\u0060, \u0060GetStoryReactionsList\u0060, \u0060GetStoryPublicForwards\u0060, \u0060CanViewStoryStats\u0060, \u0060ListStoryViewerIDs\u0060, \u0060EditStory\u0060, \u0060DeleteStories\u0060, \u0060TogglePinned\u0060, \u0060TogglePinnedToTop\u0060, \u0060TogglePeerStoriesHidden\u0060, \u0060CanSendStory\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":734}}}],"partialFingerprints":{"codehealthFindingId/v1":"51ba5504bc3938e31cd4d4cefddc61a640d330259c0a9b36d54b88fc4d515c3d"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: ChannelsService (137 methods): \u0060ChannelsService\u0060 declares 137 methods: \u0060CreateMegagroupFromCreateChat\u0060, \u0060CreateChannel\u0060, \u0060GetChannel\u0060, \u0060ResolveChannel\u0060, \u0060GetChannels\u0060, \u0060GetJoinableChannel\u0060, \u0060GetParticipants\u0060, \u0060GetParticipant\u0060, \u0060FutureCreatorAfterLeave\u0060, \u0060InviteToChannel\u0060, \u0060JoinChannel\u0060, \u0060LeaveChannel\u0060, \u0060EditTitle\u0060, \u0060SetWallpaper\u0060, \u0060EditAbout\u0060, \u0060EditAdmin\u0060, \u0060TransferOwnership\u0060, \u0060EditMemberRank\u0060, \u0060EditBanned\u0060, \u0060EditDefaultBannedRights\u0060, \u0060DeleteChannel\u0060, \u0060CheckUsername\u0060, \u0060UpdateUsername\u0060, \u0060ListAdminedPublicChannels\u0060, \u0060ListCommunityLinkableChannels\u0060, \u0060ListStoryPostableChannels\u0060, \u0060ListSendAsChannels\u0060, \u0060ResolvePublicUsername\u0060, \u0060SearchPublicChannels\u0060, \u0060SetSignatures\u0060, \u0060SetPhoto\u0060, \u0060SetPreHistoryHidden\u0060, \u0060SetParticipantsHidden\u0060, \u0060SetForum\u0060, \u0060SetAutotranslation\u0060, \u0060SetRestrictedSponsored\u0060, \u0060SetPaidMessagesPrice\u0060, \u0060SetAntiSpam\u0060, \u0060SetSlowMode\u0060, \u0060SetBoostsToUnblockRestrictions\u0060, and 97 more. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":766}}}],"partialFingerprints":{"codehealthFindingId/v1":"f83bb4e1bbbec29b277531b4c3982eff8fb09ce28c03f40e1809b9e7ee1758b9"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: CommunitiesService (21 methods): \u0060CommunitiesService\u0060 declares 21 methods: \u0060Create\u0060, \u0060Get\u0060, \u0060GetMany\u0060, \u0060ListJoined\u0060, \u0060TogglePeerLink\u0060, \u0060SetCollapsed\u0060, \u0060ListPeerLinkRequests\u0060, \u0060DecidePeerLinkRequest\u0060, \u0060DecideAllPeerLinkRequests\u0060, \u0060ToggleParticipantBanned\u0060, \u0060ParticipantJoinedChats\u0060, \u0060Participants\u0060, \u0060EditTitle\u0060, \u0060EditAbout\u0060, \u0060EditAdmin\u0060, \u0060EditDefaultBannedRights\u0060, \u0060SetPhoto\u0060, \u0060Delete\u0060, \u0060SetPinned\u0060, \u0060ReorderPinned\u0060, \u0060SearchScope\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":926}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b05f8d2cefcfebf87ad2a68c523e1bfb807eef2c296fe7b71a060790d3c5442"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: FilesService (45 methods): \u0060FilesService\u0060 declares 45 methods: \u0060SaveFilePart\u0060, \u0060SaveBigFilePart\u0060, \u0060GetFile\u0060, \u0060CreateEncryptedFileFromUpload\u0060, \u0060DeleteEncryptedFileBlob\u0060, \u0060GeoMapTile\u0060, \u0060ListAvailableReactions\u0060, \u0060AvailableEffects\u0060, \u0060GetDocuments\u0060, \u0060ResolveStickerSet\u0060, \u0060ListStickerSets\u0060, \u0060CheckStickerSetShortName\u0060, \u0060SuggestStickerSetShortName\u0060, \u0060CreateStickerSet\u0060, \u0060ListCreatedStickerSets\u0060, \u0060AddStickerToSet\u0060, \u0060RemoveStickerFromSet\u0060, \u0060ChangeStickerPosition\u0060, \u0060RenameStickerSet\u0060, \u0060DeleteStickerSet\u0060, \u0060CreatePhotoFromUpload\u0060, \u0060CreatePhotoFromBytes\u0060, \u0060CreatePhotoFromURL\u0060, \u0060CreateDocumentFromURL\u0060, \u0060ResolveWebPage\u0060, \u0060WebPagePreviewEnabled\u0060, \u0060LookupWebPage\u0060, \u0060CreateAvatarFromUpload\u0060, \u0060CreateAvatarVideoFromUpload\u0060, \u0060CreateAvatarVideoMarkupFromUpload\u0060, \u0060CreateAvatarMarkup\u0060, \u0060CreateDocumentFromUpload\u0060, \u0060CreateDocumentFromBytes\u0060, \u0060GetPhoto\u0060, \u0060GetDocument\u0060, \u0060UploadProfilePhoto\u0060, \u0060UploadProfilePhotoKind\u0060, \u0060SetCurrentProfilePhoto\u0060, \u0060SetCurrentProfilePhotoKind\u0060, \u0060CurrentProfilePhoto\u0060, and 5 more. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":952}}}],"partialFingerprints":{"codehealthFindingId/v1":"0693dacd599abfefcee35f8968b706d8718fef86407981b97ee135d9fb415773"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: GiftsService (50 methods): \u0060GiftsService\u0060 declares 50 methods: \u0060Catalog\u0060, \u0060CatalogHash\u0060, \u0060GiftByID\u0060, \u0060GiftRevisionByID\u0060, \u0060CollectiblePreview\u0060, \u0060CollectiblePreviewSample\u0060, \u0060CollectibleAvailability\u0060, \u0060UniqueBySlug\u0060, \u0060UniqueByID\u0060, \u0060UniqueByIDs\u0060, \u0060ListUniqueByOwner\u0060, \u0060Upgrade\u0060, \u0060UpgradeReceipt\u0060, \u0060RecordSavedGift\u0060, \u0060ListSaved\u0060, \u0060ListSavedFiltered\u0060, \u0060GetSaved\u0060, \u0060ResolveSavedIDs\u0060, \u0060CountSaved\u0060, \u0060ToggleSaved\u0060, \u0060ConvertAggregate\u0060, \u0060ListCollections\u0060, \u0060CreateCollection\u0060, \u0060UpdateCollection\u0060, \u0060DeleteCollection\u0060, \u0060ReorderCollections\u0060, \u0060SetPinned\u0060, \u0060ListResale\u0060, \u0060ValueInfo\u0060, \u0060SetListing\u0060, \u0060Transfer\u0060, \u0060PurchaseResale\u0060, \u0060SendOffer\u0060, \u0060ResolveOffer\u0060, \u0060ListCraft\u0060, \u0060Craft\u0060, \u0060AuctionState\u0060, \u0060ActiveAuctions\u0060, \u0060AuctionAcquired\u0060, \u0060BidAuction\u0060, and 10 more. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":1259}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d0dcd94ce07fb8faed3784f71753275544196ac54e56b6f6239533986fa92fa"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: GroupCallsService (30 methods): \u0060GroupCallsService\u0060 declares 30 methods: \u0060Create\u0060, \u0060RtmpStreamKey\u0060, \u0060StartScheduled\u0060, \u0060SetScheduleSubscription\u0060, \u0060ScheduleSubscriberIDs\u0060, \u0060CreateConference\u0060, \u0060Get\u0060, \u0060GetBySlug\u0060, \u0060GetByInviteMessage\u0060, \u0060Join\u0060, \u0060Leave\u0060, \u0060RemoveConferenceParticipants\u0060, \u0060Discard\u0060, \u0060Touch\u0060, \u0060Participant\u0060, \u0060Participants\u0060, \u0060UpdateParticipant\u0060, \u0060SetTitle\u0060, \u0060SetJoinMuted\u0060, \u0060SetStartedMessageID\u0060, \u0060SweepStale\u0060, \u0060ResetAllParticipants\u0060, \u0060NextRaiseHandRating\u0060, \u0060SetParticipantOverride\u0060, \u0060ParticipantOverride\u0060, \u0060CreateConferenceInvite\u0060, \u0060SetConferenceInviteStatus\u0060, \u0060ConferenceRecipients\u0060, \u0060AppendChainBlock\u0060, \u0060ChainBlocks\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/deps.go"},"region":{"startLine":1379}}}],"partialFingerprints":{"codehealthFindingId/v1":"42b107fea112c75604a2991dd8ad5a00203029a1dc78bb5828fc1fde5dc1b877"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: BusinessAutomationStore (24 methods): \u0060BusinessAutomationStore\u0060 declares 24 methods: \u0060HasBusinessAutomation\u0060, \u0060GetBusinessProfile\u0060, \u0060SaveBusinessProfile\u0060, \u0060ListBusinessChatLinks\u0060, \u0060CreateBusinessChatLink\u0060, \u0060UpdateBusinessChatLink\u0060, \u0060DeleteBusinessChatLink\u0060, \u0060ResolveBusinessChatLink\u0060, \u0060ListQuickReplies\u0060, \u0060CheckQuickReplyShortcut\u0060, \u0060SaveQuickReplyText\u0060, \u0060GetQuickReplyMessages\u0060, \u0060RenameQuickReplyShortcut\u0060, \u0060ReorderQuickReplies\u0060, \u0060DeleteQuickReplyShortcut\u0060, \u0060DeleteQuickReplyMessages\u0060, \u0060ReserveBusinessAutomationDelivery\u0060, \u0060LastBusinessAutomationDelivery\u0060, \u0060GetConnectedBusinessBot\u0060, \u0060SaveConnectedBusinessBot\u0060, \u0060DeleteConnectedBusinessBot\u0060, \u0060SetConnectedBusinessBotPaused\u0060, \u0060DisableConnectedBusinessBotForPeer\u0060, \u0060GetConnectedBusinessBotPeerState\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/account.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"ba425a7c0952f811da0be0838a5fe20b06638d7ddd01076ab15131b40b61f48e"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: BotStore (39 methods): \u0060BotStore\u0060 declares 39 methods: \u0060CreateBotAccount\u0060, \u0060GetBot\u0060, \u0060ListBotsByOwner\u0060, \u0060CountBotsByOwner\u0060, \u0060UpdateBotTokenSecret\u0060, \u0060UpdateBotCommands\u0060, \u0060UpdateBotInfo\u0060, \u0060UpdateBotMenuButton\u0060, \u0060SetBotInlinePlaceholder\u0060, \u0060SetBotInlineGeo\u0060, \u0060SetBotNochats\u0060, \u0060SetBotChatHistory\u0060, \u0060CanBotSendMessage\u0060, \u0060AllowBotSendMessage\u0060, \u0060UpsertBotApp\u0060, \u0060GetBotAppByID\u0060, \u0060GetBotAppByShortName\u0060, \u0060GetMainBotApp\u0060, \u0060ListBotApps\u0060, \u0060GetBotAppSettings\u0060, \u0060UpsertBotAppSettings\u0060, \u0060ListBotAppPreviewMedia\u0060, \u0060UpsertBotAppPreviewMedia\u0060, \u0060DeleteBotAppPreviewMedia\u0060, \u0060ReorderBotAppPreviewMedia\u0060, \u0060UpsertAttachMenuBot\u0060, \u0060GetAttachMenuBot\u0060, \u0060ListAttachMenuBots\u0060, \u0060GetAttachMenuState\u0060, \u0060SetAttachMenuState\u0060, \u0060SaveRequestedWebViewButton\u0060, \u0060GetRequestedWebViewButton\u0060, \u0060DeleteRequestedWebViewButton\u0060, \u0060SetBotEmojiStatusPermission\u0060, \u0060BotEmojiStatusPermission\u0060, \u0060PutWebViewCustomMethodQuery\u0060, \u0060GetBotChatState\u0060, \u0060UpsertBotChatState\u0060, \u0060DeleteBotChatState\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/bot.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"779162b794060306ec5779f90bc298c1b9d8b8b1296c63ddfdf0182ae0f45bbd"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: BotVerificationStore (25 methods): \u0060BotVerificationStore\u0060 declares 25 methods: \u0060UpsertVerificationIcon\u0060, \u0060SetVerificationIconActive\u0060, \u0060VerificationIcon\u0060, \u0060VerificationIconByDocument\u0060, \u0060ListVerificationIcons\u0060, \u0060UpsertBotVerifierSettings\u0060, \u0060SetBotVerifierEnabled\u0060, \u0060DeleteBotVerifierSettings\u0060, \u0060BotVerifierSettings\u0060, \u0060BotVerifierSettingsBatch\u0060, \u0060ListBotVerifiers\u0060, \u0060GrantCustomVerification\u0060, \u0060RevokeCustomVerification\u0060, \u0060CustomVerification\u0060, \u0060PeerVerification\u0060, \u0060PeerVerificationBatch\u0060, \u0060CountCustomVerifications\u0060, \u0060ListCustomVerifications\u0060, \u0060CreateCustomVerificationRequest\u0060, \u0060DecideCustomVerificationRequest\u0060, \u0060CustomVerificationRequest\u0060, \u0060PendingCustomVerificationRequest\u0060, \u0060ListCustomVerificationRequests\u0060, \u0060CustomVerificationRequestsForApplicant\u0060, \u0060CustomVerificationRequestCounts\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/bot_verification.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"50ddb0c530009049356357f34aa6bf0551de855a3ad499a2f517bbc41a73f558"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: ChannelStore (153 methods): \u0060ChannelStore\u0060 declares 153 methods: \u0060CreateChannel\u0060, \u0060GetChannel\u0060, \u0060ResolveChannel\u0060, \u0060GetChannels\u0060, \u0060GetChannelByID\u0060, \u0060SaveChannelDefaultSendAs\u0060, \u0060GetParticipants\u0060, \u0060GetParticipant\u0060, \u0060FutureCreatorAfterLeave\u0060, \u0060InviteToChannel\u0060, \u0060JoinChannel\u0060, \u0060LeaveChannel\u0060, \u0060EditChannelTitle\u0060, \u0060SetChannelWallpaper\u0060, \u0060EditChannelAbout\u0060, \u0060EditChannelAdmin\u0060, \u0060TransferChannelOwnership\u0060, \u0060EditChannelMemberRank\u0060, \u0060EditChannelBanned\u0060, \u0060EditChannelDefaultBannedRights\u0060, \u0060DeleteChannel\u0060, \u0060CheckUsername\u0060, \u0060UpdateUsername\u0060, \u0060SetChannelVerified\u0060, \u0060SetChannelScamFake\u0060, \u0060SetChannelAdminSettings\u0060, \u0060SetChannelUsernameAdmin\u0060, \u0060SetChannelColorAdmin\u0060, \u0060SetChannelEmojiStatusAdmin\u0060, \u0060SetChannelPhotoAdmin\u0060, \u0060ListAdminedPublicChannels\u0060, \u0060ListCommunityLinkableChannels\u0060, \u0060ListStoryPostableChannels\u0060, \u0060ListSendAsChannels\u0060, \u0060ResolvePublicChannelUsername\u0060, \u0060ResolvePublicChannelInvite\u0060, \u0060SearchPublicChannels\u0060, \u0060SetSignatures\u0060, \u0060SetChannelPhoto\u0060, \u0060SetPreHistoryHidden\u0060, and 113 more. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/channel.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"445e635a4ba9885818deaf2ab6f5d217d6e7e1c8d04dd530ef5226f93cbe1c2e"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: CommunityStore (21 methods): \u0060CommunityStore\u0060 declares 21 methods: \u0060CreateCommunity\u0060, \u0060GetCommunity\u0060, \u0060GetCommunities\u0060, \u0060ListJoinedCommunities\u0060, \u0060ToggleCommunityPeerLink\u0060, \u0060SetCommunityCollapsed\u0060, \u0060ListCommunityPeerLinkRequests\u0060, \u0060DecideCommunityPeerLinkRequest\u0060, \u0060DecideAllCommunityPeerLinkRequests\u0060, \u0060ToggleCommunityParticipantBanned\u0060, \u0060GetCommunityParticipantJoinedChats\u0060, \u0060ListCommunityParticipants\u0060, \u0060EditCommunityTitle\u0060, \u0060EditCommunityAbout\u0060, \u0060EditCommunityAdmin\u0060, \u0060EditCommunityDefaultBannedRights\u0060, \u0060SetCommunityPhoto\u0060, \u0060DeleteCommunity\u0060, \u0060SetCommunityPinned\u0060, \u0060ReorderCommunityPinned\u0060, \u0060CommunitySearchScope\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/community.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"5251d73e03da500b73e43585854dae2c60d9422226f041062d723803327c2c5a"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: ContactStore (16 methods): \u0060ContactStore\u0060 declares 16 methods: \u0060ListByUser\u0060, \u0060Get\u0060, \u0060GetMany\u0060, \u0060GetReverseContacts\u0060, \u0060ContactProjectionForViewers\u0060, \u0060Upsert\u0060, \u0060UpsertMany\u0060, \u0060UpdateNote\u0060, \u0060SetCloseFriends\u0060, \u0060SetPersonalPhoto\u0060, \u0060PersonalPhotos\u0060, \u0060Delete\u0060, \u0060Block\u0060, \u0060Unblock\u0060, \u0060IsBlocked\u0060, \u0060ListBlocked\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"02c10631360eb5d9cf65b4fa00f9c5cc053210395c4f103652198dd37054bba5"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: DialogStore (30 methods): \u0060DialogStore\u0060 declares 30 methods: \u0060ListByUser\u0060, \u0060ListByPeers\u0060, \u0060Upsert\u0060, \u0060UpsertInbox\u0060, \u0060SaveDraft\u0060, \u0060GetDraft\u0060, \u0060DeleteDraft\u0060, \u0060ListDrafts\u0060, \u0060ListDraftsByPeers\u0060, \u0060ClearDrafts\u0060, \u0060MarkRead\u0060, \u0060SetPinned\u0060, \u0060ReorderPinned\u0060, \u0060SetUnreadMark\u0060, \u0060ListUnreadMarked\u0060, \u0060SetChatTheme\u0060, \u0060SetPeerSettingsBarHidden\u0060, \u0060PeerSettingsBarHidden\u0060, \u0060SetTranslationDisabled\u0060, \u0060TranslationDisabled\u0060, \u0060ListFolders\u0060, \u0060GetFolder\u0060, \u0060UpsertFolder\u0060, \u0060DeleteFolder\u0060, \u0060ReorderFolders\u0060, \u0060SetFolderTagsEnabled\u0060, \u0060EditPeerFolders\u0060, \u0060CountArchiveUnread\u0060, \u0060SetArchivePinned\u0060, \u0060ArchivePinned\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/dialog.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ce869b1b6d4a8f17145cffd38055a01e2e378a71b526f51576b63d76e8b780c"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: DonationStore (25 methods): \u0060DonationStore\u0060 declares 25 methods: \u0060WalletSeed\u0060, \u0060CreateWalletSeed\u0060, \u0060DonationAddressForUser\u0060, \u0060DonationUserByAddress\u0060, \u0060NextDonationAddressIndex\u0060, \u0060InsertDonationAddress\u0060, \u0060ListDonationAddresses\u0060, \u0060CreateDonationChain\u0060, \u0060DeleteDonationChain\u0060, \u0060EnabledDonationChains\u0060, \u0060DonationChain\u0060, \u0060UpdateDonationChainConfig\u0060, \u0060SetDonationChainPrice\u0060, \u0060DonationTokens\u0060, \u0060AllDonationTokens\u0060, \u0060UpsertDonationToken\u0060, \u0060DeleteDonationToken\u0060, \u0060DonationChainCursor\u0060, \u0060SetDonationChainCursor\u0060, \u0060RecordDonationDeposit\u0060, \u0060UpdateDonationDepositConfirmations\u0060, \u0060PendingDonationDeposits\u0060, \u0060ConfirmedUncreditedDeposits\u0060, \u0060CreditDonationDeposit\u0060, \u0060UserDonationDeposits\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/donations.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"02109a8b683e0d5e58ec8ac51d5e7bd260ae780b52f882b272f29abd232de42a"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: GroupCallStore (31 methods): \u0060GroupCallStore\u0060 declares 31 methods: \u0060CreateGroupCall\u0060, \u0060CreateConferenceCall\u0060, \u0060GetGroupCall\u0060, \u0060GetGroupCallBySlug\u0060, \u0060GetGroupCallByInviteMessage\u0060, \u0060JoinGroupCall\u0060, \u0060LeaveGroupCall\u0060, \u0060RemoveConferenceCallParticipants\u0060, \u0060DiscardGroupCall\u0060, \u0060TouchParticipant\u0060, \u0060GetParticipant\u0060, \u0060ListParticipants\u0060, \u0060UpdateParticipant\u0060, \u0060SetGroupCallTitle\u0060, \u0060SetGroupCallJoinMuted\u0060, \u0060SetStartedMessageID\u0060, \u0060SweepStaleParticipants\u0060, \u0060ResetAllParticipants\u0060, \u0060NextRaiseHandRating\u0060, \u0060SetParticipantOverride\u0060, \u0060GetParticipantOverride\u0060, \u0060CreateConferenceInvite\u0060, \u0060SetConferenceInviteStatus\u0060, \u0060ListConferenceRecipientUserIDs\u0060, \u0060AppendGroupCallChainBlock\u0060, \u0060ListGroupCallChainBlocks\u0060, \u0060GetRtmpStreamKey\u0060, \u0060SetRtmpStreamKey\u0060, \u0060StartScheduledGroupCall\u0060, \u0060SetScheduleStartSubscription\u0060, \u0060ListScheduleSubscriberIDs\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/groupcall.go"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"2382dbfe7a4366a3f71c94f1353fa9b4c133a2e60d64579a4a7725bb33f34c61"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: InlineRegistryStore (17 methods): \u0060InlineRegistryStore\u0060 declares 17 methods: \u0060PutInlinePending\u0060, \u0060GetInlinePending\u0060, \u0060DeleteInlinePending\u0060, \u0060PutInlineResult\u0060, \u0060GetInlineResult\u0060, \u0060DeleteInlineResult\u0060, \u0060PutInlineCache\u0060, \u0060GetInlineCache\u0060, \u0060PutInlineWebDocument\u0060, \u0060GetInlineWebDocument\u0060, \u0060PutInlineWebDocumentBytes\u0060, \u0060PutPreparedInlineMessage\u0060, \u0060GetPreparedInlineMessage\u0060, \u0060PutWebViewSession\u0060, \u0060GetWebViewSession\u0060, \u0060GetWebViewSessionByBotQuery\u0060, \u0060DeleteWebViewSession\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/inline_registry.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"8493439f8ecf51eaeb81c58ba14873385fe9230365d0f9f523766f6efbb7fa58"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: MediaStore (45 methods): \u0060MediaStore\u0060 declares 45 methods: \u0060SaveFilePart\u0060, \u0060UploadPartUsage\u0060, \u0060UploadPartSlot\u0060, \u0060LoadFileParts\u0060, \u0060DeleteFileParts\u0060, \u0060DeleteExpiredUploadParts\u0060, \u0060GetUploadedMediaReceipt\u0060, \u0060PutUploadedMediaReceipt\u0060, \u0060PutFileBlob\u0060, \u0060GetFileBlob\u0060, \u0060GetFileBlobs\u0060, \u0060SumFileBlobBytes\u0060, \u0060DeleteFileBlobRow\u0060, \u0060GetSeedState\u0060, \u0060PutSeedState\u0060, \u0060PutDocument\u0060, \u0060GetDocument\u0060, \u0060GetDocuments\u0060, \u0060PutPhoto\u0060, \u0060GetPhoto\u0060, \u0060PutWebPage\u0060, \u0060GetWebPageByURLHash\u0060, \u0060PutStickerSet\u0060, \u0060CreateStickerSet\u0060, \u0060UpdateStickerSet\u0060, \u0060DeleteStickerSet\u0060, \u0060AdminDeleteStickerSet\u0060, \u0060GetStickerSetByID\u0060, \u0060GetStickerSetByShortName\u0060, \u0060GetStickerSetBySystemKey\u0060, \u0060ListStickerSets\u0060, \u0060ListStickerSetsByCreator\u0060, \u0060StickerSetShortNameAvailable\u0060, \u0060CountStickerSets\u0060, \u0060PutAvailableReaction\u0060, \u0060ListAvailableReactions\u0060, \u0060CountAvailableReactions\u0060, \u0060AddProfilePhotoKind\u0060, \u0060CurrentProfilePhotoKind\u0060, \u0060CurrentProfilePhotos\u0060, and 5 more. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/media.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"1babb64379b1bde976b3ffcad21f0dd5f1f9e5b35f56c94291065b59883036ad"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: MessageStore (27 methods): \u0060MessageStore\u0060 declares 27 methods: \u0060Create\u0060, \u0060SendPrivateText\u0060, \u0060ForwardPrivateMessages\u0060, \u0060ReadHistory\u0060, \u0060ReadMessageContents\u0060, \u0060GetOutboxReadDate\u0060, \u0060SetMessageReactions\u0060, \u0060GetMessageReactions\u0060, \u0060ListSavedReactionTags\u0060, \u0060UpsertSavedReactionTag\u0060, \u0060VoteMessagePoll\u0060, \u0060CloseMessagePoll\u0060, \u0060EditMessage\u0060, \u0060PinPrivateMessage\u0060, \u0060UnpinAllPrivateMessages\u0060, \u0060DeleteMessages\u0060, \u0060DeleteHistory\u0060, \u0060GetByIDs\u0060, \u0060ListByUser\u0060, \u0060SearchPrivateMedia\u0060, \u0060CountPrivateMediaCategories\u0060, \u0060ListSavedDialogs\u0060, \u0060ListPinnedSavedDialogs\u0060, \u0060ListSavedDialogsByPeers\u0060, \u0060ToggleSavedDialogPin\u0060, \u0060ReorderPinnedSavedDialogs\u0060, \u0060DeleteSavedHistory\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/message.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"11fc9cca778e27b14bfda0491db36f6b315e381920d1c819093a773389367345"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: StarGiftStore (32 methods): \u0060StarGiftStore\u0060 declares 32 methods: \u0060Catalog\u0060, \u0060CatalogGift\u0060, \u0060CatalogRevision\u0060, \u0060CreateCatalogRevision\u0060, \u0060CreateCatalogBundle\u0060, \u0060SetCatalogEnabled\u0060, \u0060SetCatalogSortOrder\u0060, \u0060AnimationJSON\u0060, \u0060PublishCollectibleRevision\u0060, \u0060ActiveCollectibleRevision\u0060, \u0060ActiveCollectibleProjection\u0060, \u0060CollectibleAvailability\u0060, \u0060CollectibleAnimationJSON\u0060, \u0060UniqueBySlug\u0060, \u0060UniqueByID\u0060, \u0060UniqueByIDs\u0060, \u0060ListUniqueByOwner\u0060, \u0060Create\u0060, \u0060ListByOwner\u0060, \u0060ListByOwnerFiltered\u0060, \u0060GetByRef\u0060, \u0060ResolveUserMessageRef\u0060, \u0060ResolveSavedIDs\u0060, \u0060CountByOwner\u0060, \u0060SetUnsaved\u0060, \u0060MarkConverted\u0060, \u0060ListCollections\u0060, \u0060CreateCollection\u0060, \u0060UpdateCollection\u0060, \u0060DeleteCollection\u0060, \u0060ReorderCollections\u0060, \u0060SetPinned\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/star_gift.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"89eba8907b23663fbb7454bae589eeef84879a64930efcb6b2fd2bb84ba68eeb"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: StarGiftLifecycleStore (37 methods): \u0060StarGiftLifecycleStore\u0060 declares 37 methods: \u0060IssueStarGiftPurchaseForm\u0060, \u0060ValidateStarGiftPurchaseForm\u0060, \u0060PurchaseStarGift\u0060, \u0060ConvertStarGift\u0060, \u0060ListResaleStarGifts\u0060, \u0060UniqueStarGiftValueInfo\u0060, \u0060SetStarGiftListing\u0060, \u0060TransferStarGift\u0060, \u0060PurchaseResaleStarGift\u0060, \u0060SendStarGiftOffer\u0060, \u0060ResolveStarGiftOffer\u0060, \u0060ListCraftStarGifts\u0060, \u0060CraftStarGift\u0060, \u0060StarGiftAuctionState\u0060, \u0060ActiveStarGiftAuctions\u0060, \u0060StarGiftAuctionAcquired\u0060, \u0060BidStarGiftAuction\u0060, \u0060PrepaidUpgradeTarget\u0060, \u0060PrepayStarGiftUpgrade\u0060, \u0060DropStarGiftOriginalDetails\u0060, \u0060SetStarGiftNotifications\u0060, \u0060StarGiftNotificationsEnabled\u0060, \u0060RecordStarGiftWithdrawal\u0060, \u0060ResolveStarGiftWithdrawal\u0060, \u0060CompleteStarGiftWithdrawal\u0060, \u0060IssueChannelRevenueWithdrawal\u0060, \u0060ResolveChannelRevenueWithdrawal\u0060, \u0060CompleteChannelRevenueWithdrawal\u0060, \u0060TonBalance\u0060, \u0060TonTransactions\u0060, \u0060ChannelStarsBalance\u0060, \u0060ChannelStarsOverallRevenue\u0060, \u0060ChannelStarsTransactions\u0060, \u0060ChannelTonBalance\u0060, \u0060ChannelTonOverallRevenue\u0060, \u0060ChannelTonTransactions\u0060, \u0060SweepStarGiftLifecycle\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/star_gift.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"c967f673f026507854e03a5a1b328e7a461f2d5de1f9d7116763a6898d83103c"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: StoryStore (29 methods): \u0060StoryStore\u0060 declares 29 methods: \u0060CreateStory\u0060, \u0060UpsertStory\u0060, \u0060ListActiveStories\u0060, \u0060ListActiveStoriesPage\u0060, \u0060ActiveStoriesDigest\u0060, \u0060ListOwnerActiveStories\u0060, \u0060GetPeerStories\u0060, \u0060GetStoriesByID\u0060, \u0060ListPinnedStories\u0060, \u0060HasPinnedStories\u0060, \u0060ListStoriesArchive\u0060, \u0060ListReadStates\u0060, \u0060GetPeerMaxIDs\u0060, \u0060GetPeerHiddenStates\u0060, \u0060GetPeerStoryProjections\u0060, \u0060ActiveStoryPeerExpirations\u0060, \u0060ListHiddenStoryPeers\u0060, \u0060MarkRead\u0060, \u0060IncrementViews\u0060, \u0060SetReaction\u0060, \u0060ListStoryViews\u0060, \u0060ListStoryReactions\u0060, \u0060ListStoryPublicForwards\u0060, \u0060ListStoryViewerIDs\u0060, \u0060EditStory\u0060, \u0060DeleteStories\u0060, \u0060TogglePinned\u0060, \u0060TogglePinnedToTop\u0060, \u0060SetPeerHidden\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/story.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"7f1ba15b8f575c5c132d6a4b14234a10b56c3ab770bd57ffabdc72a026cbf2cf"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: TelegramLoginStore (29 methods): \u0060TelegramLoginStore\u0060 declares 29 methods: \u0060CreateTelegramLoginClient\u0060, \u0060UpsertTelegramLoginClient\u0060, \u0060GetTelegramLoginClient\u0060, \u0060GetTelegramLoginClientByBot\u0060, \u0060RotateTelegramLoginClientSecret\u0060, \u0060SetTelegramLoginClientSigningAlgorithm\u0060, \u0060SetTelegramLoginClientEnabled\u0060, \u0060AddTelegramLoginAllowedURL\u0060, \u0060DeleteTelegramLoginAllowedURL\u0060, \u0060ListTelegramLoginAllowedURLs\u0060, \u0060IsTelegramLoginURLAllowed\u0060, \u0060UpsertTelegramLoginNativeApp\u0060, \u0060DeleteTelegramLoginNativeApp\u0060, \u0060ListTelegramLoginNativeApps\u0060, \u0060CreateTelegramLoginRequest\u0060, \u0060GetTelegramLoginRequest\u0060, \u0060GetTelegramLoginRequestByTokenHash\u0060, \u0060GetTelegramLoginRequestByBrowserTokenHash\u0060, \u0060ApproveTelegramLoginRequest\u0060, \u0060DeclineTelegramLoginRequest\u0060, \u0060PutTelegramLoginAuthorizationCode\u0060, \u0060GetTelegramLoginAuthorizationCodeByRequest\u0060, \u0060GetTelegramLoginAuthorizationCodeByHash\u0060, \u0060ConsumeTelegramLoginAuthorizationCode\u0060, \u0060ConsumeTelegramLoginDirectToken\u0060, \u0060ListTelegramLoginWebAuthorizations\u0060, \u0060RevokeTelegramLoginWebAuthorization\u0060, \u0060RevokeAllTelegramLoginWebAuthorizations\u0060, \u0060DeleteExpiredTelegramLoginArtifacts\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/telegram_login.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"40285c40c6e7fcc48bacbe9cfa88b7ce49fbd86e342c0c872cbeb0f9803895d3"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: UserStore (21 methods): \u0060UserStore\u0060 declares 21 methods: \u0060ByID\u0060, \u0060ByIDs\u0060, \u0060ByPhone\u0060, \u0060ByPhones\u0060, \u0060ByEmail\u0060, \u0060ByUsername\u0060, \u0060Search\u0060, \u0060UpdateProfile\u0060, \u0060UpdateUsername\u0060, \u0060UpdatePhone\u0060, \u0060UpdateLastSeen\u0060, \u0060Create\u0060, \u0060SetPremiumUntil\u0060, \u0060SetVerified\u0060, \u0060SetScamFake\u0060, \u0060SetSupport\u0060, \u0060SweepExpiredPremium\u0060, \u0060UpdateEmojiStatus\u0060, \u0060UpdateColor\u0060, \u0060UpdateBirthday\u0060, \u0060UpdatePersonalChannel\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/user.go"},"region":{"startLine":10}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2a6fa154d8ac9f03af46dcc1b6ce467886990da0f18730bf6a3c2054e9e424c"}},{"ruleId":"AX6","level":"note","message":{"text":"Fat interface: VerificationStore (18 methods): \u0060VerificationStore\u0060 declares 18 methods: \u0060CreateVerificationDraft\u0060, \u0060SaveVerificationDraft\u0060, \u0060SubmitVerificationApplication\u0060, \u0060CancelVerificationApplication\u0060, \u0060ClaimVerificationApplication\u0060, \u0060DecideVerificationApplication\u0060, \u0060RevokeVerification\u0060, \u0060VerificationApplication\u0060, \u0060ActiveVerificationApplicationForTarget\u0060, \u0060VerificationDraftForApplicant\u0060, \u0060ListVerificationApplications\u0060, \u0060VerificationApplicationsForApplicant\u0060, \u0060VerificationStatusCounts\u0060, \u0060VerificationApplicationEvents\u0060, \u0060LastVerificationRejection\u0060, \u0060PendingVerificationNotifications\u0060, \u0060MarkVerificationNotificationDelivered\u0060, \u0060MarkVerificationNotificationFailed\u0060. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. A wide interface forces every implementer and caller to depend on methods they don\u0027t use (the Interface-Segregation \u0027I\u0027 in SOLID). Split it into focused role-interfaces."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/verification.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"718d9cd95e0ee89a45c484c0dd2151b058cbb56ce8c3894f9206c6c55a6dc2f4"}},{"ruleId":"DM2","level":"note","message":{"text":"Primitive id on a domain type: StarGiftCatalogWrite.GiftID: \u0060StarGiftCatalogWrite.GiftID\u0060 is a raw \u0060int64\u0060 \u2014 give it a strongly-typed id: a dedicated single-field type wrapping the \u0060int64\u0060, in whatever form your language spells that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":884}}}],"partialFingerprints":{"codehealthFindingId/v1":"e6678b2fe6f9bafd66fe67941e92bd9ce4965b10ca35152516c3e7f16bb05cbd"}},{"ruleId":"DM2","level":"note","message":{"text":"Primitive id on a domain type: StarGiftCatalogWrite.CommandID: \u0060StarGiftCatalogWrite.CommandID\u0060 is a raw \u0060string\u0060 \u2014 give it a strongly-typed id: a dedicated single-field type wrapping the \u0060string\u0060, in whatever form your language spells that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":895}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b97b73408ed775457d79ca1fe6ba973732c890e1a661b7e4289870c9f038361"}},{"ruleId":"DM2","level":"note","message":{"text":"Primitive id on a domain type: StarGiftCatalogWrite.OfficialGiftID: \u0060StarGiftCatalogWrite.OfficialGiftID\u0060 is a raw \u0060int64\u0060 \u2014 give it a strongly-typed id: a dedicated single-field type wrapping the \u0060int64\u0060, in whatever form your language spells that."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":896}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fe150a54a473fd12bb5facc9ccc96c951b15add29361d550df52df4ebd4a1f4"}},{"ruleId":"DM5","level":"note","message":{"text":"Mutable entity: StarGiftCatalogWrite: \u0060StarGiftCatalogWrite\u0060 exposes publicly writable state (GiftID, Title, Stars, ConvertStars, Enabled, SortOrder, and 32 more)."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":883}}}],"partialFingerprints":{"codehealthFindingId/v1":"7be479b997190b2c346ece972ac64e555bbd189397f895f6776779bd0ee51a02"}},{"ruleId":"M2","level":"note","message":{"text":"No ADRs: No Architecture Decision Records found \u2014 no conventional ADR directory, no numbered \u0060NNNN-title\u0060 documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"670b3d6e36a756d63097d0dfbf90afd5fc761308800b9354894a07c3f4e4aa14"}},{"ruleId":"M2","level":"note","message":{"text":"No architecture diagram/doc: No C4/Structurizr/PlantUML/Mermaid/Graphviz/D2 diagram, no drawn diagram named for the architecture, no file named \u0060architecture\u0060 or \u0060design\u0060 in any markup this check reads, and nothing in the README, docs or contributor guides that announces the shape \u2014 no \u0060## Architecture\u0060 heading, no \u0022architecture overview\u0022/\u0022high-level design\u0022 phrasing, no \u0022the architecture is \u2026\u0022 introduction, no guided code tour. A shape laid out in prose that never names itself as the architecture is not visible to this check, and neither is one kept outside the repository, so this row reports the absence of a re-findable shape document \u2014 not evidence that nobody wrote the shape down."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"0c190e7c159d1850ee706c3ac4486e151e8a4fe169de4bf61436b9f399654f06"}},{"ruleId":"P1","level":"warning","message":{"text":"No CI pipeline: No CI workflow found (.github/workflows, azure-pipelines.yml, .gitlab-ci.yml, \u2026) \u2014 changes aren\u0027t gated by an automated build/test."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"44f01af96e50474fba2df84d95ddf4f7e1d34c29c307830b9efc9057daa6b670"}},{"ruleId":"P3","level":"note","message":{"text":"No SAST: No static application security testing detected. For this repository\u0027s stack, add gosec / govulncheck (or golangci-lint) (or \u0060semgrep --config=auto\u0060, which runs on any language) \u2014 this repository has no CI pipeline yet, so run it locally to clear the existing findings, then make it a step of the first workflow you add so a regression fails the build. What was searched, so you can tell an absence from a miss: the 0 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge\u0027s web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen \u2014 if that is your case the row is wrong, and saying so is more useful than adding a second scanner."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"6e54424179c892f03ef2fd003130ac4bd43f39bbf3b1ca0a0143e25acb80ec87"}},{"ruleId":"P3","level":"note","message":{"text":"No dependency-update automation: \u0060cmd/telesrv-admin/web/package.json\u0060 declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices \u2014 including after an advisory is published against it. Add a \u0060.github/dependabot.yml\u0060 with one \u0060package-ecosystem\u0060 entry per ecosystem the tree uses (or an enabled \u0060renovate.json\u0060), and gate pull requests with \u0060actions/dependency-review-action\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/package.json"},"region":{"startLine":11}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f4c1f79416f72c076d4f8ce33361f343559410ee8b48c72b0d8528cc856c405"}},{"ruleId":"P5","level":"warning","message":{"text":"No DR/backup evidence: A persistence guard (data volume / purge-protection) was found, but no backup, geo-recovery or RTO/RPO controls were evidenced \u2014 a volume that survives a container recreate is not a tested restore from catastrophic loss."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"5daabb38c90b07af65b8738cf94ce884e90a7d8fef810d341de5c186188c8fe0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!allowPrivate \u0026\u0026 isBlockedExternalIP(ip)\u0060 appears character-identically in 2 files \u2014 internal/app/files/external_media.go, internal/app/files/webpage.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"d630d8407f2fdb36478df25a1c0712e8801a191655ca3b2deb30835d5376ba78"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!alreadyKicked || len(result.ChannelBans) \u003E 0 || len(result.RemovedLinks) \u003E 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/community.go, internal/store/postgres/community.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":779}}}],"partialFingerprints":{"codehealthFindingId/v1":"6123c19d3adb2c3585737726ab2cac6d9dc33008ef4d16ed531b0fb702ddbada"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!canManageForumTopic(channel, member, topic, req.UserID, 0) \u0026\u0026 !canDeleteAnyChannelMessage(member)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":384}}}],"partialFingerprints":{"codehealthFindingId/v1":"b878838ee2d637dc54597f37c0ae16c47b1c3da9648edd42b108fc8284a6e16e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!channel.Broadcast \u0026\u0026 !channel.Megagroup\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_core.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":34}}}],"partialFingerprints":{"codehealthFindingId/v1":"a73bca8e360055395b922e1b90ea601e73b3b6c0ba5c251cbc553386159fe44c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!channel.Broadcast || !channel.Signatures\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_send.go, internal/store/postgres/channel_message_send.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":412}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b6d0e479d5774180134a063227e4ddccaa41f92a031c2de9a00b166e4f1de54"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!channel.Forum || channel.Broadcast || !channel.Megagroup\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":87}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca77f7f954e313a315a3e4baff3c41cbd36116c39bcdfb5d9afbd77ae4efa706"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!channel.Megagroup || !canBanChannelUsers(member)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_join_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":765}}}],"partialFingerprints":{"codehealthFindingId/v1":"5036b1b579b8a9872dd32575bce0332857129ba4a81ca64ca40e54c4d2aea2c4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!channel.Megagroup || !canChangeChannelInfo(member)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":509}}}],"partialFingerprints":{"codehealthFindingId/v1":"c24e5b99db1103d9970a5f517ceba1d90ff3427e4324df53d2c4e824050e4c83"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!channel.Megagroup || !canExportChannelInvite(member)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_join_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":784}}}],"partialFingerprints":{"codehealthFindingId/v1":"a73ddeb3fa5d33c961dc28bf6a06c17b31d39d823b1c968e5a46964dedf72d6b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!channel.Megagroup || channel.ParticipantsHidden || channel.ParticipantsCount \u003E domain.MaxChannelReadParticipants\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_read.go, internal/store/postgres/channel_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"0213fb2af6c548441ef15a70f64ed080aff91478fcd6d75e695f076a6fc03f31"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!channel.PreHistoryHidden \u0026\u0026 member.AvailableMinID \u003E 0 \u0026\u0026 member.HistoryClearAnchorID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/memory/channel_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9d1db2d86f463a06ad1e97311305790b380fd7259c79576b93c37d5ac4139e9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!found || target.ID == 0 || target.ID == userID\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_compat.go, internal/rpc/photos.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_compat.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba3d20fe26f2c8755aa308a758ce5a0c514f5e3cc762f91e4d3fe34b5a8f904"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!from.Valid() || !to.Valid() || from == to\u0060 appears character-identically in 2 files \u2014 internal/domain/bot_verification.go, internal/domain/verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/bot_verification.go"},"region":{"startLine":266}}}],"partialFingerprints":{"codehealthFindingId/v1":"030145059c6e375bcad9e3cc681a69321c6a3ce6f643b71fe425d9c89334b351"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!m.ExpiresAt.IsZero() \u0026\u0026 !now.Before(m.ExpiresAt)\u0060 appears character-identically in 2 files \u2014 internal/domain/botapi_update.go, internal/domain/ephemeral.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/botapi_update.go"},"region":{"startLine":117}}}],"partialFingerprints":{"codehealthFindingId/v1":"29b30ee2b1f4ab8684b39daaa3a46f5bda34dcb87de253c2ed47491d4d10ac99"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || channel.Deleted || (!channel.Broadcast \u0026\u0026 !channel.Megagroup)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/memory/channel_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae12797072588c8b66d4b1bd9cbea8d7e5a01645242f679bfa6f6421617e8530"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || in.ID == 0 || r.deps.Files == nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/account.go, internal/rpc/messages_stickers_personal.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":628}}}],"partialFingerprints":{"codehealthFindingId/v1":"78be89e0b1c817d1a7b8a1a7aa12bcd9f920471194351ae4a58beadf93de440c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || member.Status != domain.ChannelMemberActive\u0060 appears character-identically in 3 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/memory/channel_helpers.go, internal/store/memory/channel_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"bab1dc8bbaaba27b943a37c5a52588fc72daacf95236ae699d3cd65705f31541"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || member.Status != domain.ChannelMemberActive || member.BannedRights.ViewMessages\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/memory/channel_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":695}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a87e5298d128aed895daf31da7e3868d3bf940e982bba370f8325871bbbe2ab"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || mono.Deleted || !mono.Monoforum || mono.LinkedMonoforumID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_monoforum.go, internal/store/memory/channel_suggested_post.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":202}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c68cddf139f75dec4fc087b1fb43e3d83c9be34c45f141be54609f9332266f9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || msg.Deleted || msg.ID \u003C= member.AvailableMinID\u0060 appears character-identically in 3 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/channel_reactions.go, internal/store/memory/channel_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":485}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc03e044fc736d71fd653c9c851be0f70c0f47fb8a33bb62c7db646982da8200"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || participant.Type != domain.PeerTypeUser || participant.ID == 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_legacy_chat.go, internal/rpc/channels_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":435}}}],"partialFingerprints":{"codehealthFindingId/v1":"b4bf357aacd4d932427d97f0b9ee747fc7ccd72537dd749398600cab5333b240"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || peer.Type != domain.PeerTypeUser || peer.ID == 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_legacy_chat.go, internal/rpc/channels_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_legacy_chat.go"},"region":{"startLine":474}}}],"partialFingerprints":{"codehealthFindingId/v1":"07990aefc6986f2615bfe4b2b470f6f910d6bb316afb112302dd87aed840ad11"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ok || req.RequestMsgID \u003C 0 || req.RequestMsgID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_no_forwards.go, internal/store/postgres/message_no_forwards.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_no_forwards.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"021ec73c4c12c04d572095fe52d53fd0216b2cddc282f1abf73fc46a75dc8b6b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!preview \u0026\u0026 member.AvailableMinPts \u003E req.Pts\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_updates.go, internal/store/postgres/channel_updates.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"4db9d04967ad633707b8fa4613bf873ae6692aa8385bff42b1c565b60268c31a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!ref.CheckAccessHash || r.deps.Channels == nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_stubs.go, internal/rpc/messages_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":619}}}],"partialFingerprints":{"codehealthFindingId/v1":"8536354d7fccdc1e391681e11e7e0f4e41861bacb91f8fad60a5ca585281e5f7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!req.AllowTodoParticipantMutation || req.SetReplyMarkup || req.Media == nil || req.Media.Kind != domain.MessageMediaKindTodo || req.Media.To\u2026\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/memory/message_edit.go, internal/store/postgres/channel_message_edit.go, internal/store/postgres/message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"32a463728e763810e757851a46a31a3792aff9312086006cd5621284be212f49"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!scope.Valid() || s.scopes[scope] != hash\u0060 appears character-identically in 2 files \u2014 internal/store/memory/auth.go, internal/store/memory/login_code.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth.go"},"region":{"startLine":629}}}],"partialFingerprints":{"codehealthFindingId/v1":"4fb2e13b4b5b1cbaced8cb7c5b9b45a51100899dd0158ef1707e611f975a5bed"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!source.Broadcast || source.LinkedChatID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_core.go, internal/store/postgres/channel_core.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":169}}}],"partialFingerprints":{"codehealthFindingId/v1":"df1827d2043b9e2bd61a8985d46d9e4082dc1bcbc013dd2a860d82e8d486062f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!split || err != nil || targetID \u003C= 0 || !targetType.Valid()\u0060 appears character-identically in 2 files \u2014 internal/app/bots/verifierbot.go, internal/app/bots/verifybot.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":660}}}],"partialFingerprints":{"codehealthFindingId/v1":"1b203eb6c04e9d631195a5061d72638290e7bbb28b30e63c711d86bc86354523"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!status.Authorized || status.User == nil || status.User.ID != record.UserID\u0060 appears character-identically in 2 files \u2014 internal/loadharness/run.go, internal/loadharness/seed.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":612}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a78bac22b8d4d1ee17799e73a4dbf4a7d646df39a4e10158fdb0808ad11a13b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!status.Valid() || status == domain.CustomVerificationPending\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":614}}}],"partialFingerprints":{"codehealthFindingId/v1":"771334504f46991de62a79a1996201c3952a19e9b6409085ab5604dfb1eba0dc"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!upd.SetName \u0026\u0026 !upd.SetAbout \u0026\u0026 !upd.SetDescription\u0060 appears character-identically in 2 files \u2014 internal/app/bots/service.go, internal/rpc/bots.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/service.go"},"region":{"startLine":879}}}],"partialFingerprints":{"codehealthFindingId/v1":"1232601475110906182d50f30150b0954b0c974cf828b6c6790c2ae3cc2ac09c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!validStarGiftOwner(owner) || len(refs) \u003E domain.MaxStarGiftCollectionItems\u0060 appears character-identically in 2 files \u2014 internal/store/memory/star_gift.go, internal/store/postgres/star_gift.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":505}}}],"partialFingerprints":{"codehealthFindingId/v1":"403c7c13faccea3dede75365780263cfd0d4abe8b6cca1b9500fd597bd9de7fd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060(!want.ChangeInfo || have.ChangeInfo) \u0026\u0026 (!want.PostMessages || have.PostMessages) \u0026\u0026 (!want.EditMessages || have.EditMessages) \u0026\u0026 (!want.De\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":642}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef1af734d71764aeaae3f9fd73d71d8d0745c5748e847032ae5d6038fc932da6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060(r \u003E= \u0027A\u0027 \u0026\u0026 r \u003C= \u0027Z\u0027) || (r \u003E= \u00270\u0027 \u0026\u0026 r \u003C= \u00279\u0027)\u0060 appears character-identically in 2 files \u2014 internal/app/telegramlogin/native.go, internal/config/config.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/native.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ce46bc8d3e703949e2deee671063146b31b1702d941d1fe4e56427853d21e32"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060(r \u003E= \u0027a\u0027 \u0026\u0026 r \u003C= \u0027z\u0027) || (r \u003E= \u0027A\u0027 \u0026\u0026 r \u003C= \u0027Z\u0027) || (r \u003E= \u00270\u0027 \u0026\u0026 r \u003C= \u00279\u0027) || r == \u0027_\u0027\u0060 appears character-identically in 2 files \u2014 cmd/telesrv-admin/privateview_store.go, internal/admin/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":890}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a4b47a94b773121c71e739b8f0013a5d95c458c4122cbfcc508b51942fe4e5e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060(senderExcludeAuthKeyID != 0) != (senderExcludeSessionID != 0) || (recipientExcludeAuthKeyID != 0) != (recipientExcludeSessionID != 0)\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/message_send_batch_sql.go, internal/store/postgres/message_send_hotpath.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_sql.go"},"region":{"startLine":200}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbc312ca5fa108d97c654af5927893eab862e95abf285bfe00d6fa561f955cfc"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060accuracy \u003C 0 || accuracy \u003E maxGeoAccuracyRadiusMeters\u0060 appears character-identically in 2 files \u2014 internal/rpc/send_media.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":948}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a83b2bcca0976ae3e7cd9ac404003613c3a1062716f76fc99805a85e54bc6ec"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060action.PhotoRequested \u0026\u0026 detail.Photo != nil\u0060 appears character-identically in 2 files \u2014 internal/botapi/projection.go, internal/rpc/convert_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":887}}}],"partialFingerprints":{"codehealthFindingId/v1":"975b8716a032f5262b66d4c9f5e6cc83a04f5647a6a5baf6461bd3cba7e161ab"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060actionID \u003C= 0 || expectedAttempts \u003C= 0 || len(errorText) \u003E 4000 || now.IsZero() || (!succeeded \u0026\u0026 retryAt.Before(now))\u0060 appears character-identically in 2 files \u2014 internal/store/memory/moderation.go, internal/store/postgres/moderation_cases.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":854}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe7c23255a20748eca11e670cf3aeccb74ab673dae1099aa9a76118bc824c58c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060actionID \u003C= 0 || expectedAttempts \u003C= 0 || now.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/moderation.go, internal/store/postgres/moderation_cases.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":834}}}],"partialFingerprints":{"codehealthFindingId/v1":"05cfbd173d57892d3e46496126d54ec49ca192501bd9885afade719016233f59"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060actor.Role != domain.ChannelRoleAdmin || !actor.AdminRights.ManageRanks\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":685}}}],"partialFingerprints":{"codehealthFindingId/v1":"db3faeb160376c53e5ff8dc96dd98fe7ecd3f2dea91ab68199096dcf690ed14e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060actor.Role != domain.ChannelRoleCreator \u0026\u0026 !adminRightsSubset(req.AdminRights, actor.AdminRights)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d18de21a26f4505023e4b8abe9f5c86f7043cc1cb31dd9c3bac5f790c85f8a4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060actor.Role == domain.ChannelRoleCreator || actor.Role == domain.ChannelRoleAdmin\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":671}}}],"partialFingerprints":{"codehealthFindingId/v1":"f69871104a7261c88a26a4b05c2d741a0f73f5e9ea83b2a30c87103765697eef"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060allUsers \u0026\u0026 peer.Type == domain.PeerTypeUser\u0060 appears character-identically in 2 files \u2014 internal/botapi/projection.go, internal/rpc/botapi_update_queue.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":869}}}],"partialFingerprints":{"codehealthFindingId/v1":"4703ab8290493e80a80c93f79a310606868c06b2268a60e9adc555b64672ce2d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060allowed.BotUserID \u003C= 0 || allowed.NormalizedURL == \u0022\u0022 || (allowed.Kind != domain.TelegramLoginAllowedWebOrigin \u0026\u0026 allowed.Kind != domain.Tel\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":165}}}],"partialFingerprints":{"codehealthFindingId/v1":"b44b9acc41d994423a704c66e31c634aea43e1ccca499f69959ed005a21e1632"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060applicationID \u003C= 0 || version \u003C= 0 || utf8.RuneCountInString(reason) \u003E domain.MaxVerificationReasonLength\u0060 appears character-identically in 2 files \u2014 internal/store/memory/verification.go, internal/store/postgres/verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"ede4c4bdde02111582e2b1e352c7edd2680d0866801d8816324bcd524d29391e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060approval.PhoneShared \u0026\u0026 !request.Requests(domain.TelegramLoginScopePhone)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"71c163faff7eafbefc35a62f5dcf4459e6667ac6f2090b95c92f67c3cba6c071"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060approval.RequestID \u003C= 0 || approval.Identity.UserID \u003C= 0 || webAuthorizationHash == 0 || approval.ApprovedAt.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":347}}}],"partialFingerprints":{"codehealthFindingId/v1":"5542dcf917622681ad35fa063fce1f32e2e73337d7c3eb3a3330896921ff42aa"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060approval.WriteAllowed \u0026\u0026 !request.Requests(domain.TelegramLoginScopeBotAccess)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"00d9b602a3c56600d5037b9dafb9e7d813671a35118abe16fd07d2cc2adf96a6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060attrs[i].Kind != domain.DocAttrSticker \u0026\u0026 attrs[i].Kind != domain.DocAttrCustomEmoji\u0060 appears character-identically in 2 files \u2014 internal/app/files/sticker_creator.go, internal/app/files/sticker_management.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"7fce2c95d6f458fadb7cf16262071e477220e17bac0aad65ca2c641ab166dd11"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060block.CallID == 0 || len(block.Block) == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":732}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd70c9686efc1aac04bbc1fc69e639ef504ab8f7460bfbdb592a5f30305611bd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060botID == 0 || channelID == 0 || id \u003C= 0 || id \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c051808c1f6925f640ec15604f80ca82717db00280a02108fcfdeeec37896ca"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060botUserID \u003C= 0 || expectedVersion \u003C= 0 || len(secretHash) != 32\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf25310c72f9571abf38ff560c111ecd5febf661bf30d5eb0a379ccdc986a6e3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060botUserID \u003C= 0 || owner == \u0022\u0022 || ttl \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/botapi_update.go, internal/store/postgres/botapi_update.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"385e5945aa28e839a68a6531d6dc6156485eee8a14230b7580c3df562ebce850"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060botUserID == 0 || confirmedUpdateID \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/botapi_update.go, internal/store/postgres/botapi_update.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"53472434e93b7a0bbe3e44bcf5ed40e6efb23337660e2cf795de850771db7944"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060botUserID == 0 || userID == 0 || botUserID == userID\u0060 appears character-identically in 3 files \u2014 internal/store/memory/bot.go, internal/store/postgres/bot.go, internal/store/postgres/bot_miniapp.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":297}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a2ded02bffd4c521360fe0c223d336788dff5580e716a48b5cdb3e33307fe67"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060botVerificationPeerType(peer.Type) \u0026\u0026 peer.ID \u003E 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":1057}}}],"partialFingerprints":{"codehealthFindingId/v1":"5521836c7077eba4453b67d110cf4a2bc1aac61a293fdb240a642eed7b24e4ec"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060box.OwnerUserID == box.MessageSenderID || len(privateMediaJSON) == 0\u0060 appears character-identically in 3 files \u2014 internal/store/postgres/star_gift_craft_projection.go, internal/store/postgres/star_gift_lifecycle_projection.go, internal/store/postgres/star_gift_upgrade.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_craft_projection.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc68c8028fbe8af74137d81334a20b0e0951461ab6d1ac786ceec9d41c949304"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060button.Type == domain.MarkupButtonCallback \u0026\u0026 bytes.Equal(button.Data, data)\u0060 appears character-identically in 2 files \u2014 internal/app/ephemeral/service.go, internal/rpc/bots_callback.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":460}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ac0a9bf931c7e45de45b32f30cea41abef649154435149b6c00a426f6a75dc9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060c == nil || c.cache == nil || channelID == 0\u0060 appears character-identically in 2 files \u2014 internal/app/channels/media_count_cache.go, internal/app/dialogs/list_snapshot_cache.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/media_count_cache.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"62b7796ff3bede9b3a0e46f99c1c10421cbadcda9356c7165f22b437472b259c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060c == nil || viewerUserID == 0 || channelID == 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/channel_full_bot_cache.go, internal/rpc/rpc_projection_cache.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_full_bot_cache.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"44e2cb4655f8d5873e5f04c82b4c2fe6ce054cc4ede5c79a4a4faa6572092777"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060c == nil || viewerUserID == 0 || peer.ID == 0\u0060 appears character-identically in 4 files \u2014 internal/rpc/rpc_projection_cache.go, internal/rpc/story_pinned_cache.go, internal/rpc/story_pinned_stories_cache.go, internal/rpc/story_projection_cache.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/rpc_projection_cache.go"},"region":{"startLine":88}}}],"partialFingerprints":{"codehealthFindingId/v1":"3984d88ac91140cbcfd6ed22f78acc82bedebbc61722791164c586ab860a5042"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060c.Concurrency \u003C= 0 || c.Concurrency \u003E 64\u0060 appears character-identically in 4 files \u2014 internal/loadharness/mutate.go, internal/loadharness/provision.go, internal/loadharness/seed.go, internal/loadharness/snapshot.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebf26fb61ee80c6a9589db9c7984e14acdb098b5afed971f612da93a2c726ab1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060c.outbound == nil || c.outboundControl == nil\u0060 appears character-identically in 2 files \u2014 internal/mtprotoedge/outbound.go, internal/mtprotoedge/session_manager.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/outbound.go"},"region":{"startLine":1566}}}],"partialFingerprints":{"codehealthFindingId/v1":"abcad1321cd9d4b7e0911f825ba688866793e643a42626649c31d085fc66b55c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060call.ID == 0 || call.AccessHash == 0 || call.CreatorUserID == 0 || call.InviteSlug == \u0022\u0022 || call.InviteLink == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1e97b0b0c0ce1034d5d0e921791a515d48e429b82751358d36e4e53481b61e8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060call.ID == 0 || call.ChannelID == 0 || call.AccessHash == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"8e638bf0dd5bd9c1f038d9f76b2eef2935cca84958d3d89ec8efff9697da22f4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060caseID \u003C= 0 || expectedVersion \u003C= 0 || actor == \u0022\u0022 || len(actor) \u003E domain.MaxModerationActorBytes || now.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/moderation.go, internal/store/postgres/moderation_cases.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"d010b0f3e7692826a62b6c204bfedcbdbfae34c980f62a7d9b0e4bdc0151500b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060cb == nil || cb.ID == 0 || cb.BotUserID != req.BotUserID || cb.UserID \u003C= 0 || cb.Peer != req.Peer || cb.MessageID != req.MessageID || cb.Cha\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/botapi_update.go, internal/store/postgres/botapi_update.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":450}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3f360c2b63b2a6c154aa5faeb2bccebb5a90129300f2266584602e7e95222bb"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060cfg.MaxWait \u003C= 0 || cfg.MaxWait \u003E 10*time.Millisecond\u0060 appears character-identically in 4 files \u2014 internal/store/contact_reverse_batch.go, internal/store/postgres/authkey_get_batch.go, internal/store/postgres/authkey_session_layer_batch.go, internal/store/read_model_batch.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc49709bc1f42bb8101472e20995b818439ee102ea779cb9eb7c18810e2091b3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060cfg.MaxWait \u003C= 0 || cfg.MaxWait \u003E time.Second\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/active_channel_ids_batch.go, internal/store/postgres/bootstrap_update_job_batch.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/active_channel_ids_batch.go"},"region":{"startLine":83}}}],"partialFingerprints":{"codehealthFindingId/v1":"a408360105273006f860fc5cabd43c5e05673c681ade29674ccff810118769fd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060cfg.PhoneCodeDeliveryProvider == \u0022webhook\u0022 || ((cfg.LoginEmailEnable || cfg.EmailSignupEnable) \u0026\u0026 cfg.EmailCodeDeliveryProvider == \u0022webhook\u0022\u2026\u0060 appears character-identically in 2 files \u2014 cmd/telesrv/main.go, internal/config/config.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":1253}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d3e268399da019302119bbcc2a7cf4a9ea19237c039059d4c6346748012e9c4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060cfg.QueryTimeout \u003C= 0 || cfg.QueryTimeout \u003E 30*time.Second\u0060 appears character-identically in 6 files \u2014 internal/store/contact_reverse_batch.go, internal/store/postgres/active_channel_ids_batch.go, internal/store/postgres/authkey_get_batch.go, internal/store/postgres/authkey_session_layer_batch.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/contact_reverse_batch.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"38edc661edfcf77a892dae94bbd1325fed53a627e895105f54f3f934bc34557b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060ch.CreatorUserID == viewerUserID \u0026\u0026 viewerUserID != 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/convert_channels_core.go, internal/rpc/convert_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_channels_core.go"},"region":{"startLine":451}}}],"partialFingerprints":{"codehealthFindingId/v1":"639f67133379b837b9f0e6cbae9f124acd0cf12723bcc5bc0964a9e84003ca4c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060changed \u0026\u0026 channel.LinkedMonoforumID != 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_settings.go, internal/store/postgres/channel_message_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_settings.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"17735f8a0245fd2f34ce632827409654828b4aa3c31319f580c1d04676455735"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.BoostsUnrestrict \u003E 0 \u0026\u0026 selfBoostsApplied \u003E= channel.BoostsUnrestrict\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_send.go, internal/store/postgres/channel_message_send.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":407}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ade48bbb3ebbfce688725ff1d86c00ab8220c55cf1cc2e6b441ccbea3f91cff"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.Broadcast \u0026\u0026 broadcastMessagesAllowed\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_settings.go, internal/store/postgres/channel_message_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_settings.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c841722817015188c5f11dc5508da13d28120818bd8973ada6b4cfd59e506a1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.CreatorUserID != req.UserID || previousOwner.Role != domain.ChannelRoleCreator\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"d581b9649ee53fba34d7605582443860a3acf35113b1da34dc1f98c5bd253f2a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.CreatorUserID != userID || member.Role != domain.ChannelRoleCreator\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_join.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":102}}}],"partialFingerprints":{"codehealthFindingId/v1":"607e9a67530b90c8dc86ab1d828756c11d3e6bfd03963ef1ac19b3e35377a198"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.CreatorUserID == userID || member.Role == domain.ChannelRoleCreator\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_join.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"94eb00b77abb566cdd7959e9a2500b25ad4ef0e9c02f19de599b9ecaa6a87f16"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.DefaultBannedRights.EditRank || actor.BannedRights.EditRank\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":674}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9daa050fca48a85826fab857828d7b5f5819755f03761c2c9a617cb96ddf207"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.Forum \u0026\u0026 req.ReplyTo.TopMessageID \u003E 0 \u0026\u0026 req.ReplyTo.TopMessageID != reply.TopMessageID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":571}}}],"partialFingerprints":{"codehealthFindingId/v1":"4892e27f7c94991b969b6b7f1d1e1bbc913bf7012bd77cfa4886b03e0e060bd5"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.Megagroup \u0026\u0026 !channel.Broadcast \u0026\u0026 !channel.Forum \u0026\u0026 !channel.Deleted\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":840}}}],"partialFingerprints":{"codehealthFindingId/v1":"83bee4c96ca5f2b1728e124d1c94839b0bdf59bf320f2bcced354cce80deede2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.Megagroup \u0026\u0026 !channel.DefaultBannedRights.InviteUsers \u0026\u0026 !member.BannedRights.InviteUsers\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":988}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d42c7696449df9b1d398531e931aa73f941046b1fedce7b50551a5170b01f7d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.Megagroup \u0026\u0026 previous.Status == domain.ChannelMemberActive \u0026\u0026 member.Status == domain.ChannelMemberKicked\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":603}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfe0438b1f57a134e9c46e79df2932cf23b66c3bf7966f09e52204cabb3989db"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.MembersListAdminOnly() \u0026\u0026 !isChannelAdmin(viewer)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_list.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d7ce3d0c0c46b1240c3f5c8c3cd7bfd58772d560618102c62c93cd11b183149"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.Monoforum \u0026\u0026 !member.CanManageDirectMessages()\u0060 appears character-identically in 6 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/channel_updates.go, internal/store/postgres/channel_message_history.go, internal/store/postgres/channel_message_views.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"cce38cb581a111c22b7d9cc57de3945b0eb75ae40fade16a382786385556efb5"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.Monoforum \u0026\u0026 channel.LinkedMonoforumID != 0\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/memory/channel_helpers.go, internal/store/memory/channel_message_history.go, internal/store/postgres/channel_core.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"de78389a8d3155f4670887136416e267b5a808cd90973082454c43131c2647bd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channel.SlowmodeSeconds \u003C= 0 || member.Role == domain.ChannelRoleCreator || member.Role == domain.ChannelRoleAdmin\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":844}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6df293bf543f7d8816cbfc0268b1d37ff7f82ad3cf264c924baae0ff00f8e32"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channelID \u003C= 0 || messageID \u003C= 0 || messageID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/moderation.go, internal/store/postgres/moderation_registries.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea12c41750eb58334d8496377b7710e303cfb91cb894bb45cf11edf1894f12db"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060channelID == 0 || r.deps.Channels == nil || r.deps.Sessions == nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_stubs.go, internal/rpc/messages_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9c1200e27c298c4126651ec195131315425dcb68853bc6eac83983536544a72"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060chat.ID == 0 || chat.ID != int(chat.RandomID)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/secretchat.go, internal/store/postgres/secretchat.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/secretchat.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fffc4b568fd0f804086aa6b33df4760fad9483fa616874e3397a2edc6bae10a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060code.RequestID \u003C= 0 || len(code.CodeHash) != 32 || len(code.SealedCode) \u003C 32 || len(code.SealNonce) \u003C 12 || code.SealKeyID == \u0022\u0022 || code.Iss\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e9f80862f1c34a52584b9239ff355b5ded725b63cef25f31f3a97b64e388df5"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060config.BotUserID \u003C= 0 || config.URL == \u0022\u0022 || config.MaxConnections \u003C 1 || config.MaxConnections \u003E 100\u0060 appears character-identically in 2 files \u2014 internal/store/memory/botapi_update.go, internal/store/postgres/botapi_update.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cbc38812cd89a2703dac9546d9896a10ed2c4e09737472cd7f6ddc6c133f00d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060contact.CloseFriend || contact.User.CloseFriend\u0060 appears character-identically in 7 files \u2014 internal/app/userprojection/contact_cache.go, internal/app/userprojection/projection.go, internal/rpc/contacts.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/contact_cache.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"4363e0da4bfba7c79b7fed0393fdda6a7b84504d0016622d96dc668362602da0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060contact.FirstName != \u0022\u0022 || contact.LastName != \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/app/userprojection/projection.go, internal/rpc/contacts.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":616}}}],"partialFingerprints":{"codehealthFindingId/v1":"1fd1f69577366d333dd0c65f70b309eff2d70c59cb33b7710364fdf33c8153c6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060customVerificationDecisionNeedsApply(status) \u0026\u0026 apply == nil\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":618}}}],"partialFingerprints":{"codehealthFindingId/v1":"34191cf26f74cdc367ba93bb2558d51f63677cd7927af285af862be01be66163"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060cut \u003E 0 \u0026\u0026 !utf8.ValidString(reason[:cut])\u0060 appears character-identically in 2 files \u2014 internal/store/memory/verification.go, internal/store/postgres/verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/verification.go"},"region":{"startLine":1004}}}],"partialFingerprints":{"codehealthFindingId/v1":"08809b6b13a118574601a4a3e989d303976b4ae04359c0eed08d789e28ae8e61"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060d == nil || !d.started.CompareAndSwap(false, true)\u0060 appears character-identically in 2 files \u2014 internal/rpc/botapi_enqueue_dispatcher.go, internal/rpc/channel_fanout_dispatcher.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_enqueue_dispatcher.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"02ea1be3e436eb839e9edc5cdc416cf79cf08f290386b407486efd9b51e71143"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060deadline.IsZero() || ctxDeadline.Before(deadline)\u0060 appears character-identically in 2 files \u2014 internal/mtprotoedge/inbound_rpc.go, internal/mtprotoedge/session_manager.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_rpc.go"},"region":{"startLine":700}}}],"partialFingerprints":{"codehealthFindingId/v1":"3101dc596da4f3e3674770440f4ddb2c1b34495dae7c529364bfb37acf46e1ec"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060deliverRecipient \u0026\u0026 originUserID == req.RecipientUserID\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/message_send_batch_sql.go, internal/store/postgres/message_send_hotpath.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_sql.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8a8252d20a37f43d6c7353941274c39054c8d86db092ac1f89c72c065cc57ad"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060delivery.OwnerUserID == 0 || delivery.PeerUserID == 0 || delivery.Kind == \u0022\u0022 || delivery.TriggerMessageID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/business.go, internal/store/postgres/business.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/business.go"},"region":{"startLine":315}}}],"partialFingerprints":{"codehealthFindingId/v1":"333955e05d10010c9cb611ad02f15604d9285188fde3f5d3e59f0c2e9f321a48"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060dialog.Peer.Type != domain.PeerTypeChannel || dialog.Peer.ID == 0\u0060 appears character-identically in 2 files \u2014 internal/app/dialogs/list_snapshot_cache.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":197}}}],"partialFingerprints":{"codehealthFindingId/v1":"764b603d1536ccd5cc6029139c2067738399d15cd20574e9341485c2ad8f2470"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060dialog.Peer.Type != domain.PeerTypeUser || dialog.Peer.ID == 0 || dialog.Peer.ID == userID\u0060 appears character-identically in 2 files \u2014 internal/app/dialogs/service.go, internal/store/memory/dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":305}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0af8170614c95cfe5bdb65ddc251bb8f2095eb368d00ec7548604e1acac2348"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060dialog.UnreadCount \u003E 0 || dialog.UnreadMark\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/memory/dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f490cffb1b94219d5ec80e340cc9b278565094d1bac80fe7c261223b536b26c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060discussionChannelID != 0 \u0026\u0026 discussionMessageID != 0\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/channel_message_helpers.go, internal/store/postgres/channel_message_views.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_helpers.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"db515d6fe857da93da2bc9ddc4788e777ddb1f78599949a6020b1deb959c467d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060email == \u0022\u0022 || !strings.Contains(email, \u0022@\u0022)\u0060 appears character-identically in 2 files \u2014 internal/domain/emailphone.go, internal/rpc/account.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/emailphone.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"aea5d02c2c7115f3245cfe0cda7c1389e19d3f0c3642f053c1d929946fb18d07"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060enabled \u0026\u0026 strings.TrimSpace(channel.Username) == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_join_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":806}}}],"partialFingerprints":{"codehealthFindingId/v1":"4777050d15d097fae85f52e81251afb558da11b7312629e838e17bc9bb974ebf"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060entry.ContentLoaded \u0026\u0026 len(entry.Pack.Strings) != entry.StringsCount\u0060 appears character-identically in 2 files \u2014 internal/store/memory/langpack.go, internal/store/postgres/langpack.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"31d6918ef07156afa15d51b4175192d5c53fa2b2aa3e4a99412a1aadcc42342f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060entry.SourceHash == \u0022\u0022 || entry.ContentHash == \u0022\u0022 || entry.StringsCount \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/langpack.go, internal/store/postgres/langpack.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/langpack.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"ecdd89860cedcbf6404a7b829b1dfa45d496224db940729edf8e2c4b9af0b86a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil \u0026\u0026 !errors.Is(err, domain.ErrChannelInvalid)\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/channel_message_send.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":218}}}],"partialFingerprints":{"codehealthFindingId/v1":"2622e898f58b14347ad2a71277e4fe5e3cd5222bd224d1ac34dbec50bcac5d00"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil \u0026\u0026 !errors.Is(err, domain.ErrMessageIDInvalid)\u0060 appears character-identically in 3 files \u2014 internal/store/postgres/channel_helpers.go, internal/store/postgres/channel_message_history.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":905}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ee0da5b9d98b40e950a5b6d6ce37cdedb3c2716814325081dc7cb96a97b9069"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil \u0026\u0026 !errors.Is(err, pgx.ErrNoRows)\u0060 appears character-identically in 9 files \u2014 internal/store/postgres/channel_dialogs.go, internal/store/postgres/community.go, internal/store/postgres/groupcall.go, internal/store/postgres/poll.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_dialogs.go"},"region":{"startLine":1716}}}],"partialFingerprints":{"codehealthFindingId/v1":"59f8838cad3c70787a12a4938f839feb49f7c45eb14a15ad0b2d67022d72370b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil || !broadcast.Broadcast || broadcast.Megagroup\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":767}}}],"partialFingerprints":{"codehealthFindingId/v1":"534279c7133fe78d4d245d5bd04686f53dcb738a104de9561a0c3dd16f9d7d49"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil || !found || profile.ChatHistory\u0060 appears character-identically in 2 files \u2014 internal/app/channels/bot_policy.go, internal/app/channels/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":212}}}],"partialFingerprints":{"codehealthFindingId/v1":"2cab7902edbfc004d7ed2f3ed8c3643d8e5d791ed804539134ca1c24fc3a7b43"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil || !validDiscussionGroup(group)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"5dde40d4b567e164569dc17ee610f52872fa1f5340624687dc92cb7091a25bbd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil || (u.Scheme != \u0022http\u0022 \u0026\u0026 u.Scheme != \u0022https\u0022) || u.Host == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/app/files/external_media.go, internal/app/files/webpage.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"f705bad73053b628684297c2424f871f1ef97bb2b4491df350dfa428c38b1515"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil || cfg.Width \u003C= 0 || cfg.Height \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/app/files/photos.go, internal/app/files/seed.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/photos.go"},"region":{"startLine":1055}}}],"partialFingerprints":{"codehealthFindingId/v1":"05d2fa90c0d8a28205f88d2fe7e57ecd9f0bda5929a0be03b0e9fb28d01deaa4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil || fingerprint != r.Fingerprint\u0060 appears character-identically in 2 files \u2014 internal/domain/moderation.go, internal/domain/moderation_case.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/moderation.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"c49df4fbec7bade1d50d021de71cf5529f2064a58c072168d25bc22b9d1b81b7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil || len(data) == 0 || int64(len(data)) \u003E domain.MaxGifCatalogUploadSize\u0060 appears character-identically in 2 files \u2014 cmd/telesrv-admin/server.go, internal/adminapi/server.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2170}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc3866322475a7d69d85b77c5aba078fb1c873e7174ef2106d4490a1ca0db690"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err != nil || len(data) == 0 || len(data) \u003E maxGiftPackZipBytes\u0060 appears character-identically in 2 files \u2014 cmd/telesrv-admin/star_gift_catalog.go, internal/adminapi/server.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/star_gift_catalog.go"},"region":{"startLine":388}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2968bc76c4477a2c94f3599a36bc7cc132986dc723ada63fcab21f8ac4fb6e7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err == nil || !isRetryablePostgresTxError(err) || ctx.Err() != nil\u0060 appears character-identically in 3 files \u2014 internal/store/postgres/channel_message_send.go, internal/store/postgres/channel_read.go, internal/store/postgres/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_send.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaed91c2c50f25db17a21871a129e6aa110ab35b17af3c37783499233d334270"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err1 != nil || err2 != nil || err3 != nil || err4 != nil || group \u003C 0 || viewerID == 0 || messageID \u003C 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/story.go, internal/store/postgres/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1526}}}],"partialFingerprints":{"codehealthFindingId/v1":"32d2855123d0092fb48ec2ceb4eccae86b236a651686eab1a4fbe24ddeb16d62"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060errors.Is(err, domain.ErrChannelInvalid) || errors.Is(err, domain.ErrChannelPrivate)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_core.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":234}}}],"partialFingerprints":{"codehealthFindingId/v1":"06c075951f326346b2003fa912553b1b5b2e90b853f7b1667dd9c667a7f41c70"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060errors.Is(err, domain.ErrInviteRequestSent) \u0026\u0026 res.Channel.ID != 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_invites.go, internal/rpc/channels_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":126}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b712e510d0b9db32dd87102bc1eb05b99f493eed5ca2636b58575e8cf24f33d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060errors.Is(err, domain.ErrUserNotFound) || errors.Is(err, domain.ErrBotNotFound) || errors.Is(err, domain.ErrChannelInvalid)\u0060 appears character-identically in 2 files \u2014 internal/app/botverification/service.go, internal/app/verification/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1494}}}],"partialFingerprints":{"codehealthFindingId/v1":"52a51835efcf182b2170150fe84332393a508516416634bdf96c88f34bcfd91e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060errors.Is(err, pgx.ErrNoRows) || (err == nil \u0026\u0026 balance \u003C amount)\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/star_gift_upgrade.go, internal/store/postgres/stars.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_upgrade.go"},"region":{"startLine":1017}}}],"partialFingerprints":{"codehealthFindingId/v1":"bad2ca89b5923163b913051eacb31ebc07ffa6101bbda6e4c299ba46db84146d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060event.ChannelID == 0 || event.UserID == 0 || event.Type == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_admin_log.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":974}}}],"partialFingerprints":{"codehealthFindingId/v1":"26980c261fefffe269d4a711150b8b4edb92df35b7f74b303e831814102a61c6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060event.SourceID == \u0022\u0022 || event.SourceID == r.instanceID\u0060 appears character-identically in 2 files \u2014 internal/rpc/ephemeral_push.go, internal/rpc/inline_push.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral_push.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0d75451b6ff07d241d72911fb6c86d9432c9c2acde3d4cc03dd41c32ebc82b7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060existing.Status == domain.ChannelMemberBanned || existing.Status == domain.ChannelMemberKicked || existing.BannedRights.ViewMessages\u0060 appears character-identically in 5 files \u2014 internal/store/memory/channel_invites.go, internal/store/memory/channel_members.go, internal/store/postgres/channel_invite_members.go, internal/store/postgres/channel_member_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":41}}}],"partialFingerprints":{"codehealthFindingId/v1":"939c6f862dd1ba67d209c5f2493e239524d95fa1fcd35caf355c60993bcd06ff"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060existing.Status == domain.ChannelMemberKicked || existing.Status == domain.ChannelMemberBanned || existing.BannedRights.ViewMessages\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_invites.go, internal/store/memory/channel_members.go, internal/store/postgres/channel_invite_import.go, internal/store/postgres/channel_member_join_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":744}}}],"partialFingerprints":{"codehealthFindingId/v1":"16413b86147ad953a0e811db24c188a66272b14a527d71b6f5c008901b85f776"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060existingChat \u0026\u0026 recipients.ExistingChats\u0060 appears character-identically in 2 files \u2014 internal/app/messages/business_automation.go, internal/domain/business.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6a05bfb506eee6b39ea221e1d21b899a7bbd13c320597afa1493a3a43aee564"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.HasFolderID \u0026\u0026 filter.FolderID != domain.DialogMainFolderID\u0060 appears character-identically in 3 files \u2014 internal/app/dialogs/list_snapshot_cache.go, internal/app/dialogs/service.go, internal/compat/tdesktop/dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/list_snapshot_cache.go"},"region":{"startLine":393}}}],"partialFingerprints":{"codehealthFindingId/v1":"89ea0354a65f236de36b072234cea976f8fa1f0f41f588e4e23cc95b25d44e8b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.HasOffsetPeer \u0026\u0026 filter.OffsetPeer == dialog.Peer\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"5ff995b3c55951b5be227e17b36140e366728b1baf4e3e06d8ac4ae4b76601a2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.HasOffsetPeer \u0026\u0026 filter.OffsetPeer.Type == dialog.Peer.Type\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":583}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d7479cb67ac521d8845639757334621cd51b88d5703ac65b8172c47bc606f8c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.Kind == domain.ChannelParticipantsKicked || filter.Kind == domain.ChannelParticipantsBanned\u0060 appears character-identically in 2 files \u2014 internal/store/memory/community.go, internal/store/postgres/community.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/community.go"},"region":{"startLine":832}}}],"partialFingerprints":{"codehealthFindingId/v1":"cafb6a02581b8e2ecbea3daddf0a8dd4831c78555049c8bf51047050c5260421"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.MaxDate \u003E 0 \u0026\u0026 msg.Date \u003E= filter.MaxDate\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":75}}}],"partialFingerprints":{"codehealthFindingId/v1":"2483c7e4131fe753ddf2bc0c1dd6631df7733a7fe1eb764836c99b3887f76350"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.MaxID \u003E 0 \u0026\u0026 msg.ID \u003E= filter.MaxID\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_reactions.go, internal/store/memory/channel_read.go, internal/store/memory/channel_topics.go, internal/store/memory/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":566}}}],"partialFingerprints":{"codehealthFindingId/v1":"d19ce66b9f99d34ce915b8aaf07b955b6411032b9b0849c0ef3ec72c1f1e0bbf"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.MinDate \u003E 0 \u0026\u0026 msg.Date \u003C= filter.MinDate\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"69c30a2f375e177d52b735204c004af09e385c4d9877bf58fe07cee67f9aaeba"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.MinID \u003E 0 \u0026\u0026 msg.ID \u003C= filter.MinID\u0060 appears character-identically in 5 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/channel_reactions.go, internal/store/memory/channel_read.go, internal/store/memory/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae1a4f3d727e4a7f98298070f7f3e8c99d38adf0ce18a8813a0a835f8c75b13d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.MonoforumID == 0 || filter.SavedPeer.ID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_monoforum.go, internal/store/postgres/channel_monoforum.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d663a4d679f5376c9b54a6b7f0a92dad5df93d79642d51badf55d23213cb85a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.MusicOnly \u0026\u0026 !msg.Media.IsMusic()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":63}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3830b5af2390dda5f5d2ab97d1183da33251924cd2ede9580023a32525d39d5"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.OffsetDate \u003C= 0 \u0026\u0026 filter.OffsetID \u003C= 0\u0060 appears character-identically in 3 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/memory/dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":567}}}],"partialFingerprints":{"codehealthFindingId/v1":"27c6f2d5ed6669a072525bd05c78cf330ae271b61a088f600be48a643e00298c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.OffsetID != 0 || filter.OffsetDate != 0 || filter.HasOffsetPeer\u0060 appears character-identically in 2 files \u2014 internal/app/dialogs/service.go, internal/compat/tdesktop/dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":619}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cb3467015c2b1a450141adf9449ea80f897173b0cd19374273d049398dee832"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.PeerType != \u0022\u0022 \u0026\u0026 !botVerificationPeerType(filter.PeerType)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":500}}}],"partialFingerprints":{"codehealthFindingId/v1":"753eaa0fa7c808f4c79b424f169c51d66b25909ffe7d10a8451e763419fb4bfe"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.Status != \u0022\u0022 \u0026\u0026 !filter.Status.Valid()\u0060 appears character-identically in 4 files \u2014 internal/adminapi/server.go, internal/app/usernames/service.go, internal/store/memory/collectible_username.go, internal/store/postgres/collectible_username.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/server.go"},"region":{"startLine":1754}}}],"partialFingerprints":{"codehealthFindingId/v1":"0141b333160b06c9717602683aa142be2654d3af66bb8800b738d749de184c2d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060filter.TargetType != \u0022\u0022 \u0026\u0026 !filter.TargetType.Valid()\u0060 appears character-identically in 4 files \u2014 internal/adminapi/verification.go, internal/app/verification/service.go, internal/store/memory/verification.go, internal/store/postgres/verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/verification.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"3937c2695319ba17f0435da1be2583b6abccffb0d93c05f4422f4ab9bb7a87e9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060folder.ExcludeArchived \u0026\u0026 dialog.FolderID == domain.DialogArchiveFolderID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":549}}}],"partialFingerprints":{"codehealthFindingId/v1":"11ee466938e14211dc7b65db62ac0dc826366cf69f79859c1968db08482e18c8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060folder.ExcludeRead \u0026\u0026 dialog.UnreadCount == 0 \u0026\u0026 !dialog.UnreadMark\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"df0d78f00da2f384c66b238261f00446d31fcfb9aa0a32053165973d755f17fb"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060form.RevisionID != req.RevisionID || form.ChargeStars != req.ChargeStars\u0060 appears character-identically in 2 files \u2014 internal/app/stargifts/service.go, internal/store/postgres/star_gift_purchase.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/service.go"},"region":{"startLine":652}}}],"partialFingerprints":{"codehealthFindingId/v1":"3594ea04fab15de62ed8d4f7cdf640261544606b20656b4df6d83d47b36dd438"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060forward == nil || forward.From.Type != domain.PeerTypeUser || forward.From.ID == 0 || forward.FromName != \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_forward.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":761}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfaa489d36debf8024612ac6a71a6e613e5270dcc81ab78bf794182d63c8f4d1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060forward.From.ID == forwarderUserID || r.deps.Privacy == nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_forward.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_forward.go"},"region":{"startLine":764}}}],"partialFingerprints":{"codehealthFindingId/v1":"bc104dd8a198b5177bde29f588e6390e9de9a782b8f77bb93c6dd2697c61e5fc"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060g.GiftID == 0 || g.RevisionID == 0 || !validStarGiftOwner(g.Owner)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/star_gift.go, internal/store/postgres/star_gift.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":934}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5abebb36799d32877dccdf8d3a55791d0e038d653de156659fdb8404952dc65"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060gift.SupportOnly \u0026\u0026 !r.viewerSupport(ctx, userID)\u0060 appears character-identically in 2 files \u2014 internal/rpc/payments_star_gift_lifecycle.go, internal/rpc/payments_star_gifts.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":443}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cdb4a5deb7cba40e63245ba7532dc36bd2a767b788ce6125a1b539b1da1821b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060heading \u003C 0 || heading \u003E maxLiveLocationHeading\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_edit_geolive.go, internal/rpc/send_media.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d55dc00b54892a3657bc95afc4b5b1e4a5319dde8310716d17402a96930dadf"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060hourly \u003E= domain.MaxAuthDeliveryReportsPerHour || phoneDaily \u003E= domain.MaxAuthDeliveryReportsPerPhoneDay\u0060 appears character-identically in 2 files \u2014 internal/store/memory/auth_delivery_report.go, internal/store/postgres/auth_delivery_report.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth_delivery_report.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"04b0b0c71ba6cc42773d3d0a5bc673eacc2bc57a0baeac0508925ab2c02f3a34"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060hourly \u003E= domain.MaxClientTelemetryEventsPerHour || daily \u003E= domain.MaxClientTelemetryEventsPerDay\u0060 appears character-identically in 2 files \u2014 internal/store/memory/client_telemetry.go, internal/store/postgres/client_telemetry.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/client_telemetry.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"04840200be02000be46846e5b3051453f69f7f2b65662d2c048b0a4c9779142f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060hourly \u003E= domain.MaxModerationReportsPerHour || daily \u003E= domain.MaxModerationReportsPerDay\u0060 appears character-identically in 2 files \u2014 internal/store/memory/moderation.go, internal/store/postgres/moderation.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"d720f897111e73419aea95fbb577cdb86119a1d08f8b7ac560f446ac3930df91"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060invite.CallID == 0 || invite.InviterUserID == 0 || invite.InviteeUserID == 0 || invite.MessageID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":656}}}],"partialFingerprints":{"codehealthFindingId/v1":"631631ff312c7b4366309765e561f31271abd71d0ca878d0a6e718dfb0c12350"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060invite.ExpireDate == 0 \u0026\u0026 invite.UsageLimit == 0 \u0026\u0026 !invite.RequestNeeded \u0026\u0026 invite.Title == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_exported.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":467}}}],"partialFingerprints":{"codehealthFindingId/v1":"65787ad680264f095a532a9dc30e401ec327b7dfed8b71c146e15260db14987e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060invite.ExpireDate \u003E 0 \u0026\u0026 invite.ExpireDate \u003C date\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_import.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"77d7a155b7f6bb79a4fcb6772405c61763ab497c649a4ab682520293d21caa8a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060invite.ExpireDate \u003E 0 \u0026\u0026 invite.ExpireDate \u003C req.Date\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_import.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":318}}}],"partialFingerprints":{"codehealthFindingId/v1":"24c414bf68d8732316c4a9354edefe91c6babbd164c06e210e6ea5a8c75c640b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060invite.InviteID != 0 \u0026\u0026 invite.UsageLimit \u003E 0 \u0026\u0026 invite.UsageCount \u003E= invite.UsageLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_import.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":733}}}],"partialFingerprints":{"codehealthFindingId/v1":"727400bc5618d72dcb7ee63aae18ffc7f09837e02a22ab2aba75d223e9473895"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060invite.Permanent \u0026\u0026 ((req.HasExpireDate \u0026\u0026 req.ExpireDate \u003E 0) || (req.HasUsageLimit \u0026\u0026 req.UsageLimit \u003E 0) || (req.HasRequestNeeded \u0026\u0026 req.\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_exported.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":452}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f9febb498242d79e13c5b8bb106d42ba9432fcf22e7a00de251ca1687635c8b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isChannelTodoParticipantEdit(req, msg) \u0026\u0026 canSendChannelMessage(channel, member)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":71}}}],"partialFingerprints":{"codehealthFindingId/v1":"65db797908f88e0ff6242e9ca108eb6a019ae28b9a2a48f342ffa5395f1a55cd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060item.FolderID != domain.DialogMainFolderID \u0026\u0026 item.FolderID != domain.DialogArchiveFolderID\u0060 appears character-identically in 4 files \u2014 internal/rpc/folders.go, internal/store/memory/channel_dialogs.go, internal/store/memory/dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/folders.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9d40ba19e550f6aacd5daf323b473bf51471d3a2879297c3da5dcd4253d977f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060item.Peer.Type != domain.PeerTypeChannel || item.Peer.ID == 0\u0060 appears character-identically in 3 files \u2014 internal/app/chatlists/service.go, internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"f589d73ccd2e10d0d9c56e08dcc23839d0cb81336d2a705ddbf5de41cd22d1df"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060item.Peer.Type == \u0022\u0022 || item.Peer.ID == 0\u0060 appears character-identically in 3 files \u2014 internal/app/chatlists/service.go, internal/store/memory/dialogs.go, internal/store/postgres/dialog.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/chatlists/service.go"},"region":{"startLine":723}}}],"partialFingerprints":{"codehealthFindingId/v1":"de98448b8e4b73d72204433db627daaa7022003aa4ac44a2b7209982c14d45fa"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060item.StartMinute \u003C 0 || item.EndMinute \u003C= item.StartMinute || item.EndMinute \u003E 8*24*60\u0060 appears character-identically in 2 files \u2014 internal/app/account/business.go, internal/app/messages/business_automation.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/business.go"},"region":{"startLine":330}}}],"partialFingerprints":{"codehealthFindingId/v1":"0e89c202dcfa6c8ce1cfb9c427b57b6140c74262b34007f618a4fc1e6486c58f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(cred.CredentialID) == 0 || cred.UserID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/passkey.go, internal/store/postgres/passkey.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/passkey.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf4d1348e260a7a2b5a08d0f025bcca52e42e5cc386fe83a563a5aa9054cae64"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(data) == 0 || int64(len(data)) \u003E domain.MaxStickerMaterialDocumentSize\u0060 appears character-identically in 2 files \u2014 internal/app/files/sticker_admin.go, internal/app/files/sticker_creator.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_admin.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"56e8c91c047b16d47b916d87041bcbb3ed1d07b0d3d8b53e2833a5fc7f41f0b8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(data) == 0 || int64(len(data)) \u003E f.maxBytes\u0060 appears character-identically in 2 files \u2014 internal/app/files/external_media.go, internal/app/files/webpage.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":163}}}],"partialFingerprints":{"codehealthFindingId/v1":"4088091a229e5f56e2d1a133f0d106e3910a3ea47b7ca590a7068ee13b003848"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(data) \u003E= 12 \u0026\u0026 data[0] == \u0027R\u0027 \u0026\u0026 data[1] == \u0027I\u0027 \u0026\u0026 data[2] == \u0027F\u0027 \u0026\u0026 data[3] == \u0027F\u0027 \u0026\u0026 data[8] == \u0027W\u0027 \u0026\u0026 data[9] == \u0027E\u0027 \u0026\u0026 data[10] == \u0027\u2026\u0060 appears character-identically in 2 files \u2014 internal/app/files/seed.go, internal/rpc/upload.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":1056}}}],"partialFingerprints":{"codehealthFindingId/v1":"1895f205701e01522e1b799dd7f39c191005c2f7d0640f159d5fa6fe1afd83a6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(data) \u003E= 2 \u0026\u0026 data[0] == 0x1f \u0026\u0026 data[1] == 0x8b\u0060 appears character-identically in 2 files \u2014 internal/admin/service.go, internal/app/stargifts/animation.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3867}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f7aa2ddc3929bd0b587c326dbb44c3716edffbc4bfce782592d639bcc5c8709"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(data) \u003E= 3 \u0026\u0026 data[0] == 0xFF \u0026\u0026 data[1] == 0xD8 \u0026\u0026 data[2] == 0xFF\u0060 appears character-identically in 2 files \u2014 internal/app/files/seed.go, internal/rpc/upload.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":1059}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6e7cc25dc9e44f0eb93a0700aef39c4879c2b5ba211f7d7dd06dbf6f8014152"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(data) \u003E= 6 \u0026\u0026 data[0] == \u0027G\u0027 \u0026\u0026 data[1] == \u0027I\u0027 \u0026\u0026 data[2] == \u0027F\u0027\u0060 appears character-identically in 2 files \u2014 internal/app/files/seed.go, internal/rpc/upload.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":1063}}}],"partialFingerprints":{"codehealthFindingId/v1":"f31e1353cce80e1e701b85c23b2f61d606892a95d5c1a6ea3e2bf5aba8aaf96e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(data) \u003E= 8 \u0026\u0026 data[0] == 0x89 \u0026\u0026 data[1] == \u0027P\u0027 \u0026\u0026 data[2] == \u0027N\u0027 \u0026\u0026 data[3] == \u0027G\u0027\u0060 appears character-identically in 2 files \u2014 internal/app/files/seed.go, internal/rpc/upload.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":1061}}}],"partialFingerprints":{"codehealthFindingId/v1":"846cac5e1a2b465b1873dac3057be853651a529a5a839a6e805ffc285c618306"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(exchange.CodeHash) != 32 || exchange.ClientID == \u0022\u0022 || exchange.ClientSecretVersion \u003C= 0 || exchange.RedirectURI == \u0022\u0022 || exchange.CodeC\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"166ebca7d404d3515032bfecc7be7f27c3be112a34e04826177b97df305b5f2d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(history.Messages) != 1 || history.Messages[0].ID != req.ID\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_messages.go, internal/rpc/messages_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":28}}}],"partialFingerprints":{"codehealthFindingId/v1":"60fdbd11d58c8ae4a99960103ebd55d864936ca37613c36b46bdd72290296d74"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(ownerUserIDs) == 0 || len(keys) == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/privacy.go, internal/store/postgres/privacy.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/privacy.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"7cdacc6b07781c683eee66a1b3ee562e71f7ad6e3eea401dc30c1baec60d40ca"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(reactions.Results) == 0 \u0026\u0026 len(reactions.Recent) == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/postgres/message_reactions.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":725}}}],"partialFingerprints":{"codehealthFindingId/v1":"670365d92a601b7be439974f80f83c1213f7598ea68c558705352a79c03245e7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(reactions.Results) \u003E 0 || len(reactions.Recent) \u003E 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_history.go, internal/store/memory/message_reactions.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"33b45b4b1ffba4c8e499bb8a82924260bb4b0bcdcfd4580b423d835f11c7115f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(req.MessageIDs) == 0 || len(req.MessageIDs) != len(req.RandomIDs)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_forward.go, internal/store/postgres/message_forward.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_forward.go"},"region":{"startLine":14}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a158a66210552ab22b828232cb48852991527f329ca06eea30cc9b1cb426663"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(req.PeerTitle) \u003E maxCustomVerificationTitleBytes || len(req.PeerUsername) \u003E maxCustomVerificationUsernameBytes || len(req.Reason) \u003E maxC\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":1007}}}],"partialFingerprints":{"codehealthFindingId/v1":"c6aab6b7d8c1513da2ebcac90aff1a0318694fe32b6db1a740aa72f088cbf695"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(request.MatchCodes) \u003E 0 \u0026\u0026 approval.MatchCode != request.MatchCode\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c2a58985aad7daf2910563be3c5215b139603df061fde8f26f3bdead5b04b97"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(settings.CompanyName) \u003C= maxVerifierCompanyBytes \u0026\u0026 len(settings.DefaultDescription) \u003C= maxVerifierDescriptionBytes \u0026\u0026 len(settings.Gran\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":998}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf6fd8654c2c3c1f2273e73f961194931d8df6052e488d91f27c460494f066f2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(tokenHash) != 32 || origin == \u0022\u0022 || now.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":568}}}],"partialFingerprints":{"codehealthFindingId/v1":"996ee2ce991299c68b5ffeb13ed9946fc54e2a414f98924f37118983d12d3f33"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060len(viewerUserIDs) == 0 || len(contactUserIDs) == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/contacts.go, internal/store/postgres/contact.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":99}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2c536ff0e7e63309cfb17d41c0d21b9613e84019ea0eb61be1c5ce4a1d501c6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C 0 || limit \u003E domain.MaxStoryListLimit\u0060 appears character-identically in 3 files \u2014 internal/app/stories/service.go, internal/rpc/stories.go, internal/store/memory/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":555}}}],"partialFingerprints":{"codehealthFindingId/v1":"bb348a573e50f4edf3a57fc4d7699a079902c3081a2fdeb31254d41167748485"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelAdminLogLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_admin_log.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"27093eeeb4b460984f2328d10e0cf59fd313c54de6c57939efa137065d7908c6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelDifferenceLimit\u0060 appears character-identically in 5 files \u2014 internal/app/channels/service.go, internal/store/memory/channel_helpers.go, internal/store/memory/channel_updates.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2332}}}],"partialFingerprints":{"codehealthFindingId/v1":"128615f0bb2732a5267e66f775634abe40e3ba7aa3d322797205ff3c5f7b30de"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelForumTopicsLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"c5c98a9dc888d6b51f0aa5d03081a43a9a4c2c91b2c6a88bdc4ee430c13a79ca"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelGlobalSearchLimit\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_history.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":627}}}],"partialFingerprints":{"codehealthFindingId/v1":"dca68ab9003739ea989ac02b1ab83de24561488f0183b8cfbc276a957942cbfb"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelHideJoinRequests\u0060 appears character-identically in 3 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_exported.go, internal/store/postgres/channel_invite_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":509}}}],"partialFingerprints":{"codehealthFindingId/v1":"a84777784e6c0e2aa97ab895121f8762e91141061006e4cd97d9954574debbc1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelInviteListLimit\u0060 appears character-identically in 3 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_exported.go, internal/store/postgres/channel_invite_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":371}}}],"partialFingerprints":{"codehealthFindingId/v1":"5c5f6a9578c86d7b6f5b33deee2f5223d49cd8ce217976f18cbde5c999e14102"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelParticipantsLimit\u0060 appears character-identically in 3 files \u2014 internal/app/channels/participants_cache.go, internal/store/memory/channel_members.go, internal/store/postgres/channel_member_list.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/participants_cache.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"b38c72cfeb818f44c7f760391373f1ee11f8cc59beed2f2e770799a5d87d403f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelPendingJoinRecentRequesters\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":649}}}],"partialFingerprints":{"codehealthFindingId/v1":"44ccf6db17492bb6507f69e25c321ff976c38fed4ee657a18e077dde4ea22853"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelReadMentionsBatch\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_read.go, internal/store/postgres/channel_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":209}}}],"partialFingerprints":{"codehealthFindingId/v1":"582e480c0ad5fd0342827caeafe9c6dacedc05c4df63e900cfad532c1f2cf8d1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelReadParticipants\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_read.go, internal/store/postgres/channel_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"03da227926a6f45e651f976cd96ffede7ec3d314d8761ad431f6b6dec8fb3f5f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelReadReactionsBatch\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/postgres/channel_reaction_unread.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":605}}}],"partialFingerprints":{"codehealthFindingId/v1":"5180166aff5f82af5636739e6f13a37c1fdb1c6878ec4177b586c3ad402dd888"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelRealtimeFanout\u0060 appears character-identically in 6 files \u2014 internal/app/channels/service.go, internal/store/memory/channel_invites.go, internal/store/memory/channel_members.go, internal/store/postgres/channel_invite_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2374}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe786caa1bfd530fbb7eb15e785d48b5eb8f67c747da19269d6ea9110ce8a3dd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelRecommendationsLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":643}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc8e19bfefbc243fb0288ac36e6f83164cd4d63ad3ff1ea0f61ab283fea1a60c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelRepliesLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":531}}}],"partialFingerprints":{"codehealthFindingId/v1":"f92a5771a42425ef1ee256c8a05f524673298c3d94f9620267846fb46de0e734"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelUnreadMentionsLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_read.go, internal/store/postgres/channel_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":156}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c93e89a7fa23e9d2e634e453cf2bb54d1b77601a221b7c49ce8f122d469fc08"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelUnreadReactionsLimit\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_reactions.go, internal/store/memory/message_read.go, internal/store/postgres/channel_reaction_unread.go, internal/store/postgres/message_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":553}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a202c83f6a15e8109838455a3d74bbd232028f59aa7793b81d3ffbeca6c0a4c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxChannelUpdateRetentionBatch\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_updates.go, internal/store/postgres/channel_update_retention.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_updates.go"},"region":{"startLine":323}}}],"partialFingerprints":{"codehealthFindingId/v1":"db97a0c594225265e853ffddfec5d1f41c4b9b45bdadece189143f4dc8c8614e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxCommonChannelsLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":168}}}],"partialFingerprints":{"codehealthFindingId/v1":"62420f56f37ba2d4621d0d15c4ee7ef55a706b68104fb3a2d5e3f640b4174f18"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxCommunityLinkRequests\u0060 appears character-identically in 2 files \u2014 internal/app/communities/service.go, internal/store/postgres/community.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/communities/service.go"},"region":{"startLine":89}}}],"partialFingerprints":{"codehealthFindingId/v1":"264bca2b8d4890a4d6e9a39badce4ac969fbc505315f95eb8131f568acb3d690"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxDialogDraftsPerUser\u0060 appears character-identically in 3 files \u2014 internal/app/dialogs/service.go, internal/store/memory/dialogs.go, internal/store/postgres/dialog.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/service.go"},"region":{"startLine":1334}}}],"partialFingerprints":{"codehealthFindingId/v1":"768183f8bf211ee5d4c188cf0c9b1d58ef6665ccdb8ceb2a650a3a5aa3f7f241"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxDiscussionGroupsLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":682}}}],"partialFingerprints":{"codehealthFindingId/v1":"a7366b989a2e975571c513bb9365c92a723139b800984bb5275e4f05d8ddbf31"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxInactiveChannelsLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":252}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2142686e9b947382d737d47be8eb1c85c3c8641c927a656289d06ec3bce2cba"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxInstalledStickerSets\u0060 appears character-identically in 2 files \u2014 internal/store/memory/password.go, internal/store/postgres/account.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":350}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1b294281a1a74046791f54316d2aad0feaab58bc65456aac43cf96bcc3445d8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxLeftChannelsLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b32145a26722f21bb6516b752f133a2c9712966654301c7ebe3636a2ea9536d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxPremiumBoostsListLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_boosts.go, internal/store/postgres/channel_boosts.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":39}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd6326a33669507ceb4343d20f19e8c986a52322dedb46c93f1df7d55dcadb74"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxPublicChannelSearchLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1b7fd625ee8e4597789ddb317597a8f3d6d26bbd1092172bdefddfece5d7d42"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxSavedMusicItems\u0060 appears character-identically in 2 files \u2014 internal/store/memory/password.go, internal/store/postgres/account.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":484}}}],"partialFingerprints":{"codehealthFindingId/v1":"33309875604bd3dfda0318dcd8eea9ff4bf8f18dedf9398a4a22cb8b07c94a71"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxSavedStarGiftsLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/star_gift.go, internal/store/postgres/star_gift.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":415}}}],"partialFingerprints":{"codehealthFindingId/v1":"94d0e6c7277c707ada3e8b73090824e45579bb118ab1b7fc1ab03ca6d3e516c9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxStickerCollectionItems(kind)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/password.go, internal/store/postgres/account.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"e591044ec7882cc144d70e21c654e42a9a6ea903d7d798112d143ffb9900d0a1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxStoryInteractionListLimit\u0060 appears character-identically in 5 files \u2014 internal/app/stories/service.go, internal/rpc/stats.go, internal/rpc/stories.go, internal/store/memory/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdfd02f9d1c7b2417b2ed4769918290bf09cb054e0957e201de476280e59b353"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxStoryListLimit\u0060 appears character-identically in 4 files \u2014 internal/app/stories/service.go, internal/rpc/story_pinned_stories_cache.go, internal/store/memory/story.go, internal/store/postgres/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":545}}}],"partialFingerprints":{"codehealthFindingId/v1":"c24adb5973d531ffdde70ab34d06dc4f0bdea18b1548ee19d3c57290f7da8b4a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxStoryPrivacyFanoutTargets\u0060 appears character-identically in 3 files \u2014 internal/app/stories/service.go, internal/store/memory/story.go, internal/store/postgres/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":569}}}],"partialFingerprints":{"codehealthFindingId/v1":"feb8a7f4bb46dacba207a1dce7c20b1946c22a2ecf3710575ba95295f6232a06"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060limit \u003C= 0 || limit \u003E domain.MaxSynchronousChannelDialogFanout\u0060 appears character-identically in 7 files \u2014 internal/app/channels/bot_policy.go, internal/app/channels/service.go, internal/store/memory/channel_helpers.go, internal/store/memory/channel_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":123}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd1f639860a580aca02d4a44093fae76f3f96b99f420b23aae5bbcc215c7dd75"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060line == \u0022\u0022 || strings.HasPrefix(line, \u0022#\u0022)\u0060 appears character-identically in 3 files \u2014 internal/config/config.go, internal/loadharness/server_metrics.go, internal/procctl/procctl.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":2199}}}],"partialFingerprints":{"codehealthFindingId/v1":"2c8b11671c617ddc528bf54cd6cf1096cfebb149165afe96d6ed465faa0dec8f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060mark.VerifierBotID \u003C= 0 || !validBotVerificationPeer(mark.Peer)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":400}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3e839a4138406d59b047e5fb90cf92edf334d2ad0ba696e93069333c45b3f24"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060markup == nil || markup.Kind() != domain.MessageReplyMarkupInline\u0060 appears character-identically in 4 files \u2014 internal/app/ephemeral/service.go, internal/rpc/bots_callback.go, internal/rpc/convert_markup.go, internal/rpc/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":455}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdc221e7a3c6444b1b1f019c2d032741c29a1e23ea044bec281c2d6bb6ce3279"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060max \u003C= 0 || utf8.RuneCountInString(value) \u003C= max\u0060 appears character-identically in 4 files \u2014 internal/app/bots/verifierbot.go, internal/app/bots/verifybot.go, internal/app/botverification/service.go, internal/app/verification/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1579}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f585526ae39f8f51ced40be1d7b8ea5b33fddf03d1445b851e834bc90b4e8bd"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060maxID \u003C= 0 || maxID \u003E channel.TopMessageID\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_message_delete.go, internal/store/memory/channel_read.go, internal/store/postgres/channel_message_delete.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"e607fca267c71509acfbeb97cdef272ba3be566094d2094d203e48f728554108"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060media == nil || media.Poll == nil || media.Poll.Results == nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_polls.go, internal/rpc/update_peer_refs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":94}}}],"partialFingerprints":{"codehealthFindingId/v1":"486e06ee6cb8e93713b0f1bfda5dcd67815df1595ba56254d1e24f37a2f35cef"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060media.BotUserID == 0 || media.AppID == 0 || (media.PhotoID == 0 \u0026\u0026 media.DocumentID == 0)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot.go, internal/store/postgres/bot_miniapp.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":461}}}],"partialFingerprints":{"codehealthFindingId/v1":"fffd52b7d3ef779a3c4084d187204a241090a4c831603efe903398fdbe604be5"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.HistoryClearAnchorID \u003E 0 \u0026\u0026 member.HistoryClearAnchorID == member.AvailableMinID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":377}}}],"partialFingerprints":{"codehealthFindingId/v1":"0aab1bb71ab19f0edac36340a5c7ebd8cdeda7195d5e37e4a5fefdf5be46bd07"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.JoinedAt == 0 \u0026\u0026 member.Status == domain.ChannelMemberActive\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"734727d82d85413b2f9f6bb70e7d50b57c33d64bfda7326f72a1116568bae3b3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role != domain.ChannelRoleCreator \u0026\u0026 member.Role != domain.ChannelRoleAdmin\u0060 appears character-identically in 5 files \u2014 internal/store/memory/channel_boosts.go, internal/store/memory/channel_members.go, internal/store/memory/channel_stats.go, internal/store/postgres/channel_boosts.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4198e64a900eecd73848a58e7100827e52f99d4eb23f77e0ad809ee640f149d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || (member.Role == domain.ChannelRoleAdmin \u0026\u0026 (member.AdminRights.InviteUsers || member.AdminRights\u2026\u0060 appears character-identically in 4 files \u2014 internal/rpc/channels_members.go, internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_helpers.go, internal/store/postgres/channel_invite_members.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":715}}}],"partialFingerprints":{"codehealthFindingId/v1":"5affdfef2c0472241ce62296817d2921016d990d1199735b93335312eebcade0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || (member.Role == domain.ChannelRoleAdmin \u0026\u0026 member.AdminRights.AddAdmins)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1253}}}],"partialFingerprints":{"codehealthFindingId/v1":"48715ba241c6de24683df59aee9d76d6822fb2a8ed1401fd65e2e8b407b6cd7f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || (member.Role == domain.ChannelRoleAdmin \u0026\u0026 member.AdminRights.BanUsers)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1257}}}],"partialFingerprints":{"codehealthFindingId/v1":"f70c0ad7d2a35c6e5178a32276f23d99097bf5a2b5d99b5a2b4f43e4c2c2922e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || (member.Role == domain.ChannelRoleAdmin \u0026\u0026 member.AdminRights.ChangeInfo)\u0060 appears character-identically in 3 files \u2014 internal/rpc/reactions_android_compat.go, internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/reactions_android_compat.go"},"region":{"startLine":23}}}],"partialFingerprints":{"codehealthFindingId/v1":"307fe55985cfa6468e29b7ca4955adbbb7f63402a57a2f7470f4a555128c2085"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || (member.Role == domain.ChannelRoleAdmin \u0026\u0026 member.AdminRights.DeleteMessages)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_delete.go, internal/store/postgres/channel_message_delete.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":292}}}],"partialFingerprints":{"codehealthFindingId/v1":"ae72b353b89302853e96605bac560de7592cd3e1e796634a540ced9daa4f8054"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || (member.Role == domain.ChannelRoleAdmin \u0026\u0026 member.AdminRights.EditMessages)\u0060 appears character-identically in 3 files \u2014 internal/rpc/messages_edit.go, internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"da1b28a83b28e9974b25d237bf3da438984ac2bab0b9234e75c450c34d5a4b8a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || (member.Role == domain.ChannelRoleAdmin \u0026\u0026 member.AdminRights.PinMessages)\u0060 appears character-identically in 3 files \u2014 internal/store/memory/channel_members.go, internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_member_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1249}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9d78359d96d2f69d096cc0a950603f880ea51a0a3f552dce1729c1ec9a406d8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || (member.Role == domain.ChannelRoleAdmin \u0026\u0026 member.AdminRights.PostMessages)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1205}}}],"partialFingerprints":{"codehealthFindingId/v1":"469bfebcbe2b2b2c13e6b92369299497c08a8973746d664300f7a3e533f4d806"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Role == domain.ChannelRoleCreator || member.Role == domain.ChannelRoleAdmin\u0060 appears character-identically in 9 files \u2014 internal/app/channels/bot_policy.go, internal/rpc/convert_channels_core.go, internal/rpc/stories.go, internal/store/memory/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":355}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bdf7f39a659bc83aa833adac3e21c68832fe0f7d1157c533cc310fea9019577"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Status == domain.ChannelMemberBanned || member.Status == domain.ChannelMemberKicked || member.BannedRights.ViewMessages\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1024}}}],"partialFingerprints":{"codehealthFindingId/v1":"8aeb5b62f3895e49d5f6a5c992db0dbaa2bc687e3a1fa6f7adad38d6b7571e71"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Status == domain.ChannelMemberKicked \u0026\u0026 previous.Status == domain.ChannelMemberActive\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":598}}}],"partialFingerprints":{"codehealthFindingId/v1":"93386c6ceb6563bfdfdd60aec245c0acda9ebaecf01bde10ebab17a651144d77"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060member.Status == domain.ChannelMemberKicked || member.Status == domain.ChannelMemberBanned || member.BannedRights.ViewMessages\u0060 appears character-identically in 3 files \u2014 internal/rpc/convert_updates.go, internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_import.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_updates.go"},"region":{"startLine":578}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdb78841d8243b1a59d2606dc86eb3bb0753d0b9a7a9ade6792adc0c5c7d604b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060message.Content.Media != nil \u0026\u0026 !message.Content.Media.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/rpc/ephemeral.go, internal/rpc/welcome_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":436}}}],"partialFingerprints":{"codehealthFindingId/v1":"8cc4f2582d94d7e066ad5dd537040c5337a9342f3683ab2a340eac22b0f1d33c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060message.Content.ReplyMarkup != nil \u0026\u0026 !message.Content.ReplyMarkup.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/rpc/ephemeral.go, internal/rpc/welcome_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"33fcc1da5ccbb05f46c86b804e8bf0185a6974c765370dd3f8d2c3db5c57696c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060messageEntityClassNil(entity) || !storyCaptionEntitySupported(entity)\u0060 appears character-identically in 2 files \u2014 internal/rpc/contacts.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":1034}}}],"partialFingerprints":{"codehealthFindingId/v1":"5279dca817395a3ec178f0df990b055bbebfcd2cc3c0ef777224001534044107"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060messages[i].ChannelID == 0 || messages[i].ID \u003C= 0\u0060 appears character-identically in 3 files \u2014 internal/store/memory/channel_read.go, internal/store/postgres/channel_reaction_helpers.go, internal/store/postgres/channel_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":556}}}],"partialFingerprints":{"codehealthFindingId/v1":"c123e1aaf8d251fcc6ce3b4b6667b9ebe2fea129cca846cad41e6069f056dd1a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060mode != domain.UpdateStateCommitDeliveredOnly \u0026\u0026 mode != domain.UpdateStateCommitDeliveredAndObservedBaseline\u0060 appears character-identically in 2 files \u2014 internal/app/updates/service.go, internal/store/memory/updates.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/updates/service.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb990da30b2f3a1bbdda950610a9febece8788ee066252333864dae434a28c33"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.Body == req.Message \u0026\u0026 sameMessageEntities(msg.Entities, req.Entities)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"9bdca3f0238ebd14d17f181aad656cb019dcaffaf9ef3919279f54d149b55bd8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.Deleted || msg.ID \u003C= member.AvailableMinID\u0060 appears character-identically in 5 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/channel_read.go, internal/store/memory/media_search.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":368}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c056914c432eba9f65f55a0f52b2c478592639f3e1c61ac5096cf342891c82e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.Deleted || msg.ID \u003C= member.AvailableMinID || !channelMessageVisibleToViewerLocked(channel, member, req.UserID, msg)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_views.go, internal/store/memory/channel_reactions.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_views.go"},"region":{"startLine":37}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a703fb8f83e0b8a1407c042f4a3cb3d6bf8c2aa8448a6fde62cd0686c883140"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.Deleted || msg.ID \u003C= readMaxID || msg.SenderUserID == viewerUserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_read.go, internal/store/memory/channel_topic_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":418}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ad8edb4456e0472ab2bd3793629442a291083db151ec78c9189c47276b6b746"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.Discussion == nil || msg.Discussion.ChannelID == 0 || msg.Discussion.MessageID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"9a84241b7e0078b0ce65c42c9ad09d50256a96509f040daacd2fe400fdd51bde"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.From.Type == domain.PeerTypeUser \u0026\u0026 msg.From.ID != 0\u0060 appears character-identically in 2 files \u2014 internal/botapi/projection.go, internal/rpc/messages_reactions_send.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":294}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea9aa0b6ab16e21f10316e436e611a122248dfd1efa7204e7433ee5ff1577931"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.ID != 0 \u0026\u0026 msg.SenderUserID == userID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_join.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"b6a13ff236581aee161f8d13fc77ed72fd7a74e5a0b1d1614e55030e92e05861"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.Media == nil || msg.Media.Kind != domain.MessageMediaKindPoll || msg.Media.Poll == nil || msg.Media.Poll.ID == 0\u0060 appears character-identically in 3 files \u2014 internal/store/memory/channel_polls.go, internal/store/memory/message_polls.go, internal/store/postgres/channel_polls.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_polls.go"},"region":{"startLine":58}}}],"partialFingerprints":{"codehealthFindingId/v1":"e3ff934e6043208471a98292c493530c3279c3fb9083e8a05f8232c037a3fb6a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.Media == nil || msg.Media.Kind != domain.MessageMediaKindTodo || msg.Media.Todo == nil\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"d13297559d312c5d20ebbc293cdb415a66c781800298922b96de650163c0366b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.Message == \u0022\u0022 || utf8.RuneCountInString(msg.Message) \u003E domain.MaxMessageTextLength || len(msg.Entities) \u003E domain.MaxMessageEntityCount\u0060 appears character-identically in 2 files \u2014 internal/app/account/business.go, internal/app/messages/business_automation.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/business.go"},"region":{"startLine":257}}}],"partialFingerprints":{"codehealthFindingId/v1":"6cdd61ed2ca94e4f30df055f2f9fb1322ce11730d1c7fe513d11a4682c112968"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.ReactionUnread \u0026\u0026 msg.From.ID == msg.OwnerUserID \u0026\u0026 reactions.Recent[i].UserID != msg.OwnerUserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_reactions.go, internal/store/postgres/message_reactions.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee0e1cc5c5580de140c24699ff9131094189fda17fc434cda9d71cd9ebde9347"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.ReplyTo != nil \u0026\u0026 msg.ReplyTo.MessageID \u003E 0\u0060 appears character-identically in 5 files \u2014 internal/app/channels/bot_policy.go, internal/botapi/projection.go, internal/store/memory/channel_message_edit.go, internal/store/memory/channel_message_send.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":326}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9170e4f7fb4bbf0add1c4ac2b4e32a27b743ccbee72f4d9344d5808d50cd05f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.ReplyTo == nil || !msg.ReplyTo.ForumTopic || msg.ReplyTo.TopMessageID \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":647}}}],"partialFingerprints":{"codehealthFindingId/v1":"ad56db8855ca3145ccae61318ceef16cb93e7efa9f6d4644cd91701cc1cfeebb"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msg.SenderUserID != actorUserID \u0026\u0026 !canDeleteAnyChannelMessage(member)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_delete.go, internal/store/postgres/channel_message_delete.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"6edb8afc0d3ad257a383012884d88707dd81b6a0441288cb7f6b80e465cd42aa"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060msgID \u003C= 0 || msgID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 5 files \u2014 internal/app/channels/service.go, internal/rpc/messages_history.go, internal/rpc/messages_reactions_lists.go, internal/rpc/messages_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2259}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a38eb31eba616fe9e76f415a69b905f93424f438a86cae8f9b3e16a57b89b7d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060name == \u0022\u0022 || len([]rune(name)) \u003E domain.MaxBotNameLength\u0060 appears character-identically in 2 files \u2014 internal/admin/service.go, internal/app/bots/botfather.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":2405}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa6506a6d4fca5637915a66ecaa5b487e9614c9ab1db01307f70ab425dfd258c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060newKind \u0026\u0026 len(final) \u003E channel.ReactionPolicy.UniqueReactionsLimit()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":100}}}],"partialFingerprints":{"codehealthFindingId/v1":"ed9a6f58d5822a22c3e9f3086c248db9856d4c70fa78d96f3861b8a0f4617c6b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060next.Status == domain.ChannelMemberKicked || next.BannedRights.ViewMessages\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":695}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f99f8e17c6335ce3b71e33d4e2d3864eb529a3c9363ce523709bcfc175849b6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060now.IsZero() || limit \u003C= 0 || limit \u003E 100 || lease \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/moderation.go, internal/store/postgres/moderation_cases.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":772}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f64eb33c884ed5db8638ebf5b24263cd9831fd9e25db487c47cded9c26d5cb9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060offset \u003C 0 || length \u003C= 0 || offset \u003E limit || length \u003E limit-offset\u0060 appears character-identically in 2 files \u2014 internal/rpc/contacts.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":1038}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d5cf672f9f19e72e8e0e48b523a21f54f989d5130bf8d971c262811643672f4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060ok \u0026\u0026 member.Status == domain.ChannelMemberActive \u0026\u0026 !member.BannedRights.ViewMessages\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"b3ccf32515f9dfdef5e746c7c0aa7920739c84bda693b7256cb47fde1fe7f879"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060oldBroadcastID != 0 \u0026\u0026 oldBroadcastID != broadcastID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":812}}}],"partialFingerprints":{"codehealthFindingId/v1":"334c5ea1894f436fccbec487d4b8aadf6728e7032164c6529192336ea5188c11"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060oldGroupID != 0 \u0026\u0026 oldGroupID != groupID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":807}}}],"partialFingerprints":{"codehealthFindingId/v1":"3bd5a39357d8c83f283aa3779c5a4009304c5357503327dedd13b1e00d1cd6ef"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060oldGroupID == groupID \u0026\u0026 group.LinkedChatID == broadcastID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":803}}}],"partialFingerprints":{"codehealthFindingId/v1":"74372bff8ae2ee8c8bf6f3d3319b93bb5b9a92bb64d69bd06ba52b1d59e55403"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060olderThan.IsZero() || limit \u003C= 0 || limit \u003E 10000\u0060 appears character-identically in 7 files \u2014 internal/store/memory/auth_delivery_report.go, internal/store/memory/client_telemetry.go, internal/store/memory/moderation.go, internal/store/postgres/auth_delivery_report.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/auth_delivery_report.go"},"region":{"startLine":67}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9e131aa84f956d77e58784b31e1ac2611cdef30cbff114c43a320dae73aa487"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060option.text == \u0022\u0022 || option.choice == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/app/bots/verifierbot.go, internal/app/bots/verifybot.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1231}}}],"partialFingerprints":{"codehealthFindingId/v1":"b2fc8d121a7a36ecc3fcc940473c3d23d5ef00f1de994bdca4b7490b6a56a5a3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060owned.Pinned == req.Pinned \u0026\u0026 (!req.Pinned || req.PmOneside)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_pin.go, internal/store/postgres/message_pin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":40}}}],"partialFingerprints":{"codehealthFindingId/v1":"e96dcdbea131f6bd803862500a4165e1f74a49d1c23f92defe6a249def331527"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060owner.ID != 0 \u0026\u0026 (owner.Type == domain.PeerTypeUser || owner.Type == domain.PeerTypeChannel)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/star_gift.go, internal/store/postgres/star_gift.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":948}}}],"partialFingerprints":{"codehealthFindingId/v1":"12258f8141132b9cb508d8c13db1607c07391a053de8ffcce8e64b1aa2fd5d71"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060ownerID == 0 || r.deps.Stories == nil || r.deps.Updates == nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/contacts.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/contacts.go"},"region":{"startLine":132}}}],"partialFingerprints":{"codehealthFindingId/v1":"6d32580b861441ec58e7d69d546ef4fdc55f209c88ad4a747ac212111defea9a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060ownerUserID == 0 || peer.Type != domain.PeerTypeUser || peer.ID == 0\u0060 appears character-identically in 3 files \u2014 internal/store/memory/message_read.go, internal/store/postgres/history_ttl.go, internal/store/postgres/message_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_read.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"b0b9b522474d99b531c6d7ebf00b937920a8adf37ca6acc918251a2bd0b473c7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.ID == 0 || (peer.Type != domain.PeerTypeUser \u0026\u0026 peer.Type != domain.PeerTypeChannel)\u0060 appears character-identically in 6 files \u2014 internal/app/dialogs/draft_read_model_cache.go, internal/app/dialogs/service.go, internal/botapi/projection.go, internal/rpc/botapi_update_queue.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/dialogs/draft_read_model_cache.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"0183d4e63742d62e38221488474e370aa429b393a9ef014351bb63c39c660b81"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type != domain.PeerTypeChannel || peer.ID \u003C= 0\u0060 appears character-identically in 4 files \u2014 internal/rpc/ephemeral.go, internal/rpc/payments_star_gifts.go, internal/rpc/welcome_messages.go, internal/store/postgres/welcome_message.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"8544739869eaa030c37753a1532d95e108f9d7f2d5a6520672b1427468b61d18"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type != domain.PeerTypeChannel || peer.ID == 0\u0060 appears character-identically in 12 files \u2014 internal/rpc/channels_invites.go, internal/rpc/channels_legacy_chat.go, internal/rpc/channels_stubs.go, internal/rpc/channels_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_invites.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"96d32b5b13a6c7ce832e76bfe380c41d16bed0fdbac33e8008a0001b81684dc8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type != domain.PeerTypeChannel || r.deps.Channels == nil\u0060 appears character-identically in 3 files \u2014 internal/rpc/bots_callback.go, internal/rpc/messages_dialogs.go, internal/rpc/messages_reactions_lists.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"b35ccfd7acd38ea6095bd1a83121e3fc65a5389b0bb689703eebce8c5033e986"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type != domain.PeerTypeUser \u0026\u0026 peer.Type != domain.PeerTypeChannel\u0060 appears character-identically in 2 files \u2014 internal/rpc/bots_inline.go, internal/store/postgres/message_send.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c43dcb83e49df25248d99da9d497fdfa1d493768eedbc1de330a1300c0851ea"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type != domain.PeerTypeUser || peer.ID == 0\u0060 appears character-identically in 4 files \u2014 internal/rpc/channels_stubs.go, internal/rpc/messages_helpers.go, internal/rpc/update_peer_refs.go, internal/store/postgres/message_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"52899140f1e1e545f498b5dbed2dcb2d9791efb192dc40d65dba81a4eaf0bb83"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type != domain.PeerTypeUser || peer.ID == userID\u0060 appears character-identically in 2 files \u2014 internal/rpc/account_business.go, internal/rpc/messages_forward.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"22572aafbdea248695ff9008cb79908975c675def14117f22455d95aa1d6bca6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type != domain.PeerTypeUser || r.deps.Messages == nil\u0060 appears character-identically in 3 files \u2014 internal/rpc/messages_edit.go, internal/rpc/messages_edit_geolive.go, internal/rpc/messages_todos.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":148}}}],"partialFingerprints":{"codehealthFindingId/v1":"50b519ac6541559be8bda02c3335a95c556342783c890aacc72b30a17fe504d9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type == domain.PeerTypeChannel \u0026\u0026 r.deps.Channels != nil\u0060 appears character-identically in 8 files \u2014 internal/rpc/messages_history.go, internal/rpc/messages_polls.go, internal/rpc/messages_reactions_lists.go, internal/rpc/messages_reactions_send.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc24175fd839a0a316a496198bc0c2dc722a34eb45e24c745fd732f9ccc51eeb"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type == domain.PeerTypeUser \u0026\u0026 peer.ID != 0\u0060 appears character-identically in 3 files \u2014 internal/rpc/channels_topics.go, internal/rpc/messages_monoforum.go, internal/rpc/messages_reactions_send.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_topics.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"1d1774dacb2373e52ede60c58b191fdbeadc465384186af42588edca7085ce8a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type == domain.PeerTypeUser \u0026\u0026 peer.ID != userID\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_pin.go, internal/rpc/messages_ttl.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_pin.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"893728a6ed319318d79bf648f891f0b63afbdf5276b59506d3d173b6e9d32e6e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peer.Type == domain.PeerTypeUser \u0026\u0026 r.deps.Messages != nil\u0060 appears character-identically in 4 files \u2014 internal/rpc/messages_history.go, internal/rpc/messages_reactions_lists.go, internal/rpc/messages_reactions_send.go, internal/rpc/stats.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_history.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"a835fe86af39b4d09414708cecbbb662b1104c49782096128117a3eeb2939129"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peerType != domain.PeerTypeUser \u0026\u0026 peerType != domain.PeerTypeChannel\u0060 appears character-identically in 2 files \u2014 internal/adminapi/botverification.go, internal/app/bots/verifierbot.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/adminapi/botverification.go"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"5613ae16038d2ebbe4535d3836f8676a438edc8048a7fef64d1482a3683c4355"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peerType != string(domain.PeerTypeUser) || peerID \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/star_gift_lifecycle_projection.go, internal/store/postgres/star_gift_upgrade.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle_projection.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"9681a89cd28726a627701bdbfd7203bf4308788b3f1cf7b105c71a2d3be63782"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060peerType == domain.PeerTypeUser || peerType == domain.PeerTypeChannel\u0060 appears character-identically in 3 files \u2014 internal/app/botverification/service.go, internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/botverification/service.go"},"region":{"startLine":1481}}}],"partialFingerprints":{"codehealthFindingId/v1":"4dc3a27ce17e360d328caaa1f369145f6b73c2a931de69514f35b15b96849522"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060period != foreverLiveLocationPeriod \u0026\u0026 (period \u003C minLiveLocationPeriod || period \u003E maxLiveLocationPeriod)\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_edit_geolive.go, internal/rpc/send_media.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4b5be4b8f674190738138da64d89c3ec4e7c4073658e2a1ece13320f1b68676"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060pgErr.Code == \u002240P01\u0022 || pgErr.Code == \u002240001\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/auth_identity_lock.go, internal/store/postgres/channel_core.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/auth_identity_lock.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"7894a7851726b7bea6bf9fa864df4ab5580e748f3955a8e8be6f62169cde01ec"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060prevForum != channel.Forum || prevTabs != channel.ForumTabs\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b523a37d3b396ae3c8c56be18790cc428dcd5d1080704f80a7cea68cd3e53b4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060prevMsg.Body != req.Message || !sameMessageEntities(prevMsg.Entities, req.Entities)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"c99b677c5dd8b613450e5f7d575b10124b27b660f191430914b6339d8288f2d1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060previous.Status == domain.ChannelMemberKicked || previous.BannedRights.ViewMessages\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":698}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1527181133eff5309f203cf73ffa6d8d481b42693fecb8e2c41b4a7b57fe678"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060query != \u0022\u0022 \u0026\u0026 !strings.Contains(strings.ToLower(msg.Body), query)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/memory/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"9813288f93cd1ed2caf14f700c19aa8e13bb5bd5c65f75cc48b97813fcc70aad"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060r == nil || r.deps.BotAPIUpdates == nil || botID == 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/botapi_gateway.go, internal/rpc/botapi_update_queue.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_gateway.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9e4505b6288a6fb1299b6f8dc4fbd2befe150bf7eb0556f1cb38be6f9451d96"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060r.Method != http.MethodGet \u0026\u0026 r.Method != http.MethodHead\u0060 appears character-identically in 3 files \u2014 cmd/walletminiapp/main.go, internal/mtprotoedge/server_info_http.go, internal/webclient/webclient.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/walletminiapp/main.go"},"region":{"startLine":149}}}],"partialFingerprints":{"codehealthFindingId/v1":"0fa8f677c9dec16aaf7f508e86cbd9da3399b5870d8ef3987fcfc92864eb9ab7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060r.deps.Channels != nil \u0026\u0026 len(channelIDs) \u003E 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/chatlists.go, internal/rpc/messages_saved_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/chatlists.go"},"region":{"startLine":366}}}],"partialFingerprints":{"codehealthFindingId/v1":"61e3d890ca9a6c0cf1e69b679ebf3acb811a75c1eb8a2b2c8423e1d93a457ea4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060r.deps.Channels == nil \u0026\u0026 r.deps.Communities == nil\u0060 appears character-identically in 5 files \u2014 internal/rpc/channels_core.go, internal/rpc/channels_legacy_chat.go, internal/rpc/channels_members.go, internal/rpc/channels_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"90dc7969cf77b7e8a9dda3a6974a6a7ab8f441b72303963c0211bc749039f814"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060r.deps.Channels == nil || channel.ID == 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_members.go, internal/rpc/channels_stubs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":720}}}],"partialFingerprints":{"codehealthFindingId/v1":"7978ae2c23dc78da66418a030517dd38ecc460bc746f1e927b4fbb2c8a59c19c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060r.deps.GroupCalls == nil || r.deps.Channels == nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/phone_group_call.go, internal/rpc/phone_group_call_rtmp.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":187}}}],"partialFingerprints":{"codehealthFindingId/v1":"d14535d14eafa586da2102e50a8b81603cb9fad3fb20dbf854b1c45b5a48b84a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060r.deps.Stories == nil || viewerUserID == 0 || len(peers) == 0\u0060 appears character-identically in 2 files \u2014 internal/rpc/story_peer_projection.go, internal/rpc/story_projection_cache.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/story_peer_projection.go"},"region":{"startLine":671}}}],"partialFingerprints":{"codehealthFindingId/v1":"677f0eaeab8031e254c8eb8e4ae7511dd2affb74f581f1bddb06973f03d440ee"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060r.deps.Users == nil || r.deps.Channels == nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/ephemeral.go, internal/rpc/welcome_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"56df4540dedcfcd5b52352090339b54150172128f5b0e1f3cf4bc5967fc81559"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060radius \u003C 0 || radius \u003E maxProximityRadiusMeters\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_edit_geolive.go, internal/rpc/send_media.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit_geolive.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"db208f61683f355a97fb66511cf9b51d4f66ac144c9c3ef3ec1971693bd1f0c8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060rating.PendingStars == 0 || rating.PendingDate.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/account_rating.go, internal/store/postgres/account_rating.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/account_rating.go"},"region":{"startLine":375}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff90e5c3fd1b87a25fb33e35132975ddf8f64ec1d72beb709aac245b5de1298e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060raw == \u0022\u0022 || len(raw) \u003E maxTelegramLoginURLLength || raw != strings.TrimSpace(raw) || strings.IndexFunc(raw, unicode.IsControl) \u003E= 0\u0060 appears character-identically in 2 files \u2014 internal/app/telegramlogin/native.go, internal/app/telegramlogin/url.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/native.go"},"region":{"startLine":49}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9fca4c62034932bca7147cc1e71dce5cc0a93886cb5e11da3e418e729f2f9ed"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060raw == \u0022\u0022 || raw == \u0022[]\u0022 || raw == \u0022null\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/poll.go, internal/store/postgres/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/poll.go"},"region":{"startLine":411}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec64d1c80d94e760e9d7718976514d3169616f95f8dad5f1458cda79233ae115"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060raw == \u0022\u0022 || raw == \u0022{}\u0022 || raw == \u0022null\u0022\u0060 appears character-identically in 3 files \u2014 internal/store/postgres/channel_core.go, internal/store/postgres/story.go, internal/store/postgres/update_event.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":696}}}],"partialFingerprints":{"codehealthFindingId/v1":"281a13daebfc6db873f948b136e8a74e56f9f525251d6a0738155a074e3210df"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060reactionsFirst \u0026\u0026 view.Reaction == nil \u0026\u0026 view.Repost == nil \u0026\u0026 view.PublicForward == nil\u0060 appears character-identically in 3 files \u2014 internal/rpc/stories.go, internal/store/memory/story.go, internal/store/postgres/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3383}}}],"partialFingerprints":{"codehealthFindingId/v1":"34cb23c02122e308843c944ff441db2c5e48b7952f6b0d6150add4ae873ca9d7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060recipientID == 0 || recipientID == ownerUserID\u0060 appears character-identically in 2 files \u2014 internal/rpc/photos.go, internal/rpc/presence.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":708}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef1ccc8aebf7b16584d0e14bb42f88712cf2038fc0e3d5469191af95f87cbc60"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060ref.CheckAccessHash \u0026\u0026 ref.AccessHash != view.Community.AccessHash\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_core.go, internal/rpc/communities.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_core.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"5544d16254f0800746ecf487163ddfaeb56c55b22b9ef41d8e190c7fb3d59593"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060ref.Kind == domain.StickerSetRefByID \u0026\u0026 set.AccessHash != ref.AccessHash\u0060 appears character-identically in 2 files \u2014 internal/app/files/sticker_management.go, internal/rpc/messages_sticker_sets.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_management.go"},"region":{"startLine":238}}}],"partialFingerprints":{"codehealthFindingId/v1":"2bbf4682dbea07ae28741c0aadc448129637f7fb1c66e23ba22bd94c96387601"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ApplicantUserID \u003C= 0 || req.TargetID \u003C= 0 || !req.TargetType.Valid()\u0060 appears character-identically in 3 files \u2014 internal/app/verification/service.go, internal/store/memory/verification.go, internal/store/postgres/verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/verification/service.go"},"region":{"startLine":490}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e2e16d287c04d39947d533c33c8b691833f7be8b76856e6e14d57701a5285fb"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.CallID == 0 || len(req.TargetUserIDs) == 0 || req.OnlyLeft == req.Kick\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"d27fc5fa7e211bded945b8df7f3c834ccfb21eb0996df86d23ae6d4ea5aa9fad"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Closed != nil \u0026\u0026 next.Closed != *req.Closed\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":232}}}],"partialFingerprints":{"codehealthFindingId/v1":"205a92aa96767feb8f3727f1374ce8f179b9bd0ded87d922e954b8beb6183a5c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.CreatorUserID == 0 || strings.TrimSpace(req.Title) == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_core.go, internal/store/postgres/channel_core.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"2abe8471cf5b77d2645aae3f37b5ecab03e583f7cf7e47ee36428a36e7094756"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ExpireDate \u003C 0 || req.UsageLimit \u003C 0 || len(req.Title) \u003E domain.MaxChannelInviteTitleLength\u0060 appears character-identically in 2 files \u2014 internal/app/channels/service.go, internal/rpc/channels_invites.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1747}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa3fcb1cde76ef2598fa0a918e6471e44df1c33839c6fe125353975f23b6b45b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ExpireDate == 0 \u0026\u0026 req.UsageLimit == 0 \u0026\u0026 !req.RequestNeeded \u0026\u0026 req.Title == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_exported.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"22e846010377f479fe3b2a96c3fb6b55801e82e6383b61751aa87238c050b3ae"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Hidden != nil \u0026\u0026 next.Hidden != *req.Hidden\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":237}}}],"partialFingerprints":{"codehealthFindingId/v1":"880ae406059b0131bdfc42a951c2981f09c0bc7164fdc8e493c6f091191b4f9a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ID \u003C= 0 || req.ID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 9 files \u2014 internal/app/channels/service.go, internal/rpc/channels_messages.go, internal/rpc/channels_topics.go, internal/rpc/messages_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1300}}}],"partialFingerprints":{"codehealthFindingId/v1":"1ce5164cb37116f316214d6f5ad29a343400720cebce6975741cc192cf28493e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ID \u003C= 0 || req.ID \u003E domain.MaxStoryID\u0060 appears character-identically in 3 files \u2014 internal/app/stories/service.go, internal/rpc/stats.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":336}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d8465c8e6b887cf85bd9a22cf75eed28932ec8f55610268905d93a6af1d0bae"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.IconEmojiID != nil \u0026\u0026 next.IconEmojiID != *req.IconEmojiID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"fec74d2c6aad6f7e0dd72e6ade052bd1c8e55e6c09a55673a266de54c82efc40"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.JustClear \u0026\u0026 req.MaxID \u003C= 0 \u0026\u0026 req.MinDate \u003C= 0 \u0026\u0026 req.MaxDate \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_history.go, internal/store/postgres/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"7aea98764eea0b732b6eb8d086d18900f6a81fdcfaa12a26b2a8114262ef942c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Kind != domain.BotAPIUpdateCallbackQuery || req.Peer.ID != 0 || req.MessageID != 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/botapi_update.go, internal/store/postgres/botapi_update.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":431}}}],"partialFingerprints":{"codehealthFindingId/v1":"c241c39cf10a2556fd6c17c46ca2bfbebca9366f5bb4fb896d34542fefceeaf6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Kind != domain.BotAPIUpdateMessage \u0026\u0026 req.Kind != domain.BotAPIUpdateEditedMessage \u0026\u0026 req.Kind != domain.BotAPIUpdateCallbackQuery\u0060 appears character-identically in 2 files \u2014 internal/store/memory/botapi_update.go, internal/store/postgres/botapi_update.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a831e8f6939c38114f88316ccb6d9c3398e0772f614abaa4413e6f005544b38"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Limit \u003C 0 || req.Limit \u003E maxSearchResultsLimit\u0060 appears character-identically in 3 files \u2014 internal/rpc/messages_polls.go, internal/rpc/messages_reactions_catalog.go, internal/rpc/messages_reactions_lists.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a36d5575caba71172a6bdbde4704e161d6f791ca67d886ed70c4b33711cf865"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Limit \u003C= 0 || req.Limit \u003E domain.MaxChannelMessageReactionListLimit\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"67127af5ea61061c99a6dbfd5690c149660bddd97246c3ec66a0151912d61386"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Limit \u003C= 0 || req.Limit \u003E domain.MaxDeleteParticipantReactionsBatch\u0060 appears character-identically in 3 files \u2014 internal/app/channels/service.go, internal/store/memory/channel_reactions.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1221}}}],"partialFingerprints":{"codehealthFindingId/v1":"3df35f8de407a5e8ff559667bdbbbfe115b94f2e387f39e363ac2b0df356e20f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Limit \u003C= 0 || req.Limit \u003E domain.MaxSavedReactionTags\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_saved_reactions.go, internal/store/postgres/message_saved_reactions.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_saved_reactions.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"35ac631e566549784826013895b038b211188577de9d3d6ba5b083efe7621559"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MaxDate \u003E 0 \u0026\u0026 msg.Date \u003E req.MaxDate\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_history.go, internal/store/memory/saved_dialog.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":230}}}],"partialFingerprints":{"codehealthFindingId/v1":"d2e9092e2f6436849fd2bb56a7b9c364bc4969f093a6a5b25ebef187c6f5ccec"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MaxID \u003C 0 || req.MaxID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 3 files \u2014 internal/rpc/channels_messages.go, internal/rpc/messages_compat.go, internal/rpc/messages_delete.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_messages.go"},"region":{"startLine":385}}}],"partialFingerprints":{"codehealthFindingId/v1":"917428df715ba118730011adf1c35ffc64e97fb66fd1c50ae728c9beae8c1ba5"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MaxID \u003C= 0 \u0026\u0026 req.Peer.ID != req.OwnerUserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_history.go, internal/store/postgres/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb2e69c58cbb4bf18996317e5e466150b2fca9baa521c2fd0d082765177a7a55"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Media == nil \u0026\u0026 !req.SetReplyMarkup \u0026\u0026 !richChanged \u0026\u0026 msg.Body == req.Message \u0026\u0026 sameMessageEntities(msg.Entities, req.Entities)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"e689c3bee0a35f0a6e1888a5ba26d404046e20f2026b774b89145274de3e54c6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Media == nil || !domain.IsPendingWebPageMedia(msg.Media, req.ExpectedWebPageID)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"5621587e56d9db834be7cc42b021a8d86ed6eb81049fae36897901a3f2940252"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MemberID != req.UserID || channel.CreatorUserID != req.UserID || actor.Role != domain.ChannelRoleCreator\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":317}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a7ff49afa4ba76c054a8125d77c1276262e5122fd6ac18cb9b22759345a19a1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MessageID \u003C= 0 || req.MessageID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 3 files \u2014 internal/store/memory/message_pin.go, internal/store/postgres/channel_read.go, internal/store/postgres/message_pin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"c0619f5be16bca689444e2f99ec6fcbd0261c2b19320023b9caff049ea574d28"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MessageID == 0 \u0026\u0026 (inline == nil || inline.DCID \u003C= 0 || inline.OwnerID \u003C= 0 || inline.ID \u003C= 0 || inline.AccessHash == 0)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/botapi_update.go, internal/store/postgres/botapi_update.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/botapi_update.go"},"region":{"startLine":456}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3cbaaa6b795a7c97e47b1b88644848f6625220f5c20811a2836ed3fb61ee096"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MinDate \u003E 0 \u0026\u0026 msg.Date \u003C req.MinDate\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_history.go, internal/store/memory/saved_dialog.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"21bdebd39afc48010db3f625007302b113aa240b9c2f655791e92a80756986ef"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MonoforumID == 0 || req.SenderUserID == 0 || req.SavedPeer.ID == 0 || req.SavedPeer.Type != domain.PeerTypeUser || strings.TrimSpace(req\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_monoforum.go, internal/store/postgres/channel_monoforum.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":19}}}],"partialFingerprints":{"codehealthFindingId/v1":"8fff2facb629ee83cfe8ba11db81e7e5b2edb6a77dd51f101651a8e0b7f952e4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.MsgID \u003C= 0 || req.MsgID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 9 files \u2014 internal/rpc/bots_callback.go, internal/rpc/channels_settings.go, internal/rpc/messages_helpers.go, internal/rpc/messages_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_callback.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"df8a5b33f70314c30af2085e48e8a384075e37783ac6a352d0ef314ca4a04f88"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.NoForwards || channel.NoForwards || linked.NoForwards\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_send.go, internal/store/postgres/channel_message_send.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_send.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"055b4a3f3589720a33c5071b52f33e4cbcebef7f232aeba18c5818b9bb3b7c7b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.OffsetChannelID \u003E 0 \u0026\u0026 req.OffsetID \u003E 0\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/channel_helpers.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"cf61570b58c9954612caa22dbcddfff57ecd5375e1b8e903a9ee5fb615786d84"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.OffsetDate \u003E 0 || req.OffsetUserID \u003E 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/poll.go, internal/store/postgres/poll.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/poll.go"},"region":{"startLine":76}}}],"partialFingerprints":{"codehealthFindingId/v1":"03ecd6e4cf3132c47456fbf52337cd928b17f0d8a227566dd9f1f8d7f1c462c2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.OffsetRate \u003E 0 \u0026\u0026 req.OffsetChannelID \u003E 0 \u0026\u0026 req.OffsetID \u003E 0\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/channel_helpers.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":261}}}],"partialFingerprints":{"codehealthFindingId/v1":"2d71268d1ae5b0ee57a18c91fb023d9e19789c11c3c822f8a9a2209a6ad00698"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Owner.Type != domain.PeerTypeUser \u0026\u0026 req.Owner.Type != domain.PeerTypeChannel\u0060 appears character-identically in 3 files \u2014 internal/app/channels/service.go, internal/store/memory/channel_message_history.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":2243}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec16961668bb01346509ce0741dcea14833cb66585f7839564847a3e9ff142e7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.OwnerUserID == 0 || req.Peer.Type != domain.PeerTypeUser || req.Peer.ID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_pin.go, internal/store/postgres/message_pin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":15}}}],"partialFingerprints":{"codehealthFindingId/v1":"0570349f8a4408a69c96c25967609810715742936f36834ae2d8b9947ca38a28"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.OwnerUserID == 0 || req.Peer.Type != domain.PeerTypeUser || req.Peer.ID == 0 || len(req.IDs) \u003E domain.MaxGetMessageIDs\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_reactions.go, internal/store/postgres/message_reactions.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":74}}}],"partialFingerprints":{"codehealthFindingId/v1":"96512bb53944224dfd523f3d3321ead79139113c430bdeae16c071f961eb0f70"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.OwnerUserID == 0 || req.Peer.Type != domain.PeerTypeUser || req.Peer.ID == 0 || req.ID \u003C= 0 || req.ID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_read.go, internal/store/postgres/message_read.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_read.go"},"region":{"startLine":105}}}],"partialFingerprints":{"codehealthFindingId/v1":"01b1eca6c9b94bd7a8ceff18e8fc52b1f09945fe0dc9953448be3689ccbc848c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Peer.ID != req.OwnerUserID \u0026\u0026 (!req.Pinned || !req.PmOneside)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_pin.go, internal/store/postgres/message_pin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_pin.go"},"region":{"startLine":51}}}],"partialFingerprints":{"codehealthFindingId/v1":"29580a5b6aa4d7b0eeb97ccae260f9887121e153d2e1cf742c0007f7a0a67dd2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.RandomID != 0 \u0026\u0026 !req.IdempotencyPreflighted\u0060 appears character-identically in 4 files \u2014 internal/app/channels/service.go, internal/app/messages/service.go, internal/store/postgres/channel_message_send.go, internal/store/postgres/channel_monoforum.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1443}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5b13c334039af51341cb25f8347e1a614f13c87eb18d2d05ef13b422253730f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ReplyTo.TopMessageID \u003C= 0 || !channel.Forum\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":540}}}],"partialFingerprints":{"codehealthFindingId/v1":"201d2a773e96737ed14f65d9df1e4cd54bcb92293742df5ef8e00c1310715b92"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.Revoke \u0026\u0026 req.Peer.ID != req.OwnerUserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_history.go, internal/store/postgres/message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_history.go"},"region":{"startLine":242}}}],"partialFingerprints":{"codehealthFindingId/v1":"09a76abe91bad13e1f01a73ca9910360fc61e34c13e3112be29dcc69a9443319"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ScheduleDate != 0 \u0026\u0026 !scheduleDateIsImmediate(req.ScheduleDate, int(r.clock.Now().Unix()))\u0060 appears character-identically in 4 files \u2014 internal/rpc/bots_inline.go, internal/rpc/messages_forward.go, internal/rpc/messages_send.go, internal/rpc/send_media.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_inline.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"16e49044f7644de0084a03a08b334b9e8435c4e5af2f15842283919cbd2c9c3e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.SenderUserID != req.SavedPeer.ID \u0026\u0026 !isAdmin\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_monoforum.go, internal/store/postgres/channel_monoforum.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_monoforum.go"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a37d6b59fe49afd598e63b5fe27613feb9e6ebe139a063c492e3e2ca24158bc"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.SetRichMessage \u0026\u0026 !richMessagesEqual(msg.RichMessage, req.RichMessage)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"239944355228b5b69b8ec1177f1c2aa58c147be0bf6b162af1c4af169f587494"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.StoryID \u003C= 0 || req.StoryID \u003E domain.MaxStoryID\u0060 appears character-identically in 2 files \u2014 internal/app/stories/service.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stories/service.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"a9d983f591e2d45d301eadb13320dee69c5ccced01c44addba51906778c04b78"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.URL.Scheme != \u0022http\u0022 \u0026\u0026 req.URL.Scheme != \u0022https\u0022\u0060 appears character-identically in 2 files \u2014 internal/app/files/external_media.go, internal/app/files/webpage.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/external_media.go"},"region":{"startLine":93}}}],"partialFingerprints":{"codehealthFindingId/v1":"40bf636d90946851d0708b07d883debed5cc189da952832482b9d24af56a686a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || len(req.IDs) == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_delete.go, internal/store/postgres/channel_message_delete.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"ef2afb896782dd8688b65fa92dc0175e51e8a3c62e9f2d03c1597cd85792a539"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || len(req.Order) \u003E domain.MaxChannelForumTopicIDs\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":319}}}],"partialFingerprints":{"codehealthFindingId/v1":"887f3c8dd599ddc82992ae2494436f9a23c16ad7384964a6e6178f5b65c3a1b1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.AdminUserID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_exported.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"98c7bc37a826b6f116f634fe1b912de1fb8b2787366b2492e816b1e0278d8d5e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.MaxID \u003C 0 || req.MinID \u003C 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_admin_log.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"b87ad6d1ddccf9d8f1758579d40f2968796c4d1758b9d41b85db0b1a01949c51"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.MemberID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff70a41dc7f77d01dd25c0955479ab3708d0985315b7812ac611440f7277a6d3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.MessageID \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"440bc224b27512c3b39a95a754cdcedc0166db9adc7b8360051db891a1e24c7c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.MessageID \u003C= 0 || req.MessageID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":32}}}],"partialFingerprints":{"codehealthFindingId/v1":"ca58cecf35fb9768bee005769ee18f3824627733f348b04d8f232af96e10e428"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.MessageID \u003C= 0 || req.MessageID \u003E domain.MaxMessageBoxID || req.ParticipantUserID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":172}}}],"partialFingerprints":{"codehealthFindingId/v1":"00a4c1b9610442b99bbaa18189f7afabb238d015d75817542c1de75bf27bbd7f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.NewOwnerID == 0 || req.NewOwnerID == req.UserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":409}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5330032609238f6689fbf1817fad894e31c201906bdb9a60163116a6628a718"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.Participant.Type != domain.PeerTypeUser || req.Participant.ID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_admin.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":535}}}],"partialFingerprints":{"codehealthFindingId/v1":"1773e1e10862937e778abd0a4f6dace917c7e13460ef4a207c10846023ade073"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.ParticipantUserID == 0\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_message_delete.go, internal/store/memory/channel_reactions.go, internal/store/postgres/channel_message_delete.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_delete.go"},"region":{"startLine":158}}}],"partialFingerprints":{"codehealthFindingId/v1":"f3d1a6b0116cf584df4b56686e467c5a66d346505843eb75cd53d49fe8e6b987"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.RandomID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"219c5ccdb54de6adf8238f57d5ee5a403804a8db3062341c8a3233def3d98dca"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.TargetUserID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_join_requests.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":815}}}],"partialFingerprints":{"codehealthFindingId/v1":"093deed7ff0a41e22af9d45de9e31437287b16172a0f51905a4941c3f95138be"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || req.TopicID \u003C= 0\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_topic_read.go, internal/store/memory/channel_topics.go, internal/store/postgres/channel_topic_read.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topic_read.go"},"region":{"startLine":107}}}],"partialFingerprints":{"codehealthFindingId/v1":"c66e0577cd85e4d9a74dfcd7ae025e964a0dc945d62d2a6dd75a819305e5a215"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || strings.TrimSpace(req.Hash) == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_exported.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":402}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f7223d346681647e4e8a8b369f03b2a819b6059a2c7e9ba0c8651e93d5fd8f9"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.ChannelID == 0 || strings.TrimSpace(req.Title) == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":12}}}],"partialFingerprints":{"codehealthFindingId/v1":"bf07cb158b15150decffb36dab5fc7c0e443cc44866538a3c28202b9698766de"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.Document.ID == 0 || !req.Document.IsMusic()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/password.go, internal/store/postgres/account.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/password.go"},"region":{"startLine":433}}}],"partialFingerprints":{"codehealthFindingId/v1":"07593b8667f6a896f71aeb275e227ef208a0147560cb5a006e74b4835c867162"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.Peer.Type != domain.PeerTypeUser || req.Peer.ID == 0 || req.MessageID \u003C= 0 || req.MessageID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_reactions.go, internal/store/postgres/message_reactions.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_reactions.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"5077e8b03f258b2644940354d79ceb8900b0c3699a7ba0cda80883cb1ae9e328"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.SourceChannelID \u003C 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":639}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2ab249a4302dd8de9b3a0b9bb2c8da9b95e1a42d713a41c78c91922d1a0f646"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || req.TargetUserID == 0 || req.UserID == req.TargetUserID || req.MaxID \u003C 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":164}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4bd778e511b42267582ae2de5d2085d62aae88d064b6f77e5bfcdabbbe117b8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.UserID == 0 || strings.TrimSpace(req.Hash) == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_import.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":309}}}],"partialFingerprints":{"codehealthFindingId/v1":"58c917b6bed1ab9a0424fb93b89ca50543d3bd18732e7208d80ed40438274f29"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ViaBotEditBotID != 0 \u0026\u0026 target.ViaBotID == req.ViaBotEditBotID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_edit.go, internal/store/postgres/message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_edit.go"},"region":{"startLine":33}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e085a69a75e00963e1bd9b671f9d0751afb7d5fb0396684134372b5eb6f3f3b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ViewerUserID == 0 || req.ChannelID == 0 || !req.Period.Valid()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_stats.go, internal/store/postgres/channel_stats.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"658b708207c78a73cbcac373418714133ca6a496abeb02dcbe3ae7dd1777db98"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ViewerUserID == 0 || req.ChannelID == 0 || req.MessageID \u003C= 0 || req.MessageID \u003E domain.MaxMessageBoxID || !req.Period.Valid()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_stats.go, internal/store/postgres/channel_stats.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":203}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0e0010ccaf1b9941e276f71172847f6207ffafc961059424e64b25b7197ef43"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ViewerUserID == 0 || req.ChannelID == 0 || req.MessageID \u003C= 0 || req.MessageID \u003E domain.MaxMessageBoxID || req.Limit \u003C= 0 || req.Limit \u003E\u2026\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_stats.go, internal/store/postgres/channel_stats.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_stats.go"},"region":{"startLine":242}}}],"partialFingerprints":{"codehealthFindingId/v1":"ec8bc310a3c269e3f36071f9c957a52dafdd6811ed75f2e542b76b6667c374c8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ViewerUserID == 0 || req.ChannelID == 0 || req.MessageID \u003C= 0 || req.MessageID \u003E domain.MaxMessageBoxID || req.ReactorUserID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":392}}}],"partialFingerprints":{"codehealthFindingId/v1":"5de03475a82a54801ce87b22531890798b5dea297ac4d2695a5f99605546e72a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060req.ViewerUserID == 0 || req.Owner.ID == 0 || req.StoryID \u003C= 0 || req.StoryID \u003E domain.MaxStoryID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a525142e554251b14ad388611790241b57c08f13dd27459b55d1596e0b1b793"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060request.AppealID \u003C= 0 || (request.Kind != domain.ModerationDecisionAppealGrant \u0026\u0026 request.Kind != domain.ModerationDecisionAppealDeny)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/moderation.go, internal/store/postgres/moderation_cases.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/moderation.go"},"region":{"startLine":507}}}],"partialFingerprints":{"codehealthFindingId/v1":"a1d0d9cac476b3a78aa8f9d0ed6264166546a1e567c83cf4e0284b3c0cd3ed1c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060request.ResponseType == \u0022post_message\u0022 || request.ResponseType == \u0022legacy_url\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":373}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea90f0b904a1e48c7520e861382e9cf0ccb309c3da800a7d37ad68bec2addf5c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060requestID \u003C= 0 || userID \u003C= 0 || now.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":446}}}],"partialFingerprints":{"codehealthFindingId/v1":"42fab6237911b3242d3736d2148504cae1f1ecada503128d66e7c42bd93d744f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060res.Duplicate \u0026\u0026 res.ReplayDeleteEvent != nil\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_updates.go, internal/rpc/messages_monoforum.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_updates.go"},"region":{"startLine":271}}}],"partialFingerprints":{"codehealthFindingId/v1":"393eea9f0121cceafd3192eddb57c087212f688e0d09945c2efa215fd23e45c0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060res.Message.Action == nil || res.Message.Action.Type != domain.ChannelActionTopicCreate\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"0dbea86c023b8920febd1e914adb90669c7665071e038a22fbe2bca7c6c55c16"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060resp.StatusCode \u003C 200 || resp.StatusCode \u003E= 300\u0060 appears character-identically in 7 files \u2014 cmd/telesrv-admin/server.go, cmd/telesrv-admin/star_gift_catalog.go, cmd/walletminiapp/main.go, internal/app/ai/provider_http.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":604}}}],"partialFingerprints":{"codehealthFindingId/v1":"735778e8cd010728b1567d6d3a0d5e954cadd4b51079e5f6cfb949be0bfc4528"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060root.Discussion == nil || root.Discussion.ChannelID == 0 || root.Discussion.MessageID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_topics.go, internal/store/postgres/channel_topics.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":515}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b0a835fea01328ef591ed46df5b01968fd722597333fad3d303111fb5dcf19b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || !s.enabled || s.store == nil\u0060 appears character-identically in 2 files \u2014 internal/app/rating/service.go, internal/app/verification/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/rating/service.go"},"region":{"startLine":198}}}],"partialFingerprints":{"codehealthFindingId/v1":"425c63498e616551c5068be164003bcbde9c8494f277d7c9c6f96de3b111ce7c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.base == nil || len(keys) == 0\u0060 appears character-identically in 2 files \u2014 internal/store/read_model_batch.go, internal/store/read_model_cache.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/read_model_batch.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1c741ba2f31a7ca8d977eb9081df3518e1eed2084aa018095970365de7a6d39"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.bots == nil || botUserID == 0\u0060 appears character-identically in 2 files \u2014 internal/app/bots/miniapp.go, internal/app/bots/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/miniapp.go"},"region":{"startLine":65}}}],"partialFingerprints":{"codehealthFindingId/v1":"704c8f7b45d4fbb4af760379726b77af57f0592b9914afa35fd6997fb9d1ad77"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.channels == nil || channelID == 0\u0060 appears character-identically in 2 files \u2014 internal/app/channels/service.go, internal/app/channels/service_groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":334}}}],"partialFingerprints":{"codehealthFindingId/v1":"65077db584022423506009e7b26b46bebbf8b4f752f57c16744aeb7e08ef5ee3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.channels == nil || userID == 0 || len(channelIDs) == 0\u0060 appears character-identically in 2 files \u2014 internal/app/channels/service.go, internal/app/dialogs/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1868}}}],"partialFingerprints":{"codehealthFindingId/v1":"082d2508c3a876cb76109b24b38efa505808b2694d743c18d1c3955b2b22b059"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.codes == nil || userID == 0\u0060 appears character-identically in 2 files \u2014 internal/app/account/lifecycle.go, internal/app/account/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":329}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f3e533162fcb95db1ed3dc85141126d78bd17702f8d8a54b5c09bfa33fcd5e1"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.db == nil || s.messages == nil || now \u003C= 0 || limit \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/star_gift_channel_notifications.go, internal/store/postgres/star_gift_craft_auction.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_channel_notifications.go"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"acbb3bf0c17872bcdcc40801df0ec4f9c4d189ac8b7cefbf9a20f190f8292585"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.dialogLimiter == nil || s.dialogRateLimit \u003C= 0 || s.dialogRateWindow \u003C= 0\u0060 appears character-identically in 2 files \u2014 internal/app/bots/verifierbot.go, internal/app/bots/verifybot.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":301}}}],"partialFingerprints":{"codehealthFindingId/v1":"a88ef7bad25af7ca48ee8cdff75b3a9e429750f029a3991dcf641758b0c94cc2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.sendGate == nil || userID == 0\u0060 appears character-identically in 2 files \u2014 internal/app/channels/service.go, internal/app/messages/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/service.go"},"region":{"startLine":1493}}}],"partialFingerprints":{"codehealthFindingId/v1":"ddd4cc305a39bc4b4ce077dd01463c83b91966f6c266b9486782ebccfb8bb20e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s == nil || s.users == nil || userID == 0\u0060 appears character-identically in 2 files \u2014 internal/app/auth/service.go, internal/app/contacts/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1487}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa6eae417d8de3c52c3233d430cf837b14734a2af8d1a43908022abebf459272"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s.emailSignupEnabled \u0026\u0026 domain.IsEmailSignupPhone(phone)\u0060 appears character-identically in 2 files \u2014 internal/app/account/phone_change.go, internal/app/auth/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/phone_change.go"},"region":{"startLine":233}}}],"partialFingerprints":{"codehealthFindingId/v1":"17563fa6513e797d0005acedb4e20a3472750c9c31b629092ad16ed84cd994cf"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060s.premium != nil \u0026\u0026 s.premium(ctx, userID)\u0060 appears character-identically in 2 files \u2014 internal/app/ai/service.go, internal/app/dialogs/service.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/service.go"},"region":{"startLine":622}}}],"partialFingerprints":{"codehealthFindingId/v1":"e09009bbee858d0e265110576b9c4b82c88d5f4d77764c9d8a13a7dcc56ada96"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060scope == domain.TelegramLoginScopeBotAccess \u0026\u0026 !approval.WriteAllowed\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":338}}}],"partialFingerprints":{"codehealthFindingId/v1":"61e74f551e206ffef8e36e6b00f3a08438bec08e5af8cb03b4107a355ff3b886"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060scope == domain.TelegramLoginScopePhone \u0026\u0026 !approval.PhoneShared\u0060 appears character-identically in 2 files \u2014 internal/store/memory/telegram_login.go, internal/store/postgres/telegram_login.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/telegram_login.go"},"region":{"startLine":335}}}],"partialFingerprints":{"codehealthFindingId/v1":"0ca7e24aa477e2b8c6881993863516d34e54661f981a47c50886c9695ff714d7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060seenMsgID \u003C msgID \u0026\u0026 record.seqNo \u003E= seqNo\u0060 appears character-identically in 2 files \u2014 internal/mtprotoedge/encrypted.go, internal/mtprotoedge/inbound_preflight.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":1645}}}],"partialFingerprints":{"codehealthFindingId/v1":"8d8b3e6f921f295ed2628bfb74ab1cdf755577c57422518ca12762ecb9b78823"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060seenMsgID \u003E msgID \u0026\u0026 record.seqNo \u003C= seqNo\u0060 appears character-identically in 2 files \u2014 internal/mtprotoedge/encrypted.go, internal/mtprotoedge/inbound_preflight.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":1648}}}],"partialFingerprints":{"codehealthFindingId/v1":"f9911f2f28f308c8cd1c3c287d14b951fdb10de83f0b6f9f8ff3e0ffb063a6b6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060self.Event.Pts == 0 || self.Message.ID == 0\u0060 appears character-identically in 3 files \u2014 internal/rpc/messages_edit.go, internal/rpc/messages_edit_geolive.go, internal/rpc/messages_todos.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_edit.go"},"region":{"startLine":178}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a8247042fa4c3f5e3e8fa2a2c31bece6537749cd9808312bcead64102b4c3d8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060set.Kind == domain.StickerSetKindEmoji || set.Emojis\u0060 appears character-identically in 3 files \u2014 internal/app/bots/stickersbot.go, internal/app/files/sticker_creator.go, internal/rpc/messages_sticker_sets.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":633}}}],"partialFingerprints":{"codehealthFindingId/v1":"9c3d08a99097d608202952030373d2786770e4173de3e6f2bc03b682162dfd5c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060set.Kind == domain.StickerSetKindMasks || set.Masks\u0060 appears character-identically in 3 files \u2014 internal/app/bots/stickersbot.go, internal/app/files/sticker_creator.go, internal/rpc/messages_sticker_sets.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":631}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f15f81b824fcef2a5f4ec65d13d221687423eb013c85f2c2875343b327cfa7d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060settings.Version \u003C 0 || !botVerifierSettingsColumnsFit(settings)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":251}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b33cc1ab1694350be1b11c291f23a4ec01234a4c20366496df57695009bddc6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060settings.Version == 0 || settings.Version != current.Version\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":270}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebc3d2b6975cdbdb96175407d763c9d57ee743ade512bd6b794780aad9367022"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060slot.Peer.Type == domain.PeerTypeChannel \u0026\u0026 slot.Peer.ID != 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_boosts.go, internal/store/postgres/channel_boosts.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"33b52786ccbe52b155ee0f13574bd67ac97214b5e8e402e17ac39ae65d27805e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060stars \u003C 0 || stars \u003E maxChannelPaidMessageStars\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_settings.go, internal/rpc/stories.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_settings.go"},"region":{"startLine":351}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ce1828bbda4dab5c3a9a97b369b1892822207a087dddf07878560e7f936c165"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060state.UserID == 0 || state.BotUserID == 0 || state.UserID == state.BotUserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot.go, internal/store/postgres/bot_miniapp.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot.go"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"01817ff45a34b697adde72a3ae79c58c8f8832af95d7405e4dca6160a953e294"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060status == domain.CustomVerificationApproved || status == domain.CustomVerificationRevoked\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":955}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c4eff3a196279db245cea28975eea09b73f61e6dc640ed0dd12c3b81a4edeb6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060story.Owner.Type == domain.PeerTypeUser \u0026\u0026 story.Owner.ID == viewerUserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/story.go, internal/store/postgres/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/story.go"},"region":{"startLine":1185}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0dba1b5d59193abaf9b8120b7ba413eb22adda6ccd2fce5e83596a166d469c4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060strings.HasPrefix(addr, \u0022http://\u0022) || strings.HasPrefix(addr, \u0022https://\u0022)\u0060 appears character-identically in 2 files \u2014 cmd/telesrv-admin/main.go, internal/procctl/adminurl.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/main.go"},"region":{"startLine":247}}}],"partialFingerprints":{"codehealthFindingId/v1":"a45398c1df74d6de99b6ba8ad49f6550af00ba15486edd40f83915ab8b4dba11"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060strings.TrimSpace(phoneCodeHash) == \u0022\u0022 || strings.TrimSpace(code) == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/app/account/lifecycle.go, internal/app/account/phone_change.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/account/lifecycle.go"},"region":{"startLine":255}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8ff88108bfb74a0f7f3bf2219cffe2561ecad2ccc7b07ff7ed94254ce742d25"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060strings.TrimSpace(req.Message) == \u0022\u0022 \u0026\u0026 finalMedia.IsZero() \u0026\u0026 finalRich.IsZero()\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":36}}}],"partialFingerprints":{"codehealthFindingId/v1":"19231950de1724f0951f491158c3e3f2f4deb7193f71142f4aaa463b6cac639f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060target.Broadcast || !target.Megagroup || target.LinkedChatID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":1053}}}],"partialFingerprints":{"codehealthFindingId/v1":"c18f8934accda1585176a6d05676f1df0caaf2bdc39060793887d658611556a0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060target.ReplyTo != nil \u0026\u0026 target.ReplyTo.TopMessageID \u003E 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":565}}}],"partialFingerprints":{"codehealthFindingId/v1":"45a4c73e1e69beac9ee715522cb3caa6045c51f5b623012974d6a8724d397a97"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060target.Role == domain.ChannelRoleAdmin \u0026\u0026 target.InviterUserID != actor.UserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":688}}}],"partialFingerprints":{"codehealthFindingId/v1":"44e3930db1b3eaf2b74e1aea91bc6eaf605e1eeaa2ea4afd722ebd4ee4632e3e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060task.req.SenderUserID != task.req.RecipientUserID \u0026\u0026 !task.req.RecipientBlocked\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/message_send_batch_actor.go, internal/store/postgres/message_send_batch_sql.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/message_send_batch_actor.go"},"region":{"startLine":307}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cabefa8bc0be08aa08516f1c35d863515f0ee1ea09b1edba177b9a5f3fdb39b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060title == \u0022\u0022 || len([]rune(title)) \u003E domain.MaxStarGiftCollectionTitleRunes\u0060 appears character-identically in 2 files \u2014 internal/store/memory/star_gift.go, internal/store/postgres/star_gift_collectibles.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/star_gift.go"},"region":{"startLine":673}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd9ee677a8bad1b5435e9261c3a29420a3cdc4a66dacd8d2939dbd857f826c20"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060title == \u0022\u0022 || utf8.RuneCountInString(title) \u003E domain.MaxStickerSetTitleLen\u0060 appears character-identically in 2 files \u2014 internal/app/bots/stickersbot.go, internal/app/files/sticker_creator.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c80ddeadfe0817574721bcaa3886225d0f3d079b3d9eb2187df90ff13012ee6"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060tone.ID == 0 || tone.AccessHash == 0 || tone.OwnerUserID == 0 || tone.Slug == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/ai.go, internal/store/postgres/ai.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/ai.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"e54d02d5fe39615bcf84507173bc111e39383c8875c01dc67dd71ff449bbd21c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060topMessageID \u003E 0 \u0026\u0026 topMessageID == member.HistoryClearAnchorID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":502}}}],"partialFingerprints":{"codehealthFindingId/v1":"cc5e5378cf41a3c41d78a3084eb657e62c8d8f90eee248da2ecf1c2f3ab99b7c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060topMsgID \u003C 0 || topMsgID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/rpc/messages_polls.go, internal/rpc/messages_reactions_lists.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":265}}}],"partialFingerprints":{"codehealthFindingId/v1":"72d58f5366e213540cf8570c9629e19c5e1ccd0a6d5dce8c919a6856695646ac"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060topMsgID \u003C= 0 || topMsgID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/rpc/channels_stubs.go, internal/rpc/media_count.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_stubs.go"},"region":{"startLine":150}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe0e499a40b4a01c839eb64f7c09b82a41904f2a95d5a95dcf7c7f500f6c1f5e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060topic.Closed \u0026\u0026 !canManageForumTopic(channel, member, topic, req.UserID, selfBoostsApplied)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":547}}}],"partialFingerprints":{"codehealthFindingId/v1":"488100d84fc9d9c8d45750b2c1b8815c66853cf46bcdb6bf79b8571411d5cbae"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060total \u003C= blobBytesCacheMaxEntryBytes \u0026\u0026 int64(len(data)) == total\u0060 appears character-identically in 2 files \u2014 internal/app/files/service.go, internal/app/files/warm.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/service.go"},"region":{"startLine":560}}}],"partialFingerprints":{"codehealthFindingId/v1":"cb04dc04cbed3ffa78ed8a24c310422431458ce75482fdb621d23c35575b2574"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060u.MutedByAdmin != nil \u0026\u0026 p.MutedByAdmin != *u.MutedByAdmin\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":586}}}],"partialFingerprints":{"codehealthFindingId/v1":"ab36cfd9a55a5adf989ab02bfa2650105eb54592e9977d6eeb6110a880ab3076"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060u.PresentationJSON != nil \u0026\u0026 string(p.PresentationJSON) != string(*u.PresentationJSON)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":602}}}],"partialFingerprints":{"codehealthFindingId/v1":"9958b6d2ec2d6c6fc01aae0683a518e2c92d30fa3463cbe85ea192ef854b7ab3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060u.RaiseHandRating != nil \u0026\u0026 p.RaiseHandRating != *u.RaiseHandRating\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":594}}}],"partialFingerprints":{"codehealthFindingId/v1":"5142a7d15957806c61b1fc0ca2c1ab0dcbbf917c3a45df391e70f04569e7418e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060u.VideoJSON != nil \u0026\u0026 string(p.VideoJSON) != string(*u.VideoJSON)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":598}}}],"partialFingerprints":{"codehealthFindingId/v1":"edb1f9125953e8f7caf7a8b6c0538341fc618d36d2163119b59fc9b83de405b3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060u.VolumeByAdmin != nil \u0026\u0026 p.VolumeByAdmin != *u.VolumeByAdmin\u0060 appears character-identically in 2 files \u2014 internal/store/memory/groupcall.go, internal/store/postgres/groupcall.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/groupcall.go"},"region":{"startLine":590}}}],"partialFingerprints":{"codehealthFindingId/v1":"d68c20d7aebe01f62c974e4f8acce6f6507f51f0c57b8fbf2f6e8859a0ebddad"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060unreadEligible \u0026\u0026 msg.SenderUserID != 0 \u0026\u0026 msg.SenderUserID != req.UserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_reactions.go, internal/store/postgres/channel_reaction_messages.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_reactions.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c397692480452933dc10c096a18c70304dbe9de5910d1fbff8f74b2e93cd204"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060update.UserID == 0 || update.LastSeenAt \u003C= 0\u0060 appears character-identically in 4 files \u2014 internal/app/users/service.go, internal/rpc/presence_last_seen_batch.go, internal/store/memory/users.go, internal/store/postgres/user.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/users/service.go"},"region":{"startLine":453}}}],"partialFingerprints":{"codehealthFindingId/v1":"d490bfa158a045152cc1f972e02cacc34a46b04ad90ad684a4845fe3b409510a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || blockedUserID == 0 || userID == blockedUserID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/contacts.go, internal/store/postgres/contact.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/contacts.go"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"98b5b62fc8034589d63569a62293ee3f55aceb3f43bdeaeaf452a6377764193f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || channelID \u003C 0 || strings.TrimSpace(username) == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"a3e580344afa93f331a833eeed08c46f8deff0c7a9446006135ea1b2cb857ab8"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || channelID == 0 || !domain.ValidChannelSlowModeSeconds(seconds)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":529}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f5a134697cb0ee4eab7fe7166746bef590422df98d97ae6a4492056837189d7"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || channelID == 0 || boosts \u003C 0 || boosts \u003E domain.MaxChannelBoostsToUnblockRestrictions\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_settings.go, internal/store/postgres/channel_boosts.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_settings.go"},"region":{"startLine":559}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2694edc626ca78c37a1f994d735adb856ad207c46b3540c008f1444d74e6ed0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || channelID == 0 || messageID \u003C= 0 || messageID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_polls.go, internal/store/postgres/channel_polls.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_polls.go"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"7a16a0cdef2deb2d10afc470b2681b8c91e2b06159ed954f2b9e3c1412c0b1f2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || channelID == 0 || stars \u003C 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_settings.go, internal/store/postgres/channel_message_settings.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_settings.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"80d52f0f587325b150b80f8fd28ed3174eaa1647fa54895a35e610f3b048b36c"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || offset \u003C 0 || offset \u003E domain.MaxLeftChannelsOffset\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":205}}}],"partialFingerprints":{"codehealthFindingId/v1":"e868dc15b2c2cbb5acb0ce788ded4fdd95410f658f922f653d6968e9699bf7c0"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || peer.Type != domain.PeerTypeChannel || peer.ID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/postgres/channel_boost_cache.go, internal/store/postgres/channel_boosts.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_boost_cache.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"4be2e6239ee2de33ec4ceed4264ebca59ecad5ef8cd8183a90a663a536763dd4"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || peer.Type != domain.PeerTypeUser || peer.ID == 0 || messageID \u003C= 0 || messageID \u003E domain.MaxMessageBoxID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/message_polls.go, internal/store/postgres/message_polls.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/message_polls.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"931d0d9ccb60b669d139daee5d59a2cebe0234f13aa965022659e67ec36d0a4b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || peer.Type == \u0022\u0022 || peer.ID == 0\u0060 appears character-identically in 3 files \u2014 internal/store/memory/dialogs.go, internal/store/memory/saved_dialog.go, internal/store/postgres/dialog.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/dialogs.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"c31f2ead998d29ada5dafc65c4794b8c8546ee2bfcfa894f0958fd8a2c40b79f"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || sinceDate \u003C= 0 || afterChannelID \u003C 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_helpers.go, internal/store/postgres/channel_helpers.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_helpers.go"},"region":{"startLine":321}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ae7fbe3893d5ab1a979a1b5f2ad470fc3c23a84134620b784e024c9caef7612"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060userID == 0 || strings.TrimSpace(hash) == \u0022\u0022\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_invites.go, internal/store/postgres/channel_invite_import.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_invites.go"},"region":{"startLine":256}}}],"partialFingerprints":{"codehealthFindingId/v1":"1adfe6d16fda41066b7de634454de3b2aded38c3c3e30304ef14cd0acd6d2b0e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060verifierBotID \u003C= 0 || !validBotVerificationPeer(peer)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/bot_verification.go, internal/store/postgres/bot_verification.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/bot_verification.go"},"region":{"startLine":419}}}],"partialFingerprints":{"codehealthFindingId/v1":"4b3ad471da50ce56a83cdf6ecc00b2e6695bd5d1c73f825413835ab781247d07"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060viaBotEditRequested \u0026\u0026 msg.ViaBotID == req.ViaBotEditBotID\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_edit.go, internal/store/postgres/channel_message_edit.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_edit.go"},"region":{"startLine":73}}}],"partialFingerprints":{"codehealthFindingId/v1":"41871d5aab5300c80fb457062314fc3f043094e71ab76e890379e0140d0fe56a"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060view.Channel.Broadcast \u0026\u0026 !view.Channel.Megagroup\u0060 appears character-identically in 2 files \u2014 internal/rpc/convert_markup.go, internal/rpc/messages_polls.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_markup.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2d2d24958f6300090de06bec05dcce1eb231e26a4fdd221ee994d95d985a760"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060view.Repost != nil || view.PublicForward != nil\u0060 appears character-identically in 3 files \u2014 internal/rpc/stories.go, internal/store/memory/story.go, internal/store/postgres/story.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3378}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c246eaba85783bfeb08f16dc4d073dd2e089b29e735f340d4c9e793748ac571"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060view.Self.Role != domain.ChannelRoleCreator \u0026\u0026 view.Self.Role != domain.ChannelRoleAdmin\u0060 appears character-identically in 3 files \u2014 internal/app/ephemeral/service.go, internal/rpc/channels_stubs.go, internal/rpc/stats.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ephemeral/service.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a2118a9b8ab6ee5817f235ed3c0b7f9c79875317fc4371f05bd3b78b9110ffe"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060view.Self.Status != domain.ChannelMemberActive || !channelMemberIsAdmin(view.Self)\u0060 appears character-identically in 2 files \u2014 internal/rpc/phone_group_call.go, internal/rpc/phone_group_call_rtmp.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":211}}}],"partialFingerprints":{"codehealthFindingId/v1":"5511d6e1e2f2a27a0cc2394f8914ed1bbaea80286dc36f26511db2e137f3e93d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060viewerUserID != 0 \u0026\u0026 u.ID == viewerUserID\u0060 appears character-identically in 2 files \u2014 internal/rpc/convert_dialogs.go, internal/rpc/convert_users.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_dialogs.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2b8501dba4bf1449f9303c2901765571894df9c7e660a7013b82367a00d5d2b"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060viewerUserID == 0 || (query == \u0022\u0022 \u0026\u0026 !req.MusicOnly)\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_message_history.go, internal/store/postgres/channel_message_history.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_message_history.go"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"42f0cf14d403d9dabacc642f7f6d0ccfa8f8e51ed6898b9d412a6a0737ed7453"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060viewerUserID == 0 || channelID == 0 || targetUserID == 0\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_boosts.go, internal/store/postgres/channel_boosts.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_boosts.go"},"region":{"startLine":109}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bf4643cbb4196fefe1284c33b84b14b2dd04660fee86592af391ca7d7d566ab"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060viewerUserID == 0 || len(channelIDs) == 0\u0060 appears character-identically in 4 files \u2014 internal/store/memory/channel_core.go, internal/store/memory/channel_dialogs.go, internal/store/postgres/channel_core.go, internal/store/postgres/channel_dialogs.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_core.go"},"region":{"startLine":207}}}],"partialFingerprints":{"codehealthFindingId/v1":"3b96a9de665ebb09979c928b35f6616d4207991f30e4b2301c9d3a02c3dcbea2"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060viewerUserID == participantUserID \u0026\u0026 viewer.Guest\u0060 appears character-identically in 2 files \u2014 internal/store/memory/channel_members.go, internal/store/postgres/channel_member_list.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_members.go"},"region":{"startLine":85}}}],"partialFingerprints":{"codehealthFindingId/v1":"55c4920fb4c5abb91c4030f2847fdae0d9fffd7dd8b0ed5bcc04eb6ccf239d08"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060writeTimeout \u003C= 0 || writeTimeout \u003E 5*time.Second\u0060 appears character-identically in 2 files \u2014 internal/mtprotoedge/encrypted.go, internal/mtprotoedge/layer_rpc_execution.go. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/encrypted.go"},"region":{"startLine":675}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f4f980caaf701b6590a6bdc957cddc2a7321ab2f746e81b09ee91857de3c50d"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060!cancelled \u0026\u0026 !onError(err) \u0026\u0026 setError(errorMessage(err))\u0060 appears character-identically in 2 files \u2014 cmd/telesrv-admin/web/src/components/chat/AccountChats.tsx, cmd/telesrv-admin/web/src/components/chat/ProfileGalleries.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/chat/AccountChats.tsx"},"region":{"startLine":45}}}],"partialFingerprints":{"codehealthFindingId/v1":"24a0b0241a07df33d70261f0d8b0818ee6a17fbef280125a0867dd5588352b84"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060err instanceof APIError \u0026\u0026 err.status === 409\u0060 appears character-identically in 2 files \u2014 cmd/telesrv-admin/web/src/pages/BotVerificationRequestPage.tsx, cmd/telesrv-admin/web/src/pages/VerificationDetailPage.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/BotVerificationRequestPage.tsx"},"region":{"startLine":55}}}],"partialFingerprints":{"codehealthFindingId/v1":"f999810dbd03a9519b37a08fff650fa0400222765cc98977bf238b52029a810e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060m.includes(\u0022tgsticker\u0022) || m.includes(\u0022lottie\u0022) || m.includes(\u0022json\u0022)\u0060 appears character-identically in 2 files \u2014 cmd/telesrv-admin/web/src/components/EmojiPicker.tsx, cmd/telesrv-admin/web/src/pages/EmojiPage.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/EmojiPicker.tsx"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"6123c546206667494c7e1fb2deb998d3838626f7a7d7db9199b27244a9e01209"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060row.FirstName || displayUsername(row.Username) || \u0022\u2014\u0022\u0060 appears character-identically in 3 files \u2014 cmd/telesrv-admin/web/src/pages/AccountRatingsPage.tsx, cmd/telesrv-admin/web/src/pages/BotsPage.tsx, cmd/telesrv-admin/web/src/pages/StoragePage.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/pages/AccountRatingsPage.tsx"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"a5db49dca3f4da8f9c5c5b078e18eb55941365b8dc730da2e56d27524ceb2135"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060username.trim().length \u003C 3 || password.trim() === \u0022\u0022\u0060 appears character-identically in 2 files \u2014 cmd/telesrv-admin/web/src/components/SetupWizard.tsx, cmd/telesrv-admin/web/src/pages/AdminUsersPage.tsx. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/components/SetupWizard.tsx"},"region":{"startLine":424}}}],"partialFingerprints":{"codehealthFindingId/v1":"0cf0c1defb249f7ade6aa4a260579401d251445cd297745e7affa4ae9ce6dae3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060args.send_chat_id is not None and args.send_text\u0060 appears character-identically in 2 files \u2014 cmd/bots/aiogramecho/echo.py, cmd/bots/ptbecho/echo.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":248}}}],"partialFingerprints":{"codehealthFindingId/v1":"3343c2f439c76f70e905c8c351db3260f74495f07871a74eb80ebcfcf54b68fe"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060args.send_only and not args.send_text and args.buttons_chat_id is None\u0060 appears character-identically in 2 files \u2014 cmd/bots/aiogramecho/echo.py, cmd/bots/ptbecho/echo.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":84}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7511dd03f329000fa3df7fa4494c7e64a4e7cbc2a1fe16e3ab407d3b516b8d3"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060args.send_text and args.send_chat_id is None\u0060 appears character-identically in 2 files \u2014 cmd/bots/aiogramecho/echo.py, cmd/bots/ptbecho/echo.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"926361c7f0c9c97f5823ab25d8653c58f456ea6d8eb067566bd15c1deb6b8d8e"}},{"ruleId":"X10","level":"note","message":{"text":"Duplicated predicate: \u0060isinstance(raw, int) and not isinstance(raw, bool) and raw \u003E 0\u0060 appears character-identically in 2 files \u2014 cmd/bots/aiogramecho/echo.py, cmd/bots/ptbecho/echo.py. It is one line, so the duplication detector\u0027s token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/aiogramecho/echo.py"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce214e341657476b87e4a39ac8f5691cffbd4fc2d0870ca6a7d847c98216fd7c"}},{"ruleId":"X14","level":"warning","message":{"text":"IP classification is bypassable through an IPv4-in-IPv6 embedding: This function unwraps IPv4-MAPPED IPv6 (\u0060To4\u0060, line 508) and then rejects \u0060192.168.0.0/16\u0060 on its IPv4 path \u2014 but the IPv6 decision at line 530 classifies the address as written, and IPv4 reaches IPv6 through three MORE embeddings this function never mentions: IPv4-compatible (\u0060::a.b.c.d\u0060), 6to4 (\u00602002::/16\u0060) and NAT64 (\u006064:ff9b::/96\u0060). So \u0060::192.168.0.1\u0060, \u00602002:c0a8:0001::\u0060 and \u006064:ff9b::192.168.0.0\u0060 all name a host inside \u0060192.168.0.0/16\u0060 \u2014 the range this same function declares non-public \u2014 and all reach the IPv6 decision un-unwrapped, taking the opposite verdict. Unwrap every embedding to its IPv4 form before classifying, or reject any IPv6 address carrying an embedded IPv4 outright."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/verification.go"},"region":{"startLine":530}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfa676642734bd0d75beb32eb6dbfb55608ab2557fc4e35b489b37ce6b715af3"}},{"ruleId":"X2","level":"note","message":{"text":"Not all functions that make a request accept a context.Context: Only 35/38 functions that make a cancellable request (net/http, net.Dial) accept a context.Context or pass one on, so a request keeps running after whatever wanted it has given up \u2014 a cancelled request, a shutdown, an expired deadline. Take \u0060ctx context.Context\u0060 as the first parameter and build the request with it (\u0060http.NewRequestWithContext\u0060, \u0060DialContext\u0060); where nothing could ever cancel the call, omitting it is a deliberate choice \u2014 judge against how the function is used."},"locations":[],"partialFingerprints":{"codehealthFindingId/v1":"faab330444baf00d50193f250b5c9b514f84cdca16c24014ef3776329847910c"}},{"ruleId":"X2","level":"warning","message":{"text":"Function without context.Context: listening: \u0060listening\u0060 calls \u0060net.DialTimeout(\u2026)\u0060 but takes no context.Context and reaches none its caller controls, so its caller cannot cancel the request once it has started. Take \u0060ctx context.Context\u0060 as the first parameter and build the request with it: \u0060http.NewRequestWithContext(ctx, \u2026)\u0060, \u0060(\u0026net.Dialer{}).DialContext(ctx, \u2026)\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":221}}}],"partialFingerprints":{"codehealthFindingId/v1":"a299210998f6d592b02777d9c331ce5d6928de8ff5ad8e475de7b9e82faf68cc"}},{"ruleId":"X2","level":"warning","message":{"text":"Function without context.Context: fetch: \u0060fetch\u0060 calls \u0060http.NewRequestWithContext(\u2026)\u0060 but takes no context.Context and reaches none its caller controls, so its caller cannot cancel the request once it has started. Take \u0060ctx context.Context\u0060 as the first parameter and build the request with it: \u0060http.NewRequestWithContext(ctx, \u2026)\u0060, \u0060(\u0026net.Dialer{}).DialContext(ctx, \u2026)\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/maptile_proxy.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"8ad929ef5b7ef816e54b0503d608ef8680cec94c169acbb4442b63e7904a6c5f"}},{"ruleId":"X2","level":"warning","message":{"text":"Function without context.Context: serverListening: \u0060serverListening\u0060 calls \u0060net.DialTimeout(\u2026)\u0060 but takes no context.Context and reaches none its caller controls, so its caller cannot cancel the request once it has started. Take \u0060ctx context.Context\u0060 as the first parameter and build the request with it: \u0060http.NewRequestWithContext(ctx, \u2026)\u0060, \u0060(\u0026net.Dialer{}).DialContext(ctx, \u2026)\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/serverstorage.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f74f0c308f6a30442442765568d2db6ecfe0889dcadc0fa6af2962f5b156980"}},{"ruleId":"X26","level":"warning","message":{"text":"Collection crosses a callback boundary unsynchronised: \u0060projectBatch\u0060 starts two goroutines that both write \u0060profileRefs\u0060, a map \u2014 \u0060profileRefs = \u2026\u0060 on line 392, and again on line 409 \u2014 and waits on \u0060g\u0060 only after both have started, so the two run at the same time with nothing ordering one write against the other. A Go map is not safe for concurrent use: a write concurrent with any other access is a data race, and the runtime aborts the whole process with \u0060fatal error: concurrent map writes\u0060 when it catches one. \u0060g\u0060 is an \u0060errgroup.Group\u0060, which orders the handoff\u0027s signal and takes no exclusion over the map\u0027s own state. Guard every write to \u0060profileRefs\u0060 with one \u0060sync.Mutex\u0060, or have each goroutine send its result on a channel that this body alone receives from and writes into \u0060profileRefs\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/userprojection/projection.go"},"region":{"startLine":392}}}],"partialFingerprints":{"codehealthFindingId/v1":"79ba128368ebc26382f5ff91832b4ee2a51cf0e7764cecf66f95cc8712df25aa"}},{"ruleId":"X26","level":"warning","message":{"text":"Collection crosses a callback boundary unsynchronised: \u0060DashboardActivity\u0060 starts two goroutines that both write \u0060err\u0060, a variable \u2014 \u0060err = \u2026\u0060 on line 68, and again on line 79 \u2014 and waits on \u0060g\u0060 only after both have started, so the two run at the same time with nothing ordering one write against the other. A goroutine\u0027s closure captures \u0060err\u0060 by reference, so every goroutine and the body use ONE variable, and a plain variable has no synchronisation of its own: by the Go memory model a write concurrent with any other access to it is a data race (the race detector reports it), a racing \u0060\u002B\u002B\u0060 loses updates, and a racing read sees a stale or torn value. \u0060g\u0060 is an \u0060errgroup.Group\u0060, which orders the handoff\u0027s signal and takes no exclusion over the variable\u0027s own state. Guard every write to \u0060err\u0060 with one \u0060sync.Mutex\u0060, or have each goroutine send its result on a channel that this body alone receives from and writes into \u0060err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/activity.go"},"region":{"startLine":68}}}],"partialFingerprints":{"codehealthFindingId/v1":"e236401d7e2462366aa837f086af428d350718330b7c9e88f355d846c2858863"}},{"ruleId":"X26","level":"warning","message":{"text":"Collection crosses a callback boundary unsynchronised: \u0060DashboardActivity\u0060 starts two goroutines that both write \u0060err\u0060, a variable \u2014 \u0060err = \u2026\u0060 on line 79, and again on line 90 \u2014 and waits on \u0060g\u0060 only after both have started, so the two run at the same time with nothing ordering one write against the other. A goroutine\u0027s closure captures \u0060err\u0060 by reference, so every goroutine and the body use ONE variable, and a plain variable has no synchronisation of its own: by the Go memory model a write concurrent with any other access to it is a data race (the race detector reports it), a racing \u0060\u002B\u002B\u0060 loses updates, and a racing read sees a stale or torn value. \u0060g\u0060 is an \u0060errgroup.Group\u0060, which orders the handoff\u0027s signal and takes no exclusion over the variable\u0027s own state. Guard every write to \u0060err\u0060 with one \u0060sync.Mutex\u0060, or have each goroutine send its result on a channel that this body alone receives from and writes into \u0060err\u0060."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/activity.go"},"region":{"startLine":79}}}],"partialFingerprints":{"codehealthFindingId/v1":"05d815b1b43d6d49e125efb2b553a1a8ac460d49be7bbcab9689a1baa05c9520"}},{"ruleId":"X28","level":"warning","message":{"text":"Index access outside its own emptiness guard: \u0060parts\u0060 holds what \u0060Split\u0060 returns, and \u0060parts[2]\u0060 takes element 2 of it without checking its length \u2014 while this file tests that same result elsewhere before indexing it, because it can be nil or shorter. Here a short result panics with \u0060index out of range\u0060. Test \u0060len(parts)\u0060 (or nil) first, as the other call site does."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":269}}}],"partialFingerprints":{"codehealthFindingId/v1":"cca52c3feca343882abc73a02ba77deb78d328d73248a7f3d8b51fe976895172"}},{"ruleId":"X28","level":"warning","message":{"text":"Index access outside its own emptiness guard: \u0060parts\u0060 holds what \u0060Split\u0060 returns, and \u0060parts[3]\u0060 takes element 3 of it without checking its length \u2014 while this file tests that same result elsewhere before indexing it, because it can be nil or shorter. Here a short result panics with \u0060index out of range\u0060. Test \u0060len(parts)\u0060 (or nil) first, as the other call site does."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":273}}}],"partialFingerprints":{"codehealthFindingId/v1":"02e21fd7c7d62d252be582ea24561ab2b5227edd0bf301d8e3e1c2318e8a1dd3"}},{"ruleId":"X28","level":"warning","message":{"text":"Index access outside its own emptiness guard: \u0060i%len(groupMembers)\u0060 divides by the length of \u0060groupMembers\u0060, and nothing before it checks that \u0060groupMembers\u0060 is non-empty. An empty \u0060groupMembers\u0060 makes this an integer division by zero, which panics. Test \u0060len(groupMembers) == 0\u0060 first and return early."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/dataset.go"},"region":{"startLine":127}}}],"partialFingerprints":{"codehealthFindingId/v1":"5831358102e38f6a1f60464106f12ac7f17324be88f598e3afd9b611fcfd67ab"}},{"ruleId":"X28","level":"warning","message":{"text":"Index access outside its own emptiness guard: \u0060message%len(group.MemberAccounts)\u0060 divides by the length of \u0060group.MemberAccounts\u0060, and nothing before it checks that \u0060group.MemberAccounts\u0060 is non-empty. An empty \u0060group.MemberAccounts\u0060 makes this an integer division by zero, which panics. Test \u0060len(group.MemberAccounts) == 0\u0060 first and return early."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/mutate.go"},"region":{"startLine":289}}}],"partialFingerprints":{"codehealthFindingId/v1":"7db74254f2ed5fcc239edc7b2d79c65e6888c35c64dddcb50e188dd86c67bb03"}},{"ruleId":"X28","level":"warning","message":{"text":"Index access outside its own emptiness guard: \u0060%len(targets)\u0060 divides by the length of \u0060targets\u0060, and nothing before it checks that \u0060targets\u0060 is non-empty. An empty \u0060targets\u0060 makes this an integer division by zero, which panics. Test \u0060len(targets) == 0\u0060 first and return early."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":796}}}],"partialFingerprints":{"codehealthFindingId/v1":"f641b3afd2e27e5c26266fb930d4ccabe7bebe25ca44051db5e24011bb82a186"}},{"ruleId":"X28","level":"warning","message":{"text":"Index access outside its own emptiness guard: \u0060idx\u0060 is the result of a search that answers -1 when nothing is found, and \u0060rendered[:idx]\u0060 uses it as a bound with no test of \u0060idx\u0060 in between. When the search misses, the bound is -1 and the access panics with \u0060slice bounds out of range\u0060. Test \u0060idx \u003C 0\u0060 (or use \u0060strings.Cut\u0060) before using it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/login_code_delivery.go"},"region":{"startLine":144}}}],"partialFingerprints":{"codehealthFindingId/v1":"a361b686c1fa8f48f54ee919cc2814c7f488b6423c00c1501654650cea1572ad"}},{"ruleId":"X28","level":"warning","message":{"text":"Index access outside its own emptiness guard: \u0060idx\u0060 is the result of a search that answers -1 when nothing is found, and \u0060rendered[:idx]\u0060 uses it as a bound with no test of \u0060idx\u0060 in between. When the search misses, the bound is -1 and the access panics with \u0060slice bounds out of range\u0060. Test \u0060idx \u003C 0\u0060 (or use \u0060strings.Cut\u0060) before using it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/login_code_delivery.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"25900467d9245eb467319ee65ad3dc0a6efbbb8ae3a42e1d0862ce16aaecca95"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/webclient/webclient.go"},"region":{"startLine":208}}}],"partialFingerprints":{"codehealthFindingId/v1":"d897f770078b8f5cdb1ec10aad49b96c48c3053da440f33841a4a47e30bf39cd"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060zw, _ := gzip.NewWriterLevel(\u0026buf, gzip.DefaultCompression)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060zw\u0060 as if the call succeeded. When \u0060gzip.NewWriterLevel\u0060 fails, \u0060zw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060zw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/webclient/webclient.go"},"region":{"startLine":229}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0837c1452fd2850e0e3bf7bd0112fe963a18b659435d3bbd644a331004ba5de"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060out, _ := json.Marshal(clientData{Type: typ, Challenge: b64.EncodeToString(challenge), Origin: origin})\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060out\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060out\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060out\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/webauthn/webauthntest/authenticator.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a8c8346ecea6bed57acd4e7fba7b155647225a7d7cda599b2f2285ae356593d"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060out, _ := cbor.Marshal(key)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060out\u0060 as if the call succeeded. When \u0060cbor.Marshal\u0060 fails, \u0060out\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060out\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/webauthn/webauthntest/authenticator.go"},"region":{"startLine":82}}}],"partialFingerprints":{"codehealthFindingId/v1":"bd6d4dd6223c3315979d44ecc5b07084e83250563871354d77dcee67e0028929"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/updatecdn/catalog.go"},"region":{"startLine":422}}}],"partialFingerprints":{"codehealthFindingId/v1":"1c8e6269aa27c71a5100cf018e6e26f07c545641ef95037ec660ee2963436bc3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := json.NewEncoder(w).Encode(catalog.DesktopMap()); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/updatecdn/server.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfa1d5ea9715b8a6ee947fba799d491027aa458eaf89211ed22bee5b338c833c"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060_, found, _ := st.GetParticipantOverride(ctx, call.ID, 101, 102)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060found\u0060 as if the call succeeded. When \u0060st.GetParticipantOverride\u0060 fails, \u0060found\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060found\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/storetest/groupcall.go"},"region":{"startLine":579}}}],"partialFingerprints":{"codehealthFindingId/v1":"e249da184837b2a13c6d83c3c8129aeabadd4b904a8474194733aba2acfca88d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := json.Unmarshal([]byte(raw), \u0026out); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_core.go"},"region":{"startLine":700}}}],"partialFingerprints":{"codehealthFindingId/v1":"ffff46dda92076a1a1d7718a6c7dedfda7c90eedd5dab227e4b506a604579f93"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, 0, channelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_groupcall.go"},"region":{"startLine":69}}}],"partialFingerprints":{"codehealthFindingId/v1":"bff20c4c09934c4a809a676b59f1d0468fe06555878177d735a6d9256ac496d4"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_helpers.go"},"region":{"startLine":97}}}],"partialFingerprints":{"codehealthFindingId/v1":"93f94d21f4814a82e6c386782bce9c2110bbd3d045a074e4bcddd86e9adf8852"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, userID, channelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_history_ttl.go"},"region":{"startLine":29}}}],"partialFingerprints":{"codehealthFindingId/v1":"ccf410f5ddb015ef076aeec9143b9b9487861c53e5109e71acd17db0c72f3ded"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, result.Channel.ID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_import.go"},"region":{"startLine":106}}}],"partialFingerprints":{"codehealthFindingId/v1":"467b23de05ef005f0a421418093cb49387f585818038d00abb8a4d0752c99d27"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_invite_requests.go"},"region":{"startLine":171}}}],"partialFingerprints":{"codehealthFindingId/v1":"25e9dcc3db44f3bc6f55ce48f613ca29873fb50e13599dc6785ed173a4cda6a5"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060msg, _ := s.getChannelMessage(ctx, tx, req.ChannelID, channel.TopMessageID)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060msg\u0060 as if the call succeeded. When \u0060s.getChannelMessage\u0060 fails, \u0060msg\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060msg\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"e8361257d6e6ca905b23c0afc498c6358fda5de2482ef5d44c3d64837b2d264f"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060msg, _ := s.getChannelMessage(ctx, tx, req.ChannelID, channel.TopMessageID)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060msg\u0060 as if the call succeeded. When \u0060s.getChannelMessage\u0060 fails, \u0060msg\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060msg\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":262}}}],"partialFingerprints":{"codehealthFindingId/v1":"2ba6f13f00484f679555d9ad347043866374af428d6e4355a3a735e5aa1eda45"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060msg, _ := s.getChannelMessage(ctx, tx, req.ChannelID, channel.TopMessageID)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060msg\u0060 as if the call succeeded. When \u0060s.getChannelMessage\u0060 fails, \u0060msg\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060msg\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_admin.go"},"region":{"startLine":458}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7b6ad5610c7aae8f6dd13e830c520b0aab11dc4b89ec3c9534b5493802937da"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, userID, channelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join.go"},"region":{"startLine":141}}}],"partialFingerprints":{"codehealthFindingId/v1":"421f003bf86584d52100c39f707e8b1b83e7e3dbbea8ebcd63c93146930fbb30"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_member_join_requests.go"},"region":{"startLine":177}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3e7b41427b985d4b7b9812ac350a4e447611f675fe70fbc23e59d61097b466e"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":57}}}],"partialFingerprints":{"codehealthFindingId/v1":"bcd418308d8a52b608c7f046f6bd47981dc174cd645d44f6c8eea1a7361acb19"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, 0, channel.ID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":116}}}],"partialFingerprints":{"codehealthFindingId/v1":"b60b9f1eec0d77e9985a4775411f0133b6463219cdc46e33f618b6e6e72303b3"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":361}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea0f385811e94707ea5fb56e35198fb2b3094d1a38b6f16de465724c2064260b"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_delete.go"},"region":{"startLine":430}}}],"partialFingerprints":{"codehealthFindingId/v1":"dcdbaac53ddd1c6ebfd819f35fb613ed7002c02f79d08ab5715622b356442b1c"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":137}}}],"partialFingerprints":{"codehealthFindingId/v1":"b88d627585cd778a99fb1919bfef632003f2b6ae392e34f07cdc13287c49c407"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":308}}}],"partialFingerprints":{"codehealthFindingId/v1":"25938d145ebdd31cdc2869cc7b1885455181c7b92c6876d04601a7397852176d"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":376}}}],"partialFingerprints":{"codehealthFindingId/v1":"4a05211e706d279ff969f6d359638fbc129b1cb2135550730947c0832f576e7b"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":507}}}],"partialFingerprints":{"codehealthFindingId/v1":"615c3a774719f722c66a88896be94012e385726556d7517c1df08316fee35824"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_edit.go"},"region":{"startLine":593}}}],"partialFingerprints":{"codehealthFindingId/v1":"eb840996165e6b6cbef4770a13f4791e8a0e3ab9b1becf5962e8a8de6581b9a3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":727}}}],"partialFingerprints":{"codehealthFindingId/v1":"72666c0c0ac817690c437c8eb60d2b417bc15d891788254509123177aa97a5cc"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060msg, _ := s.getChannelMessage(ctx, tx, req.ChannelID, channel.TopMessageID)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060msg\u0060 as if the call succeeded. When \u0060s.getChannelMessage\u0060 fails, \u0060msg\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060msg\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_message_history.go"},"region":{"startLine":1004}}}],"partialFingerprints":{"codehealthFindingId/v1":"55d1fa4613205f7703e1b647cb27b9578279cc9e78890587d4d4be08bf28952e"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":80}}}],"partialFingerprints":{"codehealthFindingId/v1":"181b3c216718cde24f42a394cdafca98675f3c255cd5d52d2854572f9496f749"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":154}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bf3b71b112098836c3bbdef87a7ccbdae3c5243705712684be6144266dad361"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, userID, channelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_settings.go"},"region":{"startLine":700}}}],"partialFingerprints":{"codehealthFindingId/v1":"94c38ed3b480081bc42b0d1d81159ae9d5477f0724a4a0f3e7289e5155c82e67"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":337}}}],"partialFingerprints":{"codehealthFindingId/v1":"aaae321146f2e3cf13f85cf52c5c429edf7b1f7b43f2d73c42a3d7ac74e3c266"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":382}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5320333568b7ecea2da0381e6ae126182b5e20c8ea6bc4b3ff5d353cf80b07a"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060recipients, _ := s.ListActiveChannelMemberIDs(ctx, req.UserID, req.ChannelID, 0)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060recipients\u0060 as if the call succeeded. When \u0060s.ListActiveChannelMemberIDs\u0060 fails, \u0060recipients\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060recipients\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":468}}}],"partialFingerprints":{"codehealthFindingId/v1":"329c6aeda71c7c2039d203689f22cb7a81ad0650a6de87990b5f1d33f7ebc09b"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060dialog, _ := s.getChannelDialog(ctx, s.db, viewerUserID, channel)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060dialog\u0060 as if the call succeeded. When \u0060s.getChannelDialog\u0060 fails, \u0060dialog\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060dialog\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":537}}}],"partialFingerprints":{"codehealthFindingId/v1":"7bd3f60a1c3067781d177f302c9fcc98479db28065fb62d270c13cfe932a32aa"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060dialog, _ := s.getChannelDialog(ctx, s.db, viewerUserID, channel)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060dialog\u0060 as if the call succeeded. When \u0060s.getChannelDialog\u0060 fails, \u0060dialog\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060dialog\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":550}}}],"partialFingerprints":{"codehealthFindingId/v1":"5e641a987fb401ba802dee3d33b1f22581e71d74e81fab360fda3f1537c793df"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060dialog, _ := s.getChannelDialog(ctx, s.db, viewerUserID, channel)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060dialog\u0060 as if the call succeeded. When \u0060s.getChannelDialog\u0060 fails, \u0060dialog\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060dialog\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/channel_topics.go"},"region":{"startLine":584}}}],"partialFingerprints":{"codehealthFindingId/v1":"266e6a4c91aefa3feb6a4dbc6899d5ea14b6a4fcc21990567dd9ba72481eda59"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060rights, _ := json.Marshal(c.DefaultBannedRights)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060rights\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060rights\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060rights\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":487}}}],"partialFingerprints":{"codehealthFindingId/v1":"0eecf260bfd57787893f620dad0f50c33fae5af742b2ba944a394666aba19078"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060adminRights, _ := json.Marshal(domain.CreatorChannelAdminRights())\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060adminRights\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060adminRights\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060adminRights\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"865e6c71f0863f954fc77c8810f684e56af6c04f4d3db7a57569ae023c8b908b"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060b, _ := json.Marshal(c)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060b\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060b\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060b\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":636}}}],"partialFingerprints":{"codehealthFindingId/v1":"743e74245a785ad7466968a6ad7d019a0dff54a065761d589fde72feb1bd5af9"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060rights, _ := json.Marshal(req.Rights)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060rights\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060rights\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060rights\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1156}}}],"partialFingerprints":{"codehealthFindingId/v1":"766eebbc57fd017bdf4df13ba3577ae3cd33eb450a45aa431386f21be618e2e5"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060raw, _ := json.Marshal(rights)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060raw\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060raw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060raw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/community.go"},"region":{"startLine":1189}}}],"partialFingerprints":{"codehealthFindingId/v1":"88f2f4b403254bf63669cdc55448094a689e396445005fe4a8dc84c5261e26e8"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := fmt.Sscanf(offset, \u0022 \u0022, \u0026d, \u0026u); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/groupcall.go"},"region":{"startLine":935}}}],"partialFingerprints":{"codehealthFindingId/v1":"8796920e8c29608bce3f512f3298d732bbc526cc6b5458d926540eab4b13c3aa"}},{"ruleId":"X3","level":"warning","message":{"text":"Lost error (reports an error that is nil on this path): \u0060if err == nil\u0060 reports \u0060err\u0060 on the one path where it is nil, and the path where the call failed goes on without ever reading it: the comparison is inverted. The real failure is lost and a nil error (or a panic on \u0060err.Error()\u0060) is reported in its place. Test \u0060err != nil\u0060 here."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_lifecycle.go"},"region":{"startLine":1542}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a54a7d75bc2a480ec209f9c6705e2b4311e43f562f629f7b9799499a1ccf48b"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060entitiesJSON, _ := encodeMessageEntities(req.MessageEntities)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060entitiesJSON\u0060 as if the call succeeded. When \u0060encodeMessageEntities\u0060 fails, \u0060entitiesJSON\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060entitiesJSON\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/postgres/star_gift_purchase.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c3593578ff71f2f2916b9f82d604c93a8f16413343df8a67fc4518ffd8ccd0c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := s.channelForMemberLocked(viewerUserID, channelID); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2fd90839805d9ec56fad255f41c41608b4c284987edd70bb5cbd06997fb48fb"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := s.channelForMemberLocked(userID, channelID); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":272}}}],"partialFingerprints":{"codehealthFindingId/v1":"5251f5245b336fbac3bed09563e5551de2cc915520da4c9e448181f277006977"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"81651f85defc01216a13c657d3d526dfd212695f784ba3ab063891ce0476c93d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":396}}}],"partialFingerprints":{"codehealthFindingId/v1":"f96802a8bc83b852f2c8f0d04eeedc8567af6904b55d752fe632b7a373c8b8f6"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"6b1f3580a0bd48339e8d085cc46bb3d9508e6ae9a61c2d9419affee2d5ae1dc5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := s.channelForMemberLocked(userID, channelID); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_read.go"},"region":{"startLine":43}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee2b65f13526954151b40ee599060f774a39ee8ed609327dbaafe570a4a5b18e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_topics.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"2b669f888d4a00d6ab256e33590d35ac693b7c755bb6acbe09e754cb1ae9f905"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":546}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f8fe7f9bd0a27eb10a89fd84680b3706cf71d6f75f3632e5e67401a2fad0c12"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := stream.Read(buf); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":559}}}],"partialFingerprints":{"codehealthFindingId/v1":"324ce90ebb7221dc6632cdb61d2c1d6874cfa513cbd2a3f06d64537bab7c5dcc"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":576}}}],"partialFingerprints":{"codehealthFindingId/v1":"c463bb6634c450065ed82fec04223dad035e6b88f717b335b3cde91de3f232c4"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":583}}}],"partialFingerprints":{"codehealthFindingId/v1":"b577a33b945fcf987ec1bc30de167b95bfdb8c63dddd58999cbf70e0c8e11b35"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":588}}}],"partialFingerprints":{"codehealthFindingId/v1":"45c48ebca9c6451a03626e97fc53a62c3f3d52a4e8f7c7227ddd858044936d6c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":629}}}],"partialFingerprints":{"codehealthFindingId/v1":"953e5235ef27c4a6bc517aff34e78de6300770f7473c7d1caa08bf61e43c67da"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":673}}}],"partialFingerprints":{"codehealthFindingId/v1":"cbd40d1c95e8ce85591f20cbf7d440c8991b99029ba1ebdbf7952e74c6f28fa5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := json.Unmarshal(buf[:n], \u0026msg); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/sfu/pion.go"},"region":{"startLine":683}}}],"partialFingerprints":{"codehealthFindingId/v1":"768d00610cc5d5ae19b27feb4acd6c1578fc5a64ffc6ae9fc8ffff58eb33715f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":925}}}],"partialFingerprints":{"codehealthFindingId/v1":"0a8ba20c2d9ebdf214486af342ec48850b08aeaf5c2d8ca50f5f372cfa3c0007"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060viewerID, _, _ := r.currentUserID(ctx)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060viewerID\u0060 as if the call succeeded. When \u0060r.currentUserID\u0060 fails, \u0060viewerID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060viewerID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_business.go"},"region":{"startLine":227}}}],"partialFingerprints":{"codehealthFindingId/v1":"1f6a1c5f1e6275f1e6cb4d0bc26d2a56ba82c42f94bcc12be1542b5bf84b0b5f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account_notify.go"},"region":{"startLine":231}}}],"partialFingerprints":{"codehealthFindingId/v1":"98caf60caa7c97ea9e2cfc2cb49e417dba3fec1a6bde513c943e3c252c5d7667"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"34cf6d1de8b658010f7c58e443f5d49a7408604f85eb139d3757e76a51acf42d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":365}}}],"partialFingerprints":{"codehealthFindingId/v1":"642df17580b80075ecca51494a97d918f381a51d9bffe8ed892cd4ec708a334d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":129}}}],"partialFingerprints":{"codehealthFindingId/v1":"67435b84c0c250b1db763c5b414b1913acdc79ce1825bad1ea6bdacf94a4258d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":152}}}],"partialFingerprints":{"codehealthFindingId/v1":"07073c280387a44f9cda7a9d2bcad81a57fb3e852a6ab6e139be523a54b95547"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":427}}}],"partialFingerprints":{"codehealthFindingId/v1":"e109449f8767cfe0a00c69dd1a293b2961f3781d4838d6e5418bbd67f1327578"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":467}}}],"partialFingerprints":{"codehealthFindingId/v1":"b95d341fde8ef55e42079ef8205fdd46347595ad11c8e1fd012611063db15334"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/botapi_update_queue.go"},"region":{"startLine":483}}}],"partialFingerprints":{"codehealthFindingId/v1":"a2b85e3941b79a09678ee2d6d1c7bfdc5ca805faf78bbe615fccf95a7fd71c24"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":841}}}],"partialFingerprints":{"codehealthFindingId/v1":"8140c998f45dd659515fb19ba03b185f138a7e0b6dad6f23ad6964f978bea2cb"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bots_longtail.go"},"region":{"startLine":854}}}],"partialFingerprints":{"codehealthFindingId/v1":"386f04192f701586ece362b48fe13443abaa4a2dc8993f42b55a34863972ad12"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060queryID, pending, _ := c.registerContext(context.Background(), time.Now(), botUserID, userID, botCallbackTimeout)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060queryID\u0060 as if the call succeeded. When \u0060c.registerContext\u0060 fails, \u0060queryID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060queryID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/callback_registry.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"054c2c864dab9fe057f21f73be3273038a08a1ae491f03f66109eb2c41b58017"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060resolved, _ := c.resolveContext(context.Background(), callerBotID, queryID, ans)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060resolved\u0060 as if the call succeeded. When \u0060c.resolveContext\u0060 fails, \u0060resolved\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060resolved\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/callback_registry.go"},"region":{"startLine":125}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d7847037da25213e13e418e30892ff0cdeb6c868b622c83131f14db3994b8b0"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := rand.Read(buf[:]); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/callback_registry.go"},"region":{"startLine":195}}}],"partialFingerprints":{"codehealthFindingId/v1":"80952a128d1246dc42b5a94292c423e5bf111b174aa0ded4c5e1497d35fbddd9"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9eafa6727e463529909f3e55fbef7e920ba1d21768bf88d146660a558e4d5a5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channels_members.go"},"region":{"startLine":724}}}],"partialFingerprints":{"codehealthFindingId/v1":"821a5b1704b335fe5d10bfc8112ab52b269fad57158ce2acd81d0d2029d134ea"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/convert_phone_group.go"},"region":{"startLine":239}}}],"partialFingerprints":{"codehealthFindingId/v1":"4100fe4591ce968e060c27f99391964b024f6fd2973c017db2fb75673ddde4b7"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_messages.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"792b6ac52e103a068b1afbfb5088429b233e8557e760731ff68845d9f00ac454"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/ephemeral_push.go"},"region":{"startLine":77}}}],"partialFingerprints":{"codehealthFindingId/v1":"4076b7fe37e100b5e8a857b05715ccb8215919828bffd3650a9ceb45663e2862"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/groupcall_sweep_dispatcher.go"},"region":{"startLine":81}}}],"partialFingerprints":{"codehealthFindingId/v1":"b404ce82b16ceb9764c678b59b6e9d75c74db574cd5bd8af53ce86f9708a4946"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_helpers.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"3fbe9e7c655db7d620e71b44ad7ca8f7cca7970ac8e6e4f230bf9ba83646226f"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060updates, _ := r.monoforumSendUpdatesWithPeerCacheAndOverlaysStrict(ctx, userID, mono, savedPeer, res, cache, overlays)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060updates\u0060 as if the call succeeded. When \u0060r.monoforumSendUpdatesWithPeerCacheAndOverlaysStrict\u0060 fails, \u0060updates\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060updates\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_monoforum.go"},"region":{"startLine":428}}}],"partialFingerprints":{"codehealthFindingId/v1":"e4987bcb9ea3e75ef278fccb635bf561489a6031213cb2e6f2b2befd3ce4e1c6"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls_updates.go"},"region":{"startLine":48}}}],"partialFingerprints":{"codehealthFindingId/v1":"18627ed3e4c89625184af1a8c6c5a1c93d12d4e83722d10d2ec37d348651bbd5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls_updates.go"},"region":{"startLine":61}}}],"partialFingerprints":{"codehealthFindingId/v1":"474310183c3541dc156c551d404fd7786d2be8c9e9c7d500be8ac052de3d63da"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":759}}}],"partialFingerprints":{"codehealthFindingId/v1":"62cc0879e6468df0c05e0c4f6402f42950c740bfb0f580f1a33e9d01bcf269d1"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send.go"},"region":{"startLine":1202}}}],"partialFingerprints":{"codehealthFindingId/v1":"18a6dfea3227a7bae7b7e96c06e0fa298c1b7fc0ce9ba812ad12e202d57c88c4"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send_as.go"},"region":{"startLine":119}}}],"partialFingerprints":{"codehealthFindingId/v1":"e76ca77da330a16bbf9372c26488dd0f0514eb6a5dd189dcc5ea540b9ce13a48"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send_as.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"f29d6ec9ad9c390a6a882dcfe833af966e1b3dd38afec33550c7bebbfcf4221b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send_as.go"},"region":{"startLine":161}}}],"partialFingerprints":{"codehealthFindingId/v1":"50de6fee3af9375945faea2201bd8af1fe28939d6688e103235a81a1423e0e9a"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := r.validateForeignChannelSendAs(ctx, userID, view.Channel.ID, def.ID); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_send_as.go"},"region":{"startLine":182}}}],"partialFingerprints":{"codehealthFindingId/v1":"d79d2ca0d84b7d82da80fe05c4104923d48329279b52daf40c51a815c39e569c"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060updates, _ := r.suggestedPostApprovalUpdatesWithPeerCacheAndOverlaysStrict(ctx, viewerUserID, result, cache, overlays)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060updates\u0060 as if the call succeeded. When \u0060r.suggestedPostApprovalUpdatesWithPeerCacheAndOverlaysStrict\u0060 fails, \u0060updates\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060updates\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_suggested_post_updates.go"},"region":{"startLine":16}}}],"partialFingerprints":{"codehealthFindingId/v1":"4bf2a8327cf5ec27a1e1aecea1e53c59fe06c196ccd5b839f13847dca72bf7df"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/notify_settings_cache.go"},"region":{"startLine":66}}}],"partialFingerprints":{"codehealthFindingId/v1":"edf93a831ce6a3193c326a5289f0a99a919ad83df6e3f17735374f8edf3e7b5c"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060viewerID, _, _ := r.currentUserID(ctx)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060viewerID\u0060 as if the call succeeded. When \u0060r.currentUserID\u0060 fails, \u0060viewerID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060viewerID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":536}}}],"partialFingerprints":{"codehealthFindingId/v1":"737f944c54f1448f91e47a289fd90d8c11b6ebe851f29ad2f3b9c97485d3a09f"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060balance, _ := r.deps.Gifts.TonBalance(ctx, userID)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060balance\u0060 as if the call succeeded. When \u0060r.deps.Gifts.TonBalance\u0060 fails, \u0060balance\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060balance\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/payments_star_gift_lifecycle.go"},"region":{"startLine":765}}}],"partialFingerprints":{"codehealthFindingId/v1":"9022ad157e96750b4637143b70e940761b30d98270c44e3c62485051aae2b1dd"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/peer_identity_cache.go"},"region":{"startLine":153}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6c91a47e321235570cfb6af4651fcd6ed17bf7fc5a538e36083bb3fa64a9ea1"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/peer_identity_cache.go"},"region":{"startLine":201}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f2f7fe8f259999c3adf039dbd839c5bbf8dcdf172d1874aa2e9433a917f6138"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":241}}}],"partialFingerprints":{"codehealthFindingId/v1":"721f6a7f83149e15fa81b01cba835b26e26e3f44723dd48be69ab4bfcb14fec1"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060p, found, _ := r.deps.GroupCalls.Participant(ctx, scope.call.ID, scope.userID)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060p\u0060 as if the call succeeded. When \u0060r.deps.GroupCalls.Participant\u0060 fails, \u0060p\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060p\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call.go"},"region":{"startLine":290}}}],"partialFingerprints":{"codehealthFindingId/v1":"3010c89ba5ad2fc40252ac76ed76ab0b44671acbdd562ff011eab950be930fca"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060p, found, _ := r.deps.GroupCalls.Participant(ctx, scope.call.ID, scope.userID)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060p\u0060 as if the call succeeded. When \u0060r.deps.GroupCalls.Participant\u0060 fails, \u0060p\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060p\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_rtmp.go"},"region":{"startLine":44}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6b8f09f0d9ebee82c2a44bbec51573442ffdc34d43045a1cf58b65c2936ccce"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := rand.Read(buf[:]); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_rtmp.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"a0deb0e34253337591cd687a7a0a3436b00b10897fcfcd87d938fe4a757b3abb"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_scheduled.go"},"region":{"startLine":24}}}],"partialFingerprints":{"codehealthFindingId/v1":"628521cc898bdb789012c1ee8d40057c0cb31665045c2507f5ed3dcc0ace0a57"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_updates.go"},"region":{"startLine":120}}}],"partialFingerprints":{"codehealthFindingId/v1":"c3832d0aadc2207f74fc0af4a4424d06eb66aa77c72692e6bfcbdc90c794e8bc"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_history.go"},"region":{"startLine":30}}}],"partialFingerprints":{"codehealthFindingId/v1":"89fb27ab10a3d321f42e6d3e715f8624612ce6d7278b5c32f20ac34a3471627e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_turn.go"},"region":{"startLine":27}}}],"partialFingerprints":{"codehealthFindingId/v1":"e0317e21544a56d229448a6734a7e06da6354401c31f23383fdd417c631d5cc7"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_turn.go"},"region":{"startLine":31}}}],"partialFingerprints":{"codehealthFindingId/v1":"83ad318731347322c653c6b23f31665646134a978dc7ada4ff6f6af227ba8199"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/photos.go"},"region":{"startLine":538}}}],"partialFingerprints":{"codehealthFindingId/v1":"3c731894247a598827de2046d2a9c43b8fa267596d90a81868047d3b02e00fa0"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":439}}}],"partialFingerprints":{"codehealthFindingId/v1":"3ed7b304c5fce36415739a3dcb1abdf6fc7217f9725dd916eb8fdb3af7246653"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if ids, err := provider.PrivateDialogPeerIDs(ctx, userID, presenceDialogFanoutCandidateLimit); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/presence.go"},"region":{"startLine":1127}}}],"partialFingerprints":{"codehealthFindingId/v1":"77abdbafa5c4566055a6e91d18cef50acb66546bdc2059dd1d9c15c1bc05e323"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/reactions_android_compat.go"},"region":{"startLine":124}}}],"partialFingerprints":{"codehealthFindingId/v1":"f5143c2f63ee515151b600dae2f52b017a7caa6bbb79236f5cedb32fbeb4247f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := preflightRPCWire(id, raw); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/request_preflight.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"48e4badd3dbf6ad7e6cfc97b3929a1373bdd50cfe0c9d09228ac95b3b77181af"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060id, _ := b.PeekID()\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060id\u0060 as if the call succeeded. When \u0060b.PeekID\u0060 fails, \u0060id\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060id\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/router.go"},"region":{"startLine":1861}}}],"partialFingerprints":{"codehealthFindingId/v1":"316e411fcab618d858584c1c6ad68ce6e7026163faff3eab159c604e68d06836"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":1208}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6810476c01d2d6a9139a53243942de06edb14bb90dd364dc8e492b0ae91ad1e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/sticker_catalog_cache.go"},"region":{"startLine":42}}}],"partialFingerprints":{"codehealthFindingId/v1":"774305abe119b8735afb8156a292f5df8e2b9b9b58b5791816fa858ca29b91e9"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/sticker_catalog_cache.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9a08fec66c1ee3ccc8f153c89155f3b1d4d5c2e1e8e9b816dd387c250650a94"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers.go"},"region":{"startLine":513}}}],"partialFingerprints":{"codehealthFindingId/v1":"59a45a84a3d9c8c802e8a39ab5c1ac1594bb159aba2fa3fe36e47a5169943673"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060encoded, _ := json.Marshal(r)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060encoded\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060encoded\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060encoded\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers.go"},"region":{"startLine":552}}}],"partialFingerprints":{"codehealthFindingId/v1":"2453ca71c423edc0783d913a29955a49d20d996cc3ebd88882a16422ab996ba9"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060encoded, _ = json.Marshal(doc)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060encoded\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060encoded\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060encoded\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stickers.go"},"region":{"startLine":562}}}],"partialFingerprints":{"codehealthFindingId/v1":"de196796d8466b2c1eea8ce0ea40e2aa1368bb94e87893339bc6459250322e10"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3266}}}],"partialFingerprints":{"codehealthFindingId/v1":"0c15bd3e369ef707415737998761de12896b638ebec2078df03645ac4f05f8ea"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060out, _ := r.enrichPreparedUpdateEvents(ctx, viewerUserID, events, cache, false)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060out\u0060 as if the call succeeded. When \u0060r.enrichPreparedUpdateEvents\u0060 fails, \u0060out\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060out\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"fac250b4b8a8774ab2418ef8d5e71a56ce458bfd309210f24bd271962bf1332f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":196}}}],"partialFingerprints":{"codehealthFindingId/v1":"56959558af20392568c5cb3e17feb298516054e1cd7060d239e6375944c98ac8"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060out, _ := r.enrichChannelDifferenceUsers(ctx, viewerUserID, diff, false)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060out\u0060 as if the call succeeded. When \u0060r.enrichChannelDifferenceUsers\u0060 fails, \u0060out\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060out\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/update_peer_refs.go"},"region":{"startLine":226}}}],"partialFingerprints":{"codehealthFindingId/v1":"40ef5e3fbf7f2b3b2b756fd852ac667415eb8bf0ab949daf59ab26d1ef18105f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/users.go"},"region":{"startLine":591}}}],"partialFingerprints":{"codehealthFindingId/v1":"c7a527aee5b20279e29b1ec7b128f7bce488197f27c79d237d90be2a0f1e6d46"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/procctl.go"},"region":{"startLine":121}}}],"partialFingerprints":{"codehealthFindingId/v1":"df5f099c65a8fcf45ce8be58ac977becd498272d09f393b57ef78ca23abf5929"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/serverinfo.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"85b43c53644b06f05726ea993207e6b4301ad4c7d31fe892708af2bfb31ec5b4"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060values, _ := m.readEnvFile()\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060values\u0060 as if the call succeeded. When \u0060m.readEnvFile\u0060 fails, \u0060values\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060values\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/serverinfo.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdacda21fa62669a5ab95f882536e554ee112e041a2b4b3be603a89d43a7da16"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/serverinfo.go"},"region":{"startLine":56}}}],"partialFingerprints":{"codehealthFindingId/v1":"5663a4cdcdb48f45936d5e53d371faaa8c7a4129f9c71c4f2bd36834bb2da922"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/serverinfo.go"},"region":{"startLine":64}}}],"partialFingerprints":{"codehealthFindingId/v1":"1aec640db466e3d366d1cdb1478379aef669f3e9c6627a930d607bd0ba242b4a"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"64195188baf8402af01bfabb36a08bb54e050e9c1acbd8b09eef73b28c97d0d9"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":50}}}],"partialFingerprints":{"codehealthFindingId/v1":"b77ab2297858e31b03f9e39065eac7000c144fd8e1a81c3b6e11a5c461b9650e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":223}}}],"partialFingerprints":{"codehealthFindingId/v1":"f67e8b621bd0f4af521babd2b6cbd454424d13e9da88a000a85cbd8ee0f5982d"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060fileValues, _ := p.m.readEnvFile()\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060fileValues\u0060 as if the call succeeded. When \u0060p.m.readEnvFile\u0060 fails, \u0060fileValues\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060fileValues\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":354}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f983ccad30a1db43bb20c7625cd6c9a19a25005dc8ab73f69ea95ca271a4f6c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (empty catch): An empty catch block silently discards the error \u2014 failures vanish with no log and no rethrow. Log it, handle it, or don\u0027t catch it."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/observability/metrics/registry.go"},"region":{"startLine":519}}}],"partialFingerprints":{"codehealthFindingId/v1":"0952d15e8b637cc0a9bdc3333f4b6601fa01133597c977aac09d37afec6e9c51"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/exchange_compat.go"},"region":{"startLine":479}}}],"partialFingerprints":{"codehealthFindingId/v1":"fc38bbaefd6110553387998d67a58d122e13f87b85eef6bed673f167f20ef279"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":947}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea7a8690cae199c2e9fd4cf1e08b320df35a80ea73e1edd2ef575da5c4ac3b67"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := probe.ConsumeID(id); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":956}}}],"partialFingerprints":{"codehealthFindingId/v1":"c4c6df258e9ca34eac486f3bd7334f34c4493a00aad57575d076baccfc202aa0"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := probe.ConsumeID(id); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":960}}}],"partialFingerprints":{"codehealthFindingId/v1":"903e0cf5088fc69fe127fb4a5b4ef162033656fbe0a2641912d3ead661212338"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := probe.Long(); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":963}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d5761494804e3ce04bae454cbd0063ad86aa2d50574a4ab15057f3999476f59"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := probe.ConsumeID(id); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/mtprotoedge/inbound_layer_rpc.go"},"region":{"startLine":967}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f86fe9acbb651409c05a2e46c08fa4c0e8aba4835ad5e935ea920b357300389"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := strconv.Atoi(parts[2]); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/delivery.go"},"region":{"startLine":128}}}],"partialFingerprints":{"codehealthFindingId/v1":"7dc0d360a45491d8ad5d505bd7446b4c0530f87946889fa323e0a8d709355f69"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/report.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"c934037a0396bc76b482c3faeedc7a5a0fb6449b9b116eb143ae833983cfaeb5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":470}}}],"partialFingerprints":{"codehealthFindingId/v1":"d209a2fc8fccbc07450b7eaccc9d920fc00d520c303d28af0e9d3ea8c955ad2d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":509}}}],"partialFingerprints":{"codehealthFindingId/v1":"43df70fdf98d1c0d92fa8eed8c4ab7dcfeaaf8a1acf10b30888671899d4729f1"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := cryptorand.Read(randomBytes[:]); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/run.go"},"region":{"startLine":542}}}],"partialFingerprints":{"codehealthFindingId/v1":"f2149846922fdad21a4718e75ce4b0ad1a7745dfa6fc382da3c4f9502a8bad26"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/seed.go"},"region":{"startLine":516}}}],"partialFingerprints":{"codehealthFindingId/v1":"9fff5e5ecea1271120407e6b94704d79bd8b61d53c722ba4453a4ea2cbcd9395"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060profile, _ := resolveStartupProfile(cfg.Profile)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060profile\u0060 as if the call succeeded. When \u0060resolveStartupProfile\u0060 fails, \u0060profile\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060profile\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/loadharness/startup.go"},"region":{"startLine":142}}}],"partialFingerprints":{"codehealthFindingId/v1":"58685b9fda21355e71ba8ea93b125fde8e4be54ac26700c4b2ab5baee9b543d9"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060parsed, _ := url.Parse(base)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060parsed\u0060 as if the call succeeded. When \u0060url.Parse\u0060 fails, \u0060parsed\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060parsed\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":108}}}],"partialFingerprints":{"codehealthFindingId/v1":"f7cfabf3127f9317694f5c401de0580125f5278997a4325da01f3ab76a8b3799"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":243}}}],"partialFingerprints":{"codehealthFindingId/v1":"1497c60f84cd4486c4ad615e51e7b7233622b0219869a6d332f405b7df0dd032"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060parsed, _ := url.Parse(baseURL)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060parsed\u0060 as if the call succeeded. When \u0060url.Parse\u0060 fails, \u0060parsed\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060parsed\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":246}}}],"partialFingerprints":{"codehealthFindingId/v1":"311225f79f2d3665a2649135c51e2e531e7f4a2a98942b38a0add5d9b052c895"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"183c13303253304a04288c9a99faac7e625c6b3f4cadb49964dfa21321a3632d"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060parsed, _ := url.Parse(baseURL)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060parsed\u0060 as if the call succeeded. When \u0060url.Parse\u0060 fails, \u0060parsed\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060parsed\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":263}}}],"partialFingerprints":{"codehealthFindingId/v1":"6922e27dcb4d5f545d5e5798c0b85a280e8726b573620029abb2688f7d1b12ec"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/identity/identity.go"},"region":{"startLine":135}}}],"partialFingerprints":{"codehealthFindingId/v1":"e305e6f6df498abbb2ef1183818b4465927ad0bf9629ae89c07a0ea346c15cdf"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/identity/identity.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"0d2d3fbae5b14d8dbe3f1205520eb96576a58bd3e64c438ebc0f0aa8ff3579c6"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/hoststats/cpu_unix.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"0f3cf1eee95001c1799d2bd26e3fac87048bab1aac42c1e7b6488e3d55822ce9"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060r, _, _ := procGetSystemTimes.Call( uintptr(unsafe.Pointer(\u0026idleFT)), uintptr(unsafe.Pointer(\u0026kernelFT)), uintptr(unsafe.Pointer(\u0026userFT)), )\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060r\u0060 as if the call succeeded. When \u0060procGetSystemTimes.Call\u0060 fails, \u0060r\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060r\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/hoststats/cpu_windows.go"},"region":{"startLine":52}}}],"partialFingerprints":{"codehealthFindingId/v1":"1164c3840e757bbdac05a1c365d305f36b59b4c8318d4f70b3aa9842ee566269"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := os.Stat(filepath.Join(dataDir, \u0022 \u0022, \u0022 \u0022)); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/embeddedpg/embeddedpg.go"},"region":{"startLine":147}}}],"partialFingerprints":{"codehealthFindingId/v1":"d88ce4fc1e15b8de62d41c0dba348af1dd9ba3463f00bb3831906ec298797265"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := os.Stat(pgCtl); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/embeddedpg/embeddedpg.go"},"region":{"startLine":151}}}],"partialFingerprints":{"codehealthFindingId/v1":"6ae029063a570d2b866e99b124e54f97bb7ff842b09cfae6a6be290bf6302ec3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/star_gift.go"},"region":{"startLine":1460}}}],"partialFingerprints":{"codehealthFindingId/v1":"f046cf4b45208ce474b0258da7eda5131bcd5647fe36b7a75058df8241714677"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/stars.go"},"region":{"startLine":273}}}],"partialFingerprints":{"codehealthFindingId/v1":"3cfd8cc22f369aabae12211c5625fd1df30381977c88e9ff7692563dc6a4d6e8"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/domain/webpage.go"},"region":{"startLine":18}}}],"partialFingerprints":{"codehealthFindingId/v1":"5f795f0c277c57cf07e8d28058f785a36fb9230e1ed477ef1d3c00f2a0f0dc6e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":2251}}}],"partialFingerprints":{"codehealthFindingId/v1":"325053a5a2b52c7eeefebccdf4841045b4ceef9862b6afdf7bee44aa67a48b43"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/config/config.go"},"region":{"startLine":2449}}}],"partialFingerprints":{"codehealthFindingId/v1":"f0d7cc10ffc47f0656da9af4e3afd340481d39bed6190f1ee85a13075055231f"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060body, _ := json.Marshal(directInvoiceCurrencies)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060body\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060body\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060body\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/compat/android/stars.go"},"region":{"startLine":22}}}],"partialFingerprints":{"codehealthFindingId/v1":"210d945ff6668945944153c6cea22bed6b6eb9866047bc9a8eaaac155631af98"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060parsed, _ = url.Parse(raw)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060parsed\u0060 as if the call succeeded. When \u0060url.Parse\u0060 fails, \u0060parsed\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060parsed\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/branding/branding.go"},"region":{"startLine":181}}}],"partialFingerprints":{"codehealthFindingId/v1":"e2dba6d87ffdb10bea38005034b37372f4e7df7bccc04c9906caaaf486619cf9"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":429}}}],"partialFingerprints":{"codehealthFindingId/v1":"a53506b6edb3c643d6df8c301eac0c01580cdf9a9c2d6e3b1c886bfe2d23ca6f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/formatted_text.go"},"region":{"startLine":922}}}],"partialFingerprints":{"codehealthFindingId/v1":"5bbbae254e127c252df8f8608b2e308fb2647a12667cd27ff64107093912ea6d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":21}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d4daa93c26eb37196d19bab1aad3abd6a2f7bac2fc142ff096a7d0835bde0e6"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/projection.go"},"region":{"startLine":975}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c03b003b63bcc59a39f1dd8ac5518bbb4e11416547576405d33ca76a2a622d8"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if _, err := w.Write(chunk.Bytes); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":963}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a937abbf6afdeccfd76c3efe69107b55562c7022cc1ad314e07655560c38f9f"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060b, _ := json.Marshal(x)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060b\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060b\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060b\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1292}}}],"partialFingerprints":{"codehealthFindingId/v1":"1179811062f462e613b064e57a817fcea2d3832f9293c39e259ec8909c2c99b7"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060b, _ := json.Marshal(body)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060b\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060b\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060b\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/botapi/server.go"},"region":{"startLine":1298}}}],"partialFingerprints":{"codehealthFindingId/v1":"c306a31cec4c90d3b25f92a16c79434ee7db41ea99fa9f3e3111b795f77adc30"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060u, _ := url.Parse(redirectURI)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060u\u0060 as if the call succeeded. When \u0060url.Parse\u0060 fails, \u0060u\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060u\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":641}}}],"partialFingerprints":{"codehealthFindingId/v1":"0b37a5a41fa5015168e59fc3eef86d246c693dacbb6d2e779d16ad45ea630a0d"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060redirectURL, _ := url.Parse(redirectURI)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060redirectURL\u0060 as if the call succeeded. When \u0060url.Parse\u0060 fails, \u0060redirectURL\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060redirectURL\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":650}}}],"partialFingerprints":{"codehealthFindingId/v1":"c729799e3a8425da00cde7da1a2992174f8db3072b23bbc15f4e2e5389c763ed"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060redirect, _ := url.Parse(redirectURI)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060redirect\u0060 as if the call succeeded. When \u0060url.Parse\u0060 fails, \u0060redirect\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060redirect\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":740}}}],"partialFingerprints":{"codehealthFindingId/v1":"03b7553e04de561f239688a6ec7397ae730bb6a9e1c1a42309aaed667f315280"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060redirect, _ := url.Parse(redirectURI)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060redirect\u0060 as if the call succeeded. When \u0060url.Parse\u0060 fails, \u0060redirect\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060redirect\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/telegramlogin/service.go"},"region":{"startLine":747}}}],"partialFingerprints":{"codehealthFindingId/v1":"cd7eca2a5d5d17fe71b9ee159944d9036633e600f7bb8b77397f0d3d0614d93c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/thumb.go"},"region":{"startLine":59}}}],"partialFingerprints":{"codehealthFindingId/v1":"07721ad3b6b0fd6a4e1512361cf41b444777ed9c6fc319be006632c37e358176"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/stargifts/thumb.go"},"region":{"startLine":122}}}],"partialFingerprints":{"codehealthFindingId/v1":"2e77c0873e0103e691ca516f7d6a17e7169c2a9b8d24987a2a3f744353049cae"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := weights.Validate(); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/rating/service.go"},"region":{"startLine":70}}}],"partialFingerprints":{"codehealthFindingId/v1":"d5ae973a8cfee17942b3d53ec0a941e3c233567c20a1837e95040612731b5b3c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":173}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa92f9979563aa97c26c349c912c5627620f38161284ac95a3d8ef3efd676207"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/messages/business_automation.go"},"region":{"startLine":369}}}],"partialFingerprints":{"codehealthFindingId/v1":"4ecc9077337af566d674bffdad5ff29b133d3a715325f9a47c399ae4206693db"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/langpack/parser.go"},"region":{"startLine":134}}}],"partialFingerprints":{"codehealthFindingId/v1":"10a748f0b61807140072c61d2facc68841e9d53e3fb0047efbd7bd12beeab240"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060appeal, _ := json.Marshal(freeze.AppealURL)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060appeal\u0060 as if the call succeeded. When \u0060json.Marshal\u0060 fails, \u0060appeal\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060appeal\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/help/service.go"},"region":{"startLine":268}}}],"partialFingerprints":{"codehealthFindingId/v1":"a8bbe472438bcc00b7b6c18c1746c727d0d60255db6fb0a251963260838316d5"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060ref, _ := hex.DecodeString(\u002200d1f6f438a12476426a7268240fc54ff7\u0022)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060ref\u0060 as if the call succeeded. When \u0060hex.DecodeString\u0060 fails, \u0060ref\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060ref\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/freeze_seed.go"},"region":{"startLine":46}}}],"partialFingerprints":{"codehealthFindingId/v1":"5db0b2d69e48bbb29478e049c32a1be2cbb54f615b1eb5ecf8e6f0814161be22"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/maptile_proxy.go"},"region":{"startLine":314}}}],"partialFingerprints":{"codehealthFindingId/v1":"40cd5d4a1f026bbbe1c85e62eed5ec248bd79b43bdfaaf77f308e0915de116f5"}},{"ruleId":"X3","level":"warning","message":{"text":"Lost error (reports an error that is nil on this path): \u0060if entries, err := os.ReadDir(regularDir); err == nil\u0060 reports \u0060err\u0060 on the one path where it is nil, and the path where the call failed goes on without ever reading it: the comparison is inverted. The real failure is lost and a nil error (or a panic on \u0060err.Error()\u0060) is reported in its place. Test \u0060err != nil\u0060 here."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":295}}}],"partialFingerprints":{"codehealthFindingId/v1":"cfb3ee4930f483f023c0c86a8bc89879590a84c4a5d6db106337bcb45eda887a"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060ref, _ := hex.DecodeString(dj.FileReference)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060ref\u0060 as if the call succeeded. When \u0060hex.DecodeString\u0060 fails, \u0060ref\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060ref\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"ce4d8c51f9c24f294d2638f298284dfedb6d7aa8f94a3baba9741e57c36550f5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":626}}}],"partialFingerprints":{"codehealthFindingId/v1":"3be84f85f0241d6e8a2b33295e41cf06fca2eb9c254d29d2dad43492efb3843e"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":814}}}],"partialFingerprints":{"codehealthFindingId/v1":"a021d39e8d68edb8539a6df53c5826f9a1fa5ce60c5d489c920e31f16ad736df"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":819}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f2416f515b5babdf6c2b756614bec24379d21e831d858f95bc5248dcaee4d8d"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060b, _ := hex.DecodeString(t.Bytes)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060b\u0060 as if the call succeeded. When \u0060hex.DecodeString\u0060 fails, \u0060b\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060b\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":914}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff1ec59db6b943aaf9f99d8cbe79c66506331ba15e14af7038ec29a1d869dd6a"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060b, _ := hex.DecodeString(t.Bytes)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060b\u0060 as if the call succeeded. When \u0060hex.DecodeString\u0060 fails, \u0060b\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060b\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":917}}}],"partialFingerprints":{"codehealthFindingId/v1":"edf9dcf14f08cc589feaf4a1c09cb05fb0927d25dfcca0389a07785cc967eb42"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060b, _ := hex.DecodeString(t.Bytes)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060b\u0060 as if the call succeeded. When \u0060hex.DecodeString\u0060 fails, \u0060b\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060b\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":920}}}],"partialFingerprints":{"codehealthFindingId/v1":"aab13af1941cbc74fdd127448e625c045facebe58ecf9cbbf3dcc854b2743843"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := validateStickerSetShortName(candidate); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":47}}}],"partialFingerprints":{"codehealthFindingId/v1":"d3415f714f148698883b3f7971e2a13b129d733b3ff34d1afc431ac5c6260f04"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":408}}}],"partialFingerprints":{"codehealthFindingId/v1":"9eae04e5d82aa9513ebe2c33a3c76929cd17579630797c5495c3b8eca35a7606"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":479}}}],"partialFingerprints":{"codehealthFindingId/v1":"f6c9145aa6f8ddc08ef4c2d820212e2efbbb931381c21d0432a5f2ad51369859"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := json.NewDecoder(bytes.NewReader(data)).Decode(\u0026root); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/sticker_creator.go"},"region":{"startLine":505}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee687f9e203dfcfd3bbca9ccb69035864e6732c4f54a7a750e57ad678eb2dc6d"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/tgs_sticker.go"},"region":{"startLine":62}}}],"partialFingerprints":{"codehealthFindingId/v1":"96d97969021b4f72cd9ef873f97454f0c0edb797ff9ed81c3401fea528714e42"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := json.Unmarshal(raw, \u0026lottie); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/tgs_sticker.go"},"region":{"startLine":78}}}],"partialFingerprints":{"codehealthFindingId/v1":"4cb1ff22c6b01e707e7df3a03f3e768836244410a15bc67f902f36efe580cc22"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/webpage.go"},"region":{"startLine":489}}}],"partialFingerprints":{"codehealthFindingId/v1":"3eb8b1efff119652ffc3227ba5b23ad4bce5ed5955e20317c136626ab1304afe"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/webpage.go"},"region":{"startLine":493}}}],"partialFingerprints":{"codehealthFindingId/v1":"1557d5f4f88f26184bb117679a074d65d2ae93911b825d75be82d49c656b2191"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/channels/bot_policy.go"},"region":{"startLine":328}}}],"partialFingerprints":{"codehealthFindingId/v1":"b767216725af7524826e5e0c8d0e8c9ae578df03357f9738a3c532c001749f16"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060botID, _ := strconv.ParseInt(state.Draft[botFatherDraftBotID], 10, 64)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060botID\u0060 as if the call succeeded. When \u0060strconv.ParseInt\u0060 fails, \u0060botID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060botID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":588}}}],"partialFingerprints":{"codehealthFindingId/v1":"ff3a2aec238e98b5782e657ccf375aadeb68481e37fc02d303e560626d77b7c2"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060botID, _ := strconv.ParseInt(state.Draft[botFatherDraftBotID], 10, 64)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060botID\u0060 as if the call succeeded. When \u0060strconv.ParseInt\u0060 fails, \u0060botID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060botID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/botfather.go"},"region":{"startLine":735}}}],"partialFingerprints":{"codehealthFindingId/v1":"4222b8f8ce965057dec8a7c48d5581fa02ce16b87011c7d79180aaa5ab0a4c27"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/premiumbot.go"},"region":{"startLine":183}}}],"partialFingerprints":{"codehealthFindingId/v1":"d66b79f345ecfff63009ef3ea5939981cdb6a73f228657c186b73b9d511357f2"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/premiumbot.go"},"region":{"startLine":311}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9ec984fc114e5deb73299653e6cab3d30b882e447c7ed262020a82ed9b254ca"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060id, _ := strconv.ParseInt(state.Draft[stickersBotDraftSetID], 10, 64)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060id\u0060 as if the call succeeded. When \u0060strconv.ParseInt\u0060 fails, \u0060id\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060id\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":680}}}],"partialFingerprints":{"codehealthFindingId/v1":"d9036d5b1698db2d479802133d082a8142b851301618d34f06909121ba5aed63"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060accessHash, _ := strconv.ParseInt(state.Draft[stickersBotDraftSetAccessHash], 10, 64)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060accessHash\u0060 as if the call succeeded. When \u0060strconv.ParseInt\u0060 fails, \u0060accessHash\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060accessHash\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":681}}}],"partialFingerprints":{"codehealthFindingId/v1":"fdfb3e1b5a8d32f1566012d3a22f771c861c4c78331ab4e82c2b097f26b790a4"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := json.Unmarshal([]byte(state.Draft[stickersBotDraftItems]), \u0026items); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":690}}}],"partialFingerprints":{"codehealthFindingId/v1":"f4b9332eb1b287ea9b749eac8545cf3d6d8b96728b982dba89ef2934b4144ec7"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060id, _ := strconv.ParseInt(state.Draft[stickersBotDraftPendingDocID], 10, 64)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060id\u0060 as if the call succeeded. When \u0060strconv.ParseInt\u0060 fails, \u0060id\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060id\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":712}}}],"partialFingerprints":{"codehealthFindingId/v1":"0450638d83d332e213e15c43cfc0e5a3c88f2df1508e1b4ff5eb78cd02dfb841"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060accessHash, _ := strconv.ParseInt(state.Draft[stickersBotDraftPendingDocHash], 10, 64)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060accessHash\u0060 as if the call succeeded. When \u0060strconv.ParseInt\u0060 fails, \u0060accessHash\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060accessHash\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/stickersbot.go"},"region":{"startLine":713}}}],"partialFingerprints":{"codehealthFindingId/v1":"bfb308698998644ce6a20f9c8e83c8307be5f99d89b7e774eef14dedd5b9abed"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":512}}}],"partialFingerprints":{"codehealthFindingId/v1":"af0b8e731b6ced79827cb0279736ec188c4b84786ff7f8990223da7c230a585b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1425}}}],"partialFingerprints":{"codehealthFindingId/v1":"d7b3e9f7715edf3bbb25de0a51943e26f5e6b60d7599420285158fc65eaf00b1"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifybot.go"},"region":{"startLine":1237}}}],"partialFingerprints":{"codehealthFindingId/v1":"927f4a8d828d798b79e9eeaf83ff79c6b8557d79b03351191da17357bdd37ba0"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1733}}}],"partialFingerprints":{"codehealthFindingId/v1":"12ca1096b2a18937e65fc4b6e15a90bac00fbc428e67594d83fb8420185e48f6"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/auth/service.go"},"region":{"startLine":1737}}}],"partialFingerprints":{"codehealthFindingId/v1":"993de92228327ce5bd76e95a82d34e98e60681da2e0c73c5968c65919b17d669"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/ai/provider_http.go"},"region":{"startLine":480}}}],"partialFingerprints":{"codehealthFindingId/v1":"a045f9f9c335af7c7df4362ca6014358f5ce05b427f30de9699d6bbf7ba585f3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":752}}}],"partialFingerprints":{"codehealthFindingId/v1":"e5aaaf1ee9350ce486d43ab03ba4b0ccfe297e5f0c5480757f7ee29e3bd5a81b"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":771}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8067fa0cb0766916ce56f044e1fb5496c857f3741749fa5c951e360cab706c5"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3869}}}],"partialFingerprints":{"codehealthFindingId/v1":"fa0b7c13bd4bb369fd45302efe6307370948e74d5c6513abee62629f97568deb"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/service.go"},"region":{"startLine":3874}}}],"partialFingerprints":{"codehealthFindingId/v1":"39a11372e7fe9661a35a4a275e49c8e26b36bb7f2686399ab7ad4e042672253c"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := s.read.pool.QueryRow(ctx, \u0060 \u0060, g.Unlock, g.Actor).Scan(\u0026reason); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview.go"},"region":{"startLine":264}}}],"partialFingerprints":{"codehealthFindingId/v1":"b1e4085a480d327349e70d7a27bd7032dfc8f6cdba1365dadcd2ecb06ed38b3e"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060raw, _ := io.ReadAll(io.LimitReader(resp.Body, 4\u003C\u003C10))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060raw\u0060 as if the call succeeded. When \u0060io.ReadAll\u0060 fails, \u0060raw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060raw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview.go"},"region":{"startLine":414}}}],"partialFingerprints":{"codehealthFindingId/v1":"ee2ec4c48d69c65a49b718ee71a4cf273ca143736fbf74e9491218d7974b3242"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeDate, _ := parseInt64(r.URL.Query().Get(\u0022before_date\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeDate\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeDate\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeDate\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview.go"},"region":{"startLine":441}}}],"partialFingerprints":{"codehealthFindingId/v1":"48cc49dce37327ce3c64a8a2e0189e68ac526567b8334ad0aaf28848bc3674c4"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeID, _ := parseInt(r.URL.Query().Get(\u0022before_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeID\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060beforeID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview.go"},"region":{"startLine":442}}}],"partialFingerprints":{"codehealthFindingId/v1":"e9915062bfd70141fdb8590ada81445045906206347a76f779f4233dffb90c47"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := json.Unmarshal(raw, \u0026fwd); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/privateview_store.go"},"region":{"startLine":667}}}],"partialFingerprints":{"codehealthFindingId/v1":"7406bc6719ba51b46986506b70cc5632930f4ef74ed4e6046c59b12a75cd9d90"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060raw, _ := io.ReadAll(io.LimitReader(resp.Body, 4\u003C\u003C20))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060raw\u0060 as if the call succeeded. When \u0060io.ReadAll\u0060 fails, \u0060raw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060raw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/report_evidence.go"},"region":{"startLine":53}}}],"partialFingerprints":{"codehealthFindingId/v1":"d1122b402ea0728fd40a4c118340cf6f7c8610ab9eccc49d7f3a8986d5131497"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/report_evidence.go"},"region":{"startLine":236}}}],"partialFingerprints":{"codehealthFindingId/v1":"0bdfaf389571954d94df3edf67568e10fe2c68abbd2f8697ff8fb30917086155"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeID, _ := parseInt64(r.URL.Query().Get(\u0022before_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeID\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":511}}}],"partialFingerprints":{"codehealthFindingId/v1":"7563acc9dcd5d7367455760adb471cf048f6edc5c4a5a117976b01f7e33afdd7"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060limit, _ := parseInt(r.URL.Query().Get(\u0022limit\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060limit\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060limit\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060limit\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":512}}}],"partialFingerprints":{"codehealthFindingId/v1":"d6fc1828979334afed28f142b71d8a0bd136d14a34bdf85cb0d426b7b0291d8a"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeID, _ := parseInt64(r.URL.Query().Get(\u0022before_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeID\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":724}}}],"partialFingerprints":{"codehealthFindingId/v1":"36b37b1e2f04773c870fcf9d358a219d45c28bfb779825964858b9051265ebd1"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeActiveUS, _ := parseInt64(r.URL.Query().Get(\u0022before_active_us\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeActiveUS\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeActiveUS\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeActiveUS\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":725}}}],"partialFingerprints":{"codehealthFindingId/v1":"9f14a086964aa1af7dddb6b68589aa3259c271df7b534b7f02dca7e6a47f7939"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060limit, _ := parseInt(r.URL.Query().Get(\u0022limit\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060limit\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060limit\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060limit\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":726}}}],"partialFingerprints":{"codehealthFindingId/v1":"3a143c67779d84ef5095976b43bd5940d7ac50d232e169937c52861cf3d0d4d3"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060offset, _ := parseInt(r.URL.Query().Get(\u0022offset\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060offset\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060offset\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060offset\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":775}}}],"partialFingerprints":{"codehealthFindingId/v1":"6a56db1fa8bf1c5bba638c8fcf36f0e323f41f0cc97152af6e25684c9746955a"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060limit, _ := parseInt(r.URL.Query().Get(\u0022limit\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060limit\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060limit\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060limit\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":776}}}],"partialFingerprints":{"codehealthFindingId/v1":"6f5294482caad2c8bf25702c33137c5ae756af0a37461d5ef3a685bb16bcbeb0"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeID, _ := parseInt64(r.URL.Query().Get(\u0022before_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeID\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":802}}}],"partialFingerprints":{"codehealthFindingId/v1":"7ee52d6a1d71bbfb8f9041f9dff56424a506979959798a064cb9a4c86b0c0905"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060limit, _ := parseInt(r.URL.Query().Get(\u0022limit\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060limit\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060limit\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060limit\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":803}}}],"partialFingerprints":{"codehealthFindingId/v1":"97d91d41cd637b7a48879464964eca845c44bc0b77b5f797a8089118d451ea24"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeID, _ := parseInt64(r.URL.Query().Get(\u0022before_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeID\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1016}}}],"partialFingerprints":{"codehealthFindingId/v1":"2a86379bcf436211df2085fe1084f239411f3243d37a0b78eed5e58d2b027cff"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060limit, _ := parseInt(r.URL.Query().Get(\u0022limit\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060limit\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060limit\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060limit\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1017}}}],"partialFingerprints":{"codehealthFindingId/v1":"1703e536cbf30b211725167fed0b3ea13089c7ca247132f6dfd0c155dd44cbde"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeID, _ := parseInt64(r.URL.Query().Get(\u0022before_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeID\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1198}}}],"partialFingerprints":{"codehealthFindingId/v1":"4595dbdc3ce6695c61166048e7ad0d081e5f50026059799300a2c2f61f8bb5ae"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeUpdatedUS, _ := parseInt64(r.URL.Query().Get(\u0022before_updated_us\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeUpdatedUS\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeUpdatedUS\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeUpdatedUS\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1199}}}],"partialFingerprints":{"codehealthFindingId/v1":"99e7c4f976057297d43defda1c0df73769eca6c16ca2cac870614d5650e5a855"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060limit, _ := parseInt(r.URL.Query().Get(\u0022limit\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060limit\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060limit\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060limit\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1200}}}],"partialFingerprints":{"codehealthFindingId/v1":"aa494b1c43952046b0614ce777430e90e6b2c1289ebb2f25c6d1625e353b94e5"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060owner, _ := parseInt64(q.Get(\u0022owner_user_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060owner\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060owner\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060owner\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1272}}}],"partialFingerprints":{"codehealthFindingId/v1":"c411051fef39e0e131eb9ccd87df76ba30fe04a039ab09eba154c00192e44841"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060peer, _ := parseInt64(q.Get(\u0022peer_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060peer\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060peer\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060peer\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1273}}}],"partialFingerprints":{"codehealthFindingId/v1":"7e1a0aab958d735ca06098f1ca3235b3080b67a67ce044a64ec17306d0f2bca8"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeDate, _ := parseInt64(q.Get(\u0022before_date\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeDate\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeDate\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeDate\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1274}}}],"partialFingerprints":{"codehealthFindingId/v1":"6c95eaaba0a25ba9a97e4f03d025add27456fa5d4308f3d1a16de4ad19f3ce6b"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeID, _ := parseInt(q.Get(\u0022before_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeID\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060beforeID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1275}}}],"partialFingerprints":{"codehealthFindingId/v1":"8de22ab0527678fcc85fba7544b2999fa878a85f0bafe7bbc3d566005e830e6b"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060limit, _ := parseInt(q.Get(\u0022limit\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060limit\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060limit\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060limit\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1276}}}],"partialFingerprints":{"codehealthFindingId/v1":"6df7ecfa6c1ab90113f2f28e1de06b70e937ee66916d9b5e7fc4701e9308335c"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060channelID, _ := parseInt64(q.Get(\u0022channel_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060channelID\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060channelID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060channelID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1321}}}],"partialFingerprints":{"codehealthFindingId/v1":"1a47aa6ae6be8174ab1e6dd9b735be4dcedab897be26f114fb48f7bf278b664e"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeDate, _ := parseInt64(q.Get(\u0022before_date\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeDate\u0060 as if the call succeeded. When \u0060parseInt64\u0060 fails, \u0060beforeDate\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeDate\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1322}}}],"partialFingerprints":{"codehealthFindingId/v1":"dc7ffbedd6d237a0cdc6758deb23bb4ecc1a4167df05817128b3e59045f4c368"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060beforeID, _ := parseInt(q.Get(\u0022before_id\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060beforeID\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060beforeID\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060beforeID\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1323}}}],"partialFingerprints":{"codehealthFindingId/v1":"df36c514cd8581af2138350d3bc9ba0b835c33ba545411ca290eee3cc14f4e72"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060limit, _ := parseInt(q.Get(\u0022limit\u0022))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060limit\u0060 as if the call succeeded. When \u0060parseInt\u0060 fails, \u0060limit\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060limit\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":1324}}}],"partialFingerprints":{"codehealthFindingId/v1":"e262d6e2e83767115138bc7d6d7db7d3a403187e446d6cc9483922b33b644e49"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060raw, _ := io.ReadAll(io.LimitReader(resp.Body, 1\u003C\u003C20))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060raw\u0060 as if the call succeeded. When \u0060io.ReadAll\u0060 fails, \u0060raw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060raw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2846}}}],"partialFingerprints":{"codehealthFindingId/v1":"d373a5fa20fccc699a7f16428e4377643f48552adb1cd608f05b6b5dbf3f9bf6"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060raw, _ := io.ReadAll(io.LimitReader(resp.Body, 1\u003C\u003C20))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060raw\u0060 as if the call succeeded. When \u0060io.ReadAll\u0060 fails, \u0060raw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060raw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2869}}}],"partialFingerprints":{"codehealthFindingId/v1":"402b1aac4b4d0672ecf3c32c88df48300de8d4313784108265d0e81b0697b441"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060raw, _ := io.ReadAll(io.LimitReader(resp.Body, 1\u003C\u003C20))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060raw\u0060 as if the call succeeded. When \u0060io.ReadAll\u0060 fails, \u0060raw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060raw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2905}}}],"partialFingerprints":{"codehealthFindingId/v1":"ea8879928c9064dbb5aac1191133fd7a24790d90ca545c76deeea0650ac32a97"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060raw, _ := io.ReadAll(io.LimitReader(resp.Body, 1\u003C\u003C20))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060raw\u0060 as if the call succeeded. When \u0060io.ReadAll\u0060 fails, \u0060raw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060raw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/server.go"},"region":{"startLine":2950}}}],"partialFingerprints":{"codehealthFindingId/v1":"d68ac92a91cda5233aa063a26da07f752a1685a8693ba2ef03e96d7f58a5e9d3"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/serverstorage.go"},"region":{"startLine":302}}}],"partialFingerprints":{"codehealthFindingId/v1":"408ec2bf22ee75d39cedaafad9f8e35abbec1f6bd8fb4378738c16af3d8ac531"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060raw, _ := io.ReadAll(io.LimitReader(resp.Body, 1\u003C\u003C20))\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060raw\u0060 as if the call succeeded. When \u0060io.ReadAll\u0060 fails, \u0060raw\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060raw\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/star_gift_catalog.go"},"region":{"startLine":300}}}],"partialFingerprints":{"codehealthFindingId/v1":"29ac7bd35b49279ab8e91b93d24f8ef19b012166ba62a346c362d5fcc5e0ff1d"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (an error-returning call as a bare statement): \u0060run()\u0060 returns an error, and the statement drops it: when \u0060run\u0060 fails nothing records it and the code after it runs as if it had succeeded. Check it (\u0060if err := run(); err != nil { \u2026 }\u0060) and return or log it with what was being done, or assign it to \u0060_\u0060 with a comment saying why the failure cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":2138}}}],"partialFingerprints":{"codehealthFindingId/v1":"f1d63098b48f908c7fb9e08a443be572ad7008f720484211b69cf28fdcffec40"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (an error-returning call as a bare statement): \u0060run()\u0060 returns an error, and the statement drops it: when \u0060run\u0060 fails nothing records it and the code after it runs as if it had succeeded. Check it (\u0060if err := run(); err != nil { \u2026 }\u0060) and return or log it with what was being done, or assign it to \u0060_\u0060 with a comment saying why the failure cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/main.go"},"region":{"startLine":2146}}}],"partialFingerprints":{"codehealthFindingId/v1":"ebf77fbd6a9b36d4c5298b0bc63992c1845ebdce3d18bf5eb6838e3adb6e0dc1"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := unix.Getrusage(unix.RUSAGE_SELF, \u0026usage); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/process_cpu_unix.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"8995997b8bcef936a9f4c886ccc36fe53810aa03fa332139ecac2c2df6bdeb88"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/process_cpu_windows.go"},"region":{"startLine":9}}}],"partialFingerprints":{"codehealthFindingId/v1":"31f1690133951d81260f9af6615a6a6350605541b58c9c404b0d331ca689a90f"}},{"ruleId":"X3","level":"warning","message":{"text":"Swallowed exception (caught, then discarded): \u0060if err := windows.GetProcessTimes(handle, \u0026creation, \u0026exit, \u0026kernel, \u0026user); err != nil\u0060 takes every exception and records none of it \u2014 the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv/process_cpu_windows.go"},"region":{"startLine":13}}}],"partialFingerprints":{"codehealthFindingId/v1":"57a9919fd04cc1598e7390acd8c402cc04bd8c7784d53b20da4977e071b3237e"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060port, _ := strconv.Atoi(portStr)\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060port\u0060 as if the call succeeded. When \u0060strconv.Atoi\u0060 fails, \u0060port\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060port\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botdemo/main.go"},"region":{"startLine":167}}}],"partialFingerprints":{"codehealthFindingId/v1":"9145a264cb8d69a145b9be404aaa2801dfa1f82c7d0151156b1680653abba19c"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060rid, _ := randInt64()\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060rid\u0060 as if the call succeeded. When \u0060randInt64\u0060 fails, \u0060rid\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060rid\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botdemo/main.go"},"region":{"startLine":327}}}],"partialFingerprints":{"codehealthFindingId/v1":"5a98bcd7941f12b0568e534c15956a0f01f6296efc02ead131f0d2e97c9cd25f"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060rid, _ := randInt64()\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060rid\u0060 as if the call succeeded. When \u0060randInt64\u0060 fails, \u0060rid\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060rid\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botdemo/main.go"},"region":{"startLine":360}}}],"partialFingerprints":{"codehealthFindingId/v1":"7d46de6acb63b43c9a9c56c5d8e1abf847667d60e8da9baa9c1bd2eeb850b305"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060rid, _ := randInt64()\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060rid\u0060 as if the call succeeded. When \u0060randInt64\u0060 fails, \u0060rid\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060rid\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"4f8dca769da66ac8c0efb17c52c5aa30c3726c66f02fab1c2261622ade1d4f28"}},{"ruleId":"X3","level":"warning","message":{"text":"Discarded error (assigned to \u0060_\u0060, then its result used): \u0060rid, _ := randInt64()\u0060 writes the call\u0027s error to \u0060_\u0060 and then uses \u0060rid\u0060 as if the call succeeded. When \u0060randInt64\u0060 fails, \u0060rid\u0060 is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using \u0060rid\u0060 (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/bots/botcheck/main.go"},"region":{"startLine":283}}}],"partialFingerprints":{"codehealthFindingId/v1":"15ed2415b3dc9adaaffe632a74eaabbc4d0f4ac40d5e57b344d366b9d8423436"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060Warn\u0060 at line 95 is handed a message assembled at the call \u2014 \u0060fmt.Sprintf\u0060 with values, or a string concatenated with a value \u2014 so the logger receives one finished string: the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Pass a constant message and the values as attributes instead: \u0060slog.Warn(\u0022order moved\u0022, \u0022order_id\u0022, orderID, \u0022status\u0022, status)\u0060 with log/slog, \u0060logger.Warn(\u0022order moved\u0022, zap.String(\u0022order_id\u0022, orderID))\u0060 with zap, \u0060log.WithFields(log.Fields{\u0022order_id\u0022: orderID}).Warn(\u0022order moved\u0022)\u0060 with logrus, or \u0060log.Info().Str(\u0022order_id\u0022, orderID).Msg(\u0022order moved\u0022)\u0060 with zerolog."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_polls.go"},"region":{"startLine":95}}}],"partialFingerprints":{"codehealthFindingId/v1":"3967b93825134053c4f4594d5c801505700c3ea5d9da4c8ac18869a6985ff716"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060Error\u0060 at line 1594 is handed a message assembled at the call \u2014 \u0060fmt.Sprintf\u0060 with values, or a string concatenated with a value \u2014 so the logger receives one finished string: the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Pass a constant message and the values as attributes instead: \u0060slog.Error(\u0022order moved\u0022, \u0022order_id\u0022, orderID, \u0022status\u0022, status)\u0060 with log/slog, \u0060logger.Error(\u0022order moved\u0022, zap.String(\u0022order_id\u0022, orderID))\u0060 with zap, \u0060log.WithFields(log.Fields{\u0022order_id\u0022: orderID}).Error(\u0022order moved\u0022)\u0060 with logrus, or \u0060log.Info().Str(\u0022order_id\u0022, orderID).Msg(\u0022order moved\u0022)\u0060 with zerolog."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1594}}}],"partialFingerprints":{"codehealthFindingId/v1":"da1cc35aaf8025208c7773fe6569f1324a6aed903add8e6f51da9cb7a0f85de7"}},{"ruleId":"X4","level":"note","message":{"text":"Interpolated log message defeats structured logging: \u0060Error\u0060 at line 1423 is handed a message assembled at the call \u2014 \u0060fmt.Sprintf\u0060 with values, or a string concatenated with a value \u2014 so the logger receives one finished string: the values in it cannot be queried, filtered or aggregated as fields, and every occurrence reads as a different message. Pass a constant message and the values as attributes instead: \u0060slog.Error(\u0022order moved\u0022, \u0022order_id\u0022, orderID, \u0022status\u0022, status)\u0060 with log/slog, \u0060logger.Error(\u0022order moved\u0022, zap.String(\u0022order_id\u0022, orderID))\u0060 with zap, \u0060log.WithFields(log.Fields{\u0022order_id\u0022: orderID}).Error(\u0022order moved\u0022)\u0060 with logrus, or \u0060log.Info().Str(\u0022order_id\u0022, orderID).Msg(\u0022order moved\u0022)\u0060 with zerolog."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifybot.go"},"region":{"startLine":1423}}}],"partialFingerprints":{"codehealthFindingId/v1":"f96f2b86f5a8fc9022bed7f6be54db69c999bbbd23d110641a5301072a219009"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060botVerifierMarkCount\u0060 turns a non-nil \u0060err\u0060 into \u0060return \u0022unknown\u0022\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/admin/botverification.go"},"region":{"startLine":752}}}],"partialFingerprints":{"codehealthFindingId/v1":"fe7b122cd9dee8115a4cc70d6bef74cc1f23e16fd2061c32472aba533d546d02"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060verifierMarkDescription\u0060 turns a non-nil \u0060err\u0060 into \u0060return \u0022\u0022\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":512}}}],"partialFingerprints":{"codehealthFindingId/v1":"7535a15177258db1ce2c2234cdfe42177ddc655cd16cf7da1efd84101a792dea"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060verifierDraftInt\u0060 turns a non-nil \u0060err\u0060 into \u0060return 0\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifierbot.go"},"region":{"startLine":1425}}}],"partialFingerprints":{"codehealthFindingId/v1":"81058a60291cecb571613e99f9931b5bffa3803472732eeff7ef2affc8ea1618"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060verifyDraftInt\u0060 turns a non-nil \u0060err\u0060 into \u0060return 0\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/bots/verifybot.go"},"region":{"startLine":1237}}}],"partialFingerprints":{"codehealthFindingId/v1":"300c95d66721a65cc864920ceca29c5147a34bdbd3d8f1cc3259d16491e69722"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060docIDFromName\u0060 turns a non-nil \u0060err\u0060 into \u0060return 0\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/app/files/seed.go"},"region":{"startLine":626}}}],"partialFingerprints":{"codehealthFindingId/v1":"c24a9c9179f50930a7036f7e4d3c16ad65fa55c438aacfb117b68312ac4e0802"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060sample\u0060 turns a non-nil \u0060err\u0060 into \u0060return 0\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/hoststats/cpu_unix.go"},"region":{"startLine":26}}}],"partialFingerprints":{"codehealthFindingId/v1":"8a5ba8bdd0da8e33abe0987a460b54dbc9a2708f37552dc6e832f040354f9947"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060Host\u0060 turns a non-nil \u0060err\u0060 into \u0060return \u0022telesrv.net\u0022\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/links/links.go"},"region":{"startLine":260}}}],"partialFingerprints":{"codehealthFindingId/v1":"a66f5dc8789edf3104a95f9f03b165fec42d0d8102e7ff1dbdb0c1741265369a"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060decodeResponse\u0060 turns a non-nil \u0060err\u0060 into \u0060return responseBody{}\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/otpdelivery/webhook/sender.go"},"region":{"startLine":189}}}],"partialFingerprints":{"codehealthFindingId/v1":"629ab26b330d98579dc3933071d9e981c479547ef6df1ea2068e9b26d6ed6815"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060EnvValue\u0060 turns a non-nil \u0060err\u0060 into \u0060return \u0022\u0022\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/procctl/supervisor.go"},"region":{"startLine":38}}}],"partialFingerprints":{"codehealthFindingId/v1":"cad92135e823a66ca1e66d99c1e4597c817393123b98fa26748ce6b1906e698c"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060randomSSRC\u0060 turns a non-nil \u0060err\u0060 into \u0060return 1\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/phone_group_call_rtmp.go"},"region":{"startLine":184}}}],"partialFingerprints":{"codehealthFindingId/v1":"38839ad6e7268b5369667c925599a83f45ce2ee07529047dd1f8294186af39de"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060passkeyDisplayName\u0060 turns a non-nil \u0060err\u0060 into \u0060return \u0022\u0022\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/account.go"},"region":{"startLine":925}}}],"partialFingerprints":{"codehealthFindingId/v1":"5000cc5ccb06898e4a15e23db1998fd4ccdc2a00b3dfe43b78b6944d17053cc7"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060peerBotVerificationIcon\u0060 turns a non-nil \u0060err\u0060 into \u0060return 0\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/bot_verification_projection.go"},"region":{"startLine":214}}}],"partialFingerprints":{"codehealthFindingId/v1":"fb94af456371bfc1ea2b6a2719a937be7983232b759d9c1e1594aea75aaec3ca"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060loadChannelFullBotInfo\u0060 turns a non-nil \u0060err\u0060 into \u0060return channelFullBotInfoResult{}\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/channel_full_bot_cache.go"},"region":{"startLine":98}}}],"partialFingerprints":{"codehealthFindingId/v1":"bdc03f5f3c06fed2e1d78fe6f16b9dafea77e312173d65afdfccdc50a0e0464a"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060deviceEncryptedQts\u0060 turns a non-nil \u0060err\u0060 into \u0060return 0\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/encrypted_messages.go"},"region":{"startLine":140}}}],"partialFingerprints":{"codehealthFindingId/v1":"7c8bbdabf9789d83aeb5d2acc5003fc18500ae7af588df93e406afa6f62b1bde"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060attachMenuUsers\u0060 turns a non-nil \u0060err\u0060 into \u0060return []tg.UserClass{}\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_attach_menu.go"},"region":{"startLine":220}}}],"partialFingerprints":{"codehealthFindingId/v1":"eec16361b916d979307a1b150fa27a5872d85016029ded625516cd5d28bac9a7"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060chatsForDrafts\u0060 turns a non-nil \u0060err\u0060 into \u0060return []tg.ChatClass{}\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_dialogs.go"},"region":{"startLine":332}}}],"partialFingerprints":{"codehealthFindingId/v1":"8c09901d8cb07c8f77806419d6e93db04009922eef0bf46bef847a9e1ad8fce0"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060channelOnlineCount\u0060 turns a non-nil \u0060err\u0060 into \u0060return 1\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/messages_helpers.go"},"region":{"startLine":155}}}],"partialFingerprints":{"codehealthFindingId/v1":"0615f8538d0c0e7cb37bceb1d3d8cb43a6b3c5e87e28d8d9b4d7e8ce8231d34c"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060channelPostAuthorName\u0060 turns a non-nil \u0060err\u0060 into \u0060return \u0022\u0022\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/send_media.go"},"region":{"startLine":1208}}}],"partialFingerprints":{"codehealthFindingId/v1":"d8c4c497224e10747b93054c07b3080c435aff4b74e582e5f7321762e5d95387"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060storyMessageForwardPage\u0060 turns a non-nil \u0060err\u0060 into \u0060return domain.StoryMessageForwardList{}\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/rpc/stories.go"},"region":{"startLine":3307}}}],"partialFingerprints":{"codehealthFindingId/v1":"35834d50d6b78fee0f53a358495e9b28c44435080f55b0fc8095dd0ab9f8823c"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default on error: \u0060SetChannelDialogPinned\u0060 turns a non-nil \u0060err\u0060 into \u0060return false, 0, nil\u0060 \u2014 a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the \u0060if\u0060 or in the doc comment, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"internal/store/memory/channel_dialogs.go"},"region":{"startLine":306}}}],"partialFingerprints":{"codehealthFindingId/v1":"a4fd0b1889a9ea16804bdc2e3cab93bbc71c624b8c4879f305fa34c0193e0d16"}},{"ruleId":"X7","level":"note","message":{"text":"Silent fallback default in catch: \u0060safeHttpURL\u0060 swallows every exception into \u0060return \u0022\u0022\u0060 \u2014 a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing."},"locations":[{"physicalLocation":{"artifactLocation":{"uri":"cmd/telesrv-admin/web/src/lib/format.ts"},"region":{"startLine":72}}}],"partialFingerprints":{"codehealthFindingId/v1":"dd441ae44d31259326c42f41cf40d84cc3d68424dae2fa30ef0e23dc74bec7d7"}}],"taxonomies":[{"name":"CWE","guid":"c3a2b1d0-7f3e-4b2a-9c1d-5e6f7a8b9c0d","organization":"MITRE","informationUri":"https://cwe.mitre.org/","isComprehensive":false,"shortDescription":{"text":"The MITRE Common Weakness Enumeration (CWE)."},"taxa":[{"id":"CWE-1004","guid":"872195c9-bb07-cf51-8a32-865f4bb753ca","name":"Sensitive Cookie Without \u0027HttpOnly\u0027 Flag","shortDescription":{"text":"Sensitive Cookie Without \u0027HttpOnly\u0027 Flag"},"helpUri":"https://cwe.mitre.org/data/definitions/1004.html"},{"id":"CWE-1032","guid":"5f21e517-68aa-a650-9a25-5771ef024637","name":"OWASP Top Ten \u2014 Security Misconfiguration category","shortDescription":{"text":"OWASP Top Ten \u2014 Security Misconfiguration category"},"helpUri":"https://cwe.mitre.org/data/definitions/1032.html"},{"id":"CWE-1357","guid":"e4d2e772-757e-0a5c-bd7d-77052949d866","name":"Reliance on Insufficiently Trustworthy Component","shortDescription":{"text":"Reliance on Insufficiently Trustworthy Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1357.html"},{"id":"CWE-1395","guid":"800e09e7-c11a-8654-9fa6-86f398995fed","name":"Dependency on Vulnerable Third-Party Component","shortDescription":{"text":"Dependency on Vulnerable Third-Party Component"},"helpUri":"https://cwe.mitre.org/data/definitions/1395.html"},{"id":"CWE-16","guid":"659db3ea-affc-8453-8add-c1218fbfcb92","name":"Configuration","shortDescription":{"text":"Configuration"},"helpUri":"https://cwe.mitre.org/data/definitions/16.html"},{"id":"CWE-200","guid":"b0ce3b1d-7a29-fe50-8aab-9aba899d2988","name":"Exposure of Sensitive Information to an Unauthorized Actor","shortDescription":{"text":"Exposure of Sensitive Information to an Unauthorized Actor"},"helpUri":"https://cwe.mitre.org/data/definitions/200.html"},{"id":"CWE-242","guid":"5c147e5c-be37-b051-9928-764ef5a8f3d3","name":"CWE-242","shortDescription":{"text":"CWE-242"},"helpUri":"https://cwe.mitre.org/data/definitions/242.html"},{"id":"CWE-248","guid":"64b58946-d244-a556-a48a-f82fcd4f4186","name":"Uncaught Exception","shortDescription":{"text":"Uncaught Exception"},"helpUri":"https://cwe.mitre.org/data/definitions/248.html"},{"id":"CWE-259","guid":"ae9ad959-fbb6-9d5e-892d-3dca66da0b69","name":"Use of Hard-coded Password","shortDescription":{"text":"Use of Hard-coded Password"},"helpUri":"https://cwe.mitre.org/data/definitions/259.html"},{"id":"CWE-312","guid":"96724ece-b0b2-a45c-83f9-0869fa3f6bea","name":"Cleartext Storage of Sensitive Information","shortDescription":{"text":"Cleartext Storage of Sensitive Information"},"helpUri":"https://cwe.mitre.org/data/definitions/312.html"},{"id":"CWE-328","guid":"f0ffc869-97c3-dc5c-8825-be1159f1fc5f","name":"Reversible One-Way Hash","shortDescription":{"text":"Reversible One-Way Hash"},"helpUri":"https://cwe.mitre.org/data/definitions/328.html"},{"id":"CWE-338","guid":"e89b7604-c3f7-8b53-bc8c-4d4718c28617","name":"Use of Cryptographically Weak Pseudo-Random Number Generator(PRNG)","shortDescription":{"text":"Use of Cryptographically Weak Pseudo-Random Number Generator(PRNG)"},"helpUri":"https://cwe.mitre.org/data/definitions/338.html"},{"id":"CWE-353","guid":"09d7e902-d4ee-f05d-ae6c-0a1554d0c18f","name":"Missing Support for Integrity Check","shortDescription":{"text":"Missing Support for Integrity Check"},"helpUri":"https://cwe.mitre.org/data/definitions/353.html"},{"id":"CWE-359","guid":"b7dfe5b0-0351-645b-a311-b936102c2929","name":"Exposure of Private Personal Information to an Unauthorized Actor","shortDescription":{"text":"Exposure of Private Personal Information to an Unauthorized Actor"},"helpUri":"https://cwe.mitre.org/data/definitions/359.html"},{"id":"CWE-391","guid":"d9ef5687-8d79-9b51-b509-b83411fbcdc3","name":"Unchecked Error Condition","shortDescription":{"text":"Unchecked Error Condition"},"helpUri":"https://cwe.mitre.org/data/definitions/391.html"},{"id":"CWE-400","guid":"ca529a89-676d-8857-aac1-84359c77bb6c","name":"CWE-400","shortDescription":{"text":"CWE-400"},"helpUri":"https://cwe.mitre.org/data/definitions/400.html"},{"id":"CWE-506","guid":"401d6455-56e3-0552-9a39-f77461673e3f","name":"Embedded Malicious Code","shortDescription":{"text":"Embedded Malicious Code"},"helpUri":"https://cwe.mitre.org/data/definitions/506.html"},{"id":"CWE-614","guid":"faa8a6a5-7e9d-5d5e-afc9-020ff49d250a","name":"Sensitive Cookie in HTTPS Session Without \u0027Secure\u0027 Attribute","shortDescription":{"text":"Sensitive Cookie in HTTPS Session Without \u0027Secure\u0027 Attribute"},"helpUri":"https://cwe.mitre.org/data/definitions/614.html"},{"id":"CWE-665","guid":"fe279ff9-a979-f952-9df9-3f7d05af85d8","name":"CWE-665","shortDescription":{"text":"CWE-665"},"helpUri":"https://cwe.mitre.org/data/definitions/665.html"},{"id":"CWE-703","guid":"fa730aa9-95e4-845e-83fa-8169f2cf339e","name":"Improper Check or Handling of Exceptional Conditions","shortDescription":{"text":"Improper Check or Handling of Exceptional Conditions"},"helpUri":"https://cwe.mitre.org/data/definitions/703.html"},{"id":"CWE-704","guid":"50bd74b4-a921-5159-8671-99fd7e78c810","name":"CWE-704","shortDescription":{"text":"CWE-704"},"helpUri":"https://cwe.mitre.org/data/definitions/704.html"},{"id":"CWE-732","guid":"1da27e8f-b330-7650-ab63-bd61953eae5d","name":"Incorrect Permission Assignment for Critical Resource","shortDescription":{"text":"Incorrect Permission Assignment for Critical Resource"},"helpUri":"https://cwe.mitre.org/data/definitions/732.html"},{"id":"CWE-77","guid":"332c8ade-6612-9f56-a06b-d8d90b1a8750","name":"Improper Neutralization of Special Elements used in a Command (\u0027Command Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in a Command (\u0027Command Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/77.html"},{"id":"CWE-78","guid":"2e31ceaf-c7ae-2e5e-9661-cfb1362789cf","name":"Improper Neutralization of Special Elements used in an OS Command (\u0027OS Command Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in an OS Command (\u0027OS Command Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/78.html"},{"id":"CWE-79","guid":"fd45580b-e8c4-fc5e-8c2f-aa8fab0b4dbf","name":"Improper Neutralization of Input During Web Page Generation (\u0027Cross-site Scripting\u0027)","shortDescription":{"text":"Improper Neutralization of Input During Web Page Generation (\u0027Cross-site Scripting\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/79.html"},{"id":"CWE-798","guid":"5e8f057d-fee3-995a-a0cb-9fc5b0d174d1","name":"Use of Hard-coded Credentials","shortDescription":{"text":"Use of Hard-coded Credentials"},"helpUri":"https://cwe.mitre.org/data/definitions/798.html"},{"id":"CWE-89","guid":"6d08fdad-37eb-c150-bbf0-d7d946863407","name":"Improper Neutralization of Special Elements used in an SQL Command (\u0027SQL Injection\u0027)","shortDescription":{"text":"Improper Neutralization of Special Elements used in an SQL Command (\u0027SQL Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/89.html"},{"id":"CWE-908","guid":"ca1da1d1-5eaf-e95b-adbb-4eb2bc10b9fc","name":"CWE-908","shortDescription":{"text":"CWE-908"},"helpUri":"https://cwe.mitre.org/data/definitions/908.html"},{"id":"CWE-937","guid":"16f316ae-415c-b354-a59b-1f7905f756e9","name":"Using Components with Known Vulnerabilities","shortDescription":{"text":"Using Components with Known Vulnerabilities"},"helpUri":"https://cwe.mitre.org/data/definitions/937.html"},{"id":"CWE-94","guid":"75e7f50c-6c2f-dd52-bf40-bf6c52b861fd","name":"Improper Control of Generation of Code (\u0027Code Injection\u0027)","shortDescription":{"text":"Improper Control of Generation of Code (\u0027Code Injection\u0027)"},"helpUri":"https://cwe.mitre.org/data/definitions/94.html"}]},{"name":"OWASP Top 10","guid":"7d1f0c2e-4b6a-4e39-9a51-0b2e8c3d5f61","version":"2025","organization":"OWASP Foundation","informationUri":"https://top10.owasp.org/2025/","isComprehensive":false,"shortDescription":{"text":"The OWASP Top 10:2025 web application security risks."},"taxa":[{"id":"A01:2025","guid":"df693558-c822-0452-8f7b-4d53cb6bcc59","name":"Broken Access Control","shortDescription":{"text":"Broken Access Control"},"helpUri":"https://top10.owasp.org/2025/A01_2025-Broken_Access_Control/"},{"id":"A02:2025","guid":"668dee9e-41bc-6354-97d0-fdf8f40c50c1","name":"Security Misconfiguration","shortDescription":{"text":"Security Misconfiguration"},"helpUri":"https://top10.owasp.org/2025/A02_2025-Security_Misconfiguration/"},{"id":"A03:2025","guid":"168e227c-7735-2e57-bc6e-997affe644c5","name":"Software Supply Chain Failures","shortDescription":{"text":"Software Supply Chain Failures"},"helpUri":"https://top10.owasp.org/2025/A03_2025-Software_Supply_Chain_Failures/"},{"id":"A04:2025","guid":"6a9f5bfd-1a56-6453-beec-a7eff0ba3007","name":"Cryptographic Failures","shortDescription":{"text":"Cryptographic Failures"},"helpUri":"https://top10.owasp.org/2025/A04_2025-Cryptographic_Failures/"},{"id":"A05:2025","guid":"87e86033-3231-8458-8e4a-5cb82743553a","name":"Injection","shortDescription":{"text":"Injection"},"helpUri":"https://top10.owasp.org/2025/A05_2025-Injection/"},{"id":"A06:2025","guid":"491554d7-b8e4-9652-91a9-53700dc92ece","name":"Insecure Design","shortDescription":{"text":"Insecure Design"},"helpUri":"https://top10.owasp.org/2025/A06_2025-Insecure_Design/"},{"id":"A07:2025","guid":"334ddd78-539d-d35c-83dd-253647eb7eaf","name":"Authentication Failures","shortDescription":{"text":"Authentication Failures"},"helpUri":"https://top10.owasp.org/2025/A07_2025-Authentication_Failures/"},{"id":"A08:2025","guid":"84b0c297-710e-9a5f-9335-936ecb260c36","name":"Software or Data Integrity Failures","shortDescription":{"text":"Software or Data Integrity Failures"},"helpUri":"https://top10.owasp.org/2025/A08_2025-Software_or_Data_Integrity_Failures/"},{"id":"A10:2025","guid":"9ca3ab55-ca61-fd5e-b9ab-3dad2efa59d0","name":"Mishandling of Exceptional Conditions","shortDescription":{"text":"Mishandling of Exceptional Conditions"},"helpUri":"https://top10.owasp.org/2025/A10_2025-Mishandling_of_Exceptional_Conditions/"}]}],"properties":{"codehealthPublication":{"public":true,"notice":"This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings \u2014 which rule fired, in which file, on which line, and how to fix it \u2014 are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.","securityFindingsRedacted":52,"secretScannerRunsExcluded":0}},"redactionTokens":["A security finding was recorded here. Its details are withheld on the public artifact \u2014 ask the repository owner for the full report."]}]}