Conversation
…n up schedule encode Extract shared schedule/calendar decode logic into decodeScheduleCalendarValue in asn1.ts, replacing ~440 lines of duplicated if-else chains across decodeReadAccessResult, ReadProperty, and WritePropertyMultiple. Fix indentation bug in decodeExceptionSchedule OBJECTIDENTIFIER branch. Remove redundant scheduleValues/dateListValues aliases in WriteProperty. Remove ambiguous isFullWeek heuristic — indexed writes now always treat values as BACNetTimeValueEntry[] directly. Add typeof number check in encodeEffectivePeriodPayload to correctly reject plain number inputs for non-array-size writes. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…perties Add encode and decode support for reading and writing individual array elements (arrayIndex != ARRAY_ALL) on WEEKLY_SCHEDULE, EXCEPTION_SCHEDULE, EFFECTIVE_PERIOD and DATE_LIST. Also fix falsy-bug where arrayIndex 0 was treated as ARRAY_ALL due to loose truthiness checks (|| vs ?? and p.index !== undefined). Refactor WriteProperty.encode to extract encodePropertyValuePayload so WritePropertyMultiple can reuse the same logic without duplication. Add closingTagNumber/openingTagNumber params to schedule decoder functions to support both ReadProperty (tag 3) and ReadPropertyMultiple (tag 4/2) contexts. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c001117c2c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b1c8357640
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
No description provided.